-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
ENH Add gamma='scale' option to RBFSampler #24755
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
Conversation
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.
A couple of comments.
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@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.
I would remove both comments because the code is enough self-explantory. Otherwise 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.
Thanks for the PR @glevv. LGTM
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Co-authored-by: Guillaume Lemaitre <g.lemaitre58@gmail.com>
Fixes #24748
What does this implement/fix? Explain your changes.
Added gamma='scale' option to RBFSampler;
Added small test for scale calculation, just like in svm test file (maybe excessive?);
Changed userdocs and parameter constraints accordingly.
Any other comments?
Also took the liberty to replace numpy calls on numbers to python functions, which should be faster. If it was unnecessary, I'll revert it.