[scikit-learn] VotingRegressor with pretrained estimators from CV as input

Adrin adrin.jalali at gmail.com
Fri Nov 18 12:04:15 EST 2022


Hi,

It's easy to write a meta-estimator and store it. You can write one for
yourself in a few lines of code. This might help:
https://github.com/adrinjalali/talks/blob/master/2022/sklearn-estimator-ODSC/custom_estimators_solved.ipynb

On Thu, Nov 10, 2022 at 8:30 PM Fernando Marcos Wittmann <
fernando.wittmann at gmail.com> wrote:

> Hello,
>
> I'm dealing with a problem without much data. As a solution, I'm training
> 10 estimators using a 10-Fold CV-Schema. Now, I wanted to persist those
> models. In order to avoid having to save 10 estimators, I was thinking
> about saving a single VotingRegressor with those pre-trained models or
> maybe writing a custom estimator to be used only for inference. Has anyone
> dealt with similar problems?
>
> TLDR: Looking for an easy way to store multiple models created using
> cross-validation as a single model.
>
> More context: I'll be using mlflow sklearn autolog, so it will be waaay
> more convenient to log only a single model instead of multiple models in
> each experiment.
>
> Thanks!
> _______________________________________________
> scikit-learn mailing list
> scikit-learn at python.org
> https://mail.python.org/mailman/listinfo/scikit-learn
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.python.org/pipermail/scikit-learn/attachments/20221118/ddee5c44/attachment.html>


More information about the scikit-learn mailing list