EpistasisLab / EpistasisLab/tpot

multioutput problem

Open
#971 11 comments 0 reactions 0 assignees View on GitHub
being worked on enhancement
Dominant language
Jupyter Notebook
Stars
10.1k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

I am working on a multioutput regression problem, that is the target values have more than 1-dim.
A number of regressors from scikit-learn can only be used for multi output problems when used with the class MultiOutputRegressor (see especially https://scikit-learn.org/stable/modules/multiclass.html#multioutput-regression).

MultiOutputRegressor takes a regressor as an argument and fits then one regressor per target. In this way most single-output regressors can deal multidimensional output. So I want to use it with TPOT.

The issue #903 deals with the changes that must be applied to base.py (which I did and this worked fine) in order to work for multiple output. But neither in #747, #810 nor in #903 it was clarified how to actually use MultiOutputRegressor with **several** regressors.

This is my config dictionary:
`custom_regressor_config_dict = {
'sklearn.multioutput.MultiOutputRegressor': {
'estimator':
{'sklearn.linear_model.ElasticNetCV': {
'l1_ratio': np.arange(0.0, 1.01, 0.05),
'tol': [1e-5, 1e-4, 1e-3, 1e-2, 1e-1]}}}`

Now I want to insert **more** regressors. But I tried to put them in a list or in dictionary and whatever, for example I tried

`'sklearn.multioutput.MultiOutputRegressor': {
'estimator': [
{'sklearn.linear_model.ElasticNetCV': {
'l1_ratio': np.arange(0.0, 1.01, 0.05),
'tol': [1e-5, 1e-4, 1e-3, 1e-2, 1e-1]}},
{'sklearn.ensemble.AdaBoostRegressor': {
'n_estimators': [100],
'learning_rate': [1e-3, 1e-2, 1e-1, 0.5, 1.],
'loss': ["linear", "square", "exponential"]}}
]
}
`

and it always throws an error like:

> RuntimeError: There was an error in the TPOT optimization process. This could be because the data was not formatted properly[...]

How to format it properly so that I can use more models? Is there a workaround? Thank you!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.