Skip to content

Commit

Permalink
Pulled out callbacks for more customisation.
Browse files Browse the repository at this point in the history
  • Loading branch information
jameschapman19 committed Jun 1, 2022
1 parent b87d91b commit ebc5079
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cca_zoo/model_selection/_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ def fit(self, X, y=None, *, groups=None, **fit_params):
)
self = BaseSearchCV.fit(self, np.hstack(X), y=None, groups=None, **fit_params)
self.best_estimator_ = self.best_estimator_['estimator']
self.best_params_ = {key.removeprefix('estimator__'): val for key, val in self.best_params_.items()}
self.best_params_ = {key[len('estimator__'):]: val for key, val in self.best_params_.items()}
return self


Expand Down Expand Up @@ -673,5 +673,5 @@ def fit(self, X, y=None, *, groups=None, **fit_params):
)
self = BaseSearchCV.fit(self, np.hstack(X), y=None, groups=None, **fit_params)
self.best_estimator_ = self.best_estimator_['estimator']
self.best_params_ = {key.removeprefix('estimator__'): val for key, val in self.best_params_.items()}
self.best_params_ = {key[len('estimator__'):]: val for key, val in self.best_params_.items()}
return self

0 comments on commit ebc5079

Please sign in to comment.