-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
Crash in univariate feature selection if no feature is selected. #4059
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
Comments
I assume only for sparse input, and again a nice solution is only available in very recent scipy. |
Or perhaps not only for sparse input... |
no, the example above is not sparse. There is just no max of an empty array. |
Maybe bailing is the right thing to do here, but certainly not with that message. The other option would be to return an empty array, which is not super helpful. |
I agree. Any suggestion for the class of exception we should raise for such as case? I don't think there is any standard library exception nor standard numpy exception that matches that case well.
-1 as well. |
I am working on a fix. |
Please have a look at #4206 and let me know what you think of this solution. |
[MRG] explicit warning message for strict selectors Also fixes #4059
Univariate feature selection crashes if no feature is selected with an unhelpful message:
The text was updated successfully, but these errors were encountered: