-
-
Notifications
You must be signed in to change notification settings - Fork 25.8k
DOC correct input array type in MeanShift.predict #20796
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.
Thank you @thomasjpfan! I think I have fixed the PR. One observation is that |
It can be an issue. I am okay with |
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.
Thank you for the follow up! Some more comments on the code.
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Thank you! If the team decides against the change then we need to update the documentation. Currently the doc says |
I don't really like the inconsistency. It is unlikely to fit a dense X and predict a sparse X with such clustering. |
@milana2 Could you revert the changes and just update the documentation. |
I am okay with this option. @milana2 Did you have a use case, where you fit on a dense |
Will do.
We don't have a use case, no. (While working on a project, we noticed inconsistencies in the handling of sparse data and we ran an analysis to look for inconsistencies between code and documentation. We have reported two of the cases we found. There are others. I can open an Issue with the full list if you think that would be useful?) |
…. Updated docstring instead.
This reverts commit 7b88036.
Thanks @milana2 Looks good. |
Co-authored-by: Ana Milanova <milana2@rpi.edu> Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Co-authored-by: Ana Milanova <milana2@rpi.edu> Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Co-authored-by: Ana Milanova <milana2@rpi.edu> Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Reference Issues/PRs
Fixes Issue #20733. See also Issue #20049 and PR #20117.
What does this implement/fix? Explain your changes.
A minor change of the call to validate_data to allow MeanShift.predict to work with sparse input.
Any other comments?
Apologies for mistakes, this is my first PR. Thanks!