Conversation
clone for nested sklearn estimatorsclone for nested sklearn estimators
| estimator_type = type(estimator) | ||
| # XXX: not handling dictionaries | ||
| if estimator_type in (list, tuple, set, frozenset): | ||
| return estimator_type([self._clone(e, safe=safe) for e in estimator]) |
Check failure
Code scanning / CodeQL
Wrong number of arguments in a class instantiation
Codecov Report
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. @@ Coverage Diff @@
## main #195 +/- ##
==========================================
- Coverage 82.75% 82.41% -0.34%
==========================================
Files 43 43
Lines 2806 2832 +26
==========================================
+ Hits 2322 2334 +12
- Misses 484 498 +14
|
fkiraly
added a commit
to sktime/sktime
that referenced
this pull request
Jun 20, 2023
… object (#4707) This adds a test case for the failure of `set_params` with nested `sklearn` objects, see #4704 The fix is in `skbase` and is also tested there: sktime/skbase#195 This PR adds a test in `sktime` with the `sktime` objects for which the failure was reported in #4704.
CTFallon
pushed a commit
to CTFallon/sktime
that referenced
this pull request
Jun 21, 2023
… object (sktime#4707) This adds a test case for the failure of `set_params` with nested `sklearn` objects, see sktime#4704 The fix is in `skbase` and is also tested there: sktime/skbase#195 This PR adds a test in `sktime` with the `sktime` objects for which the failure was reported in sktime#4704.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
clonemethod ofBaseObjectwould not properly clonesklearnestimator that are components (which do not have their ownclone). See sktime/sktime#4704 for a downstream effect.For now, this is fixed by replacing the faulty
skbaseclonewith a copy of thesklearnclone.Also adds a test case similar to the failure reported originally here: sktime/sktime#4704