Home > Blockchain >  Is it possible to use a MultiOutputRegressor with different hyperparameters for each output?
Is it possible to use a MultiOutputRegressor with different hyperparameters for each output?

Time:11-26

I need a scikit-learn composite estimator for vector targets, but I need to define different hyperparameters for each target.

My first instinct was to define a MultiOutputRegressor of dummy estimators, then overwrite the estimators_ attribute with the desired regressors, but this does not work as only the base estimator is defined on construction; it is then copied on fit.

Do I need to write my own meta-estimator class, or is there a better solution I'm not thinking of?

CodePudding user response:

This was answered off-site by Dr. Lemaitre - no prepacked solution exists to define multiple different regressors into a single multi-output regressor, but a decent work-around is to use one of the -CV family of regressors such as ElasticNetCV as a base estimator. This will allow different hyperparameters for each output, assuming the parameters can be decently tuned on each instance of fit.

  • Related