-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
MAINT Use check_scalar in BaseDecisionTree #21990
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
MAINT Use check_scalar in BaseDecisionTree #21990
Conversation
Notes on param range in trees Edit: updated ranges based on the ranges checked in the code |
Hi @glemaitre, the range for these parameters is different in the existing code and in my notes: Could you help to clear this up? I am already writing new checks based on the range in the notes, but if it makes more sense to keep the ranges consistent with the existing code, I will update them. Thank you! |
It makes sense for |
…m/genvalen/scikit-learn into BaseDecisionTree_add_check_scalar
…nto BaseDecisionTree_add_check_scalar
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this PR we do need to update the messages in test_gbdt_parameter_checks
since we are changing the error messages:
def test_gbdt_parameter_checks(GradientBoosting, X, y, params, err_msg): |
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Thanks @thomasjpfan, I've added a commit the updates the messages causing the issues. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Co-authored-by: Julien Jerphanion <git@jjerphan.xyz>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comment, otherwise this looks good to go.
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM as well!
Co-authored-by: Olivier Grisel <olivier.grisel@ensta.org>
The new release of numpydoc-1.2 is making |
Reference Issues/PRs
Addresses #20724
#DataUmbrella
What does this implement/fix? Explain your changes.
Summary of changes to
BaseDecisionTree
:check_scalar
fromsklearn.utils
to validate the scalar parameters.Test and validation progress:
References
Any other comments?