API Make cv_results_ return the last iteration in successive halving - #34250
Merged
betatim merged 7 commits intoJun 11, 2026
Merged
Conversation
thomasjpfan
reviewed
Jun 11, 2026
Member
|
I like it. The current behaviour is confusing enough that a user came and updated the documentation to warn people about this caveat. I think this is a better solution |
betatim
reviewed
Jun 11, 2026
betatim
approved these changes
Jun 11, 2026
Co-authored-by: Tim Head <[email protected]>
betatim
enabled auto-merge (squash)
June 11, 2026 17:02
prady0t
pushed a commit
to prady0t/scikit-learn
that referenced
this pull request
Sep 2, 2026
…cikit-learn#34250) Co-authored-by: Tim Head <[email protected]>
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.
While working on the example, it seems that the current API that expect our user to check the last iteration of the halving to inspect ranking is quite surprising.
Instead, I think that we should filter the
cv_results_to the last iteration and add a newall_cv_results_attribute that would contain all the iteration information.It is what we discussed with @ogrisel and @jeremiedbb during the IRL sprint discussion.
In addition, we don't add the ranking in the
all_cv_results_which is not useful for any practical cases.