-
-
Notifications
You must be signed in to change notification settings - Fork 26.5k
[MRG + 1] FIX/TST revert #5802 and raise error for faulty classifier #9063
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
jnothman
left a comment
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 guess so. But surely we would need similar checks in other ensembles?
Shall we impose that any estimators (classifiers + regressors): an estimator should predict something of the same type than |
|
For regressors you can expect it to convert int to float. For classifiers
we should be doing that test. Effectively what we're doing here is
outlawing regressors in an ensemble for classification
On 9 Jun 2017 10:10 am, "Guillaume Lemaitre" <[email protected]> wrote:
I guess so. But surely we would need similar checks in other ensembles?
Shall we impose that any estimators (classifiers + regressors): an
estimator should predict something of the same type than y. It could be
check in predict and tested in common test. Is there any estimator not
allowing for such behaviour?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9063 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEz69CkEkFnJ1ARxjI1cq7NIwBPcQUdks5sCI1YgaJpZM4N0McX>
.
|
|
travis is not happy maybe there is an update to do in what's new? |
|
So common tests check that the output classes are exactly the same types as the output classes, i.e. do a label encoder or equivalent inside. That means that if you input float, it will output float. We actually allow floats that encode integers as targets (see I don't think we need this test because a Classifier that internally doesn't to a |
|
[Theoretically an estimator could satisfy check_estimator by remapping strings correctly but always casting ints to floats in the output, but that seems like a weird edge case. We could add an additional check to check_estimators, but I think that's overkill] |
|
@agramfort @amueller I don't think there is a need for a what's new. |
|
LGTM |
|
Thanks @glemaitre 🎉 |
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
… classifier (scikit-learn#9063) * FIX/TST revert scikit-learn#5802 and raise error for faulty classifier * FIX check_estimator take care of the rest
Reverting #5802
Remove casting introduced in #5802 and raise an error due to faulty estimator.
@agramfort @jnothman