Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot clone object FeatureWiz...as the constructor either does not set or modifies parameter auto_encoder #114

Open
deuf-projects opened this issue Sep 1, 2024 · 0 comments

Comments

@deuf-projects
Copy link

Hi,

Trying to run the 'Best_Pipeline_Featurewiz.ipynb' example first and after a long and fastiduous work to be able getting some results from your very promising tool I've got the below error than likely prevent from seeing all the expected results.

Sounds the 'auto_encoders' parameters is not defined in the constructor

Thanks in advance for your help

{
"name": "RuntimeError",
"message": "Cannot clone object FeatureWiz(category_encoders=['label', 'label'], feature_engg=[], scalers=''), as the constructor either does not set or modifies parameter auto_encoders",
"stack": "---------------------------------------------------------------------------
RuntimeError Traceback (most recent call last)
Cell In[13], line 1

----> 1 search.fit(X_train, y_train)

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\model_selection\_search.py:788, in BaseSearchCV.fit(self, X, y, groups, **fit_params)
785 cv_orig = check_cv(self.cv, y, classifier=is_classifier(estimator))
786 n_splits = cv_orig.get_n_splits(X, y, groups)
--> 788 base_estimator = clone(self.estimator)
790 parallel = Parallel(n_jobs=self.n_jobs, pre_dispatch=self.pre_dispatch)
792 fit_and_score_kwargs = dict(
793 scorer=scorers,
794 fit_params=fit_params,
(...)
800 verbose=self.verbose,
801 )

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:89, in clone(estimator, safe)
87 new_object_params = estimator.get_params(deep=False)
88 for name, param in new_object_params.items():
---> 89 new_object_params[name] = clone(param, safe=False)
90 new_object = klass(**new_object_params)
91 params_set = new_object.get_params(deep=False)

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:67, in clone(estimator, safe)
65 # XXX: not handling dictionaries
66 if estimator_type in (list, tuple, set, frozenset):
---> 67 return estimator_type([clone(e, safe=safe) for e in estimator])
68 elif not hasattr(estimator, "get_params") or isinstance(estimator, type):
69 if not safe:

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:67, in (.0)
65 # XXX: not handling dictionaries
66 if estimator_type in (list, tuple, set, frozenset):
---> 67 return estimator_type([clone(e, safe=safe) for e in estimator])
68 elif not hasattr(estimator, "get_params") or isinstance(estimator, type):
69 if not safe:

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:67, in clone(estimator, safe)
65 # XXX: not handling dictionaries
66 if estimator_type in (list, tuple, set, frozenset):
---> 67 return estimator_type([clone(e, safe=safe) for e in estimator])
68 elif not hasattr(estimator, "get_params") or isinstance(estimator, type):
69 if not safe:

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:67, in (.0)
65 # XXX: not handling dictionaries
66 if estimator_type in (list, tuple, set, frozenset):
---> 67 return estimator_type([clone(e, safe=safe) for e in estimator])
68 elif not hasattr(estimator, "get_params") or isinstance(estimator, type):
69 if not safe:

File c:\Users\Utilisateur\anaconda3\Lib\site-packages\sklearn\base.py:98, in clone(estimator, safe)
96 param2 = params_set[name]
97 if param1 is not param2:
---> 98 raise RuntimeError(
99 "Cannot clone object %s, as the constructor "
100 "either does not set or modifies parameter %s" % (estimator, name)
101 )
103 # _sklearn_output_config is used by set_output to configure the output
104 # container of an estimator.
105 if hasattr(estimator, "_sklearn_output_config"):

RuntimeError: Cannot clone object FeatureWiz(category_encoders=['label', 'label'], feature_engg=[], scalers=''), as the constructor either does not set or modifies parameter auto_encoders"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant