TeamHG-Memex / eli5

A library for debugging/inspecting machine learning classifiers and explaining their predictions
http://eli5.readthedocs.io
MIT License
2.76k stars 332 forks source link

tutorials may become broken after next scikit-learn release #179

Closed kmike closed 7 years ago

kmike commented 7 years ago

In the tutorials we rely on the fact classifier and vectorizer are fit after a pipeline is fit - see e.g. http://eli5.readthedocs.io/en/latest/tutorials/sklearn-text.html. But this is changed in scikit-learn development version, so the tutorials should be updated to make no use of this pattern.

Maybe it already became easier after https://github.com/TeamHG-Memex/eli5/pull/177, but we need to check that, and it also needs to be fixed for explain_prediction. Alternative is to avoid using Pipeline in these tutorials, or use pipe.named_steps instead of original clf/vec.

jnothman commented 7 years ago

I don't think this is changed in current scikit-learn master, is it? That's a backward incompatibility we can't afford.

On 2 May 2017 at 23:32, Mikhail Korobov notifications@github.com wrote:

In the tutorials we rely on the fact classifier and vectorizer are fit after a pipeline is fit - see e.g. http://eli5.readthedocs.io/en/ latest/tutorials/sklearn-text.html. But this is changed in scikit-learn development version, so the tutorials should be updated to make no use of this pattern.

Maybe it already became easier after #177 https://github.com/TeamHG-Memex/eli5/pull/177, but we need to check that, and it also needs to be fixed for explain_prediction. Alternative is to avoid using Pipeline in these tutorials, or use pipe.named_steps instead of original clf/vec.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/TeamHG-Memex/eli5/issues/179, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEz67eD_mN0J8F5Gdp351eopsc-5F8Rks5r1zCCgaJpZM4NOJTf .

kmike commented 7 years ago

Oh, right, for some reason I thought https://github.com/scikit-learn/scikit-learn/pull/8350 is already merged and that it is not backwards compatible, while both of it is false. Thanks for the catch!