Skip to content
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

Bug in BaseSearchCV.inverse_transform #8344

Closed
cstjean opened this issue Feb 12, 2017 · 7 comments · Fixed by #8348
Closed

Bug in BaseSearchCV.inverse_transform #8344

cstjean opened this issue Feb 12, 2017 · 7 comments · Fixed by #8348
Labels

Comments

@cstjean
Copy link

cstjean commented Feb 12, 2017

The delegating code for inverse_transform is

    def inverse_transform(self, Xt):
        self._check_is_fitted('inverse_transform')
        return self.best_estimator_.transform(Xt)

Unless I'm mistaken, this should be .inverse_transform(Xt)

@jnothman
Copy link
Member

jnothman commented Feb 12, 2017 via email

@rishikksh20
Copy link
Contributor

@cstjean have you work on this issue ?

@cstjean
Copy link
Author

cstjean commented Feb 13, 2017

@rishikksh20 If you want to make the PR, by all means go ahead. If not, I'll do it later this week.

@raghavrv
Copy link
Member

Thanks for spotting this!!

@lesteve
Copy link
Member

lesteve commented Feb 14, 2017

Just curious, don't we have estimator checks that make sure that estimator.inverse_transform(transform(X)) == X ?

@jnothman
Copy link
Member

jnothman commented Feb 14, 2017 via email

@lesteve
Copy link
Member

lesteve commented Feb 14, 2017

Thanks for the answer, I kind of guessed there were subtleties involved but I figure I would ask and learn something ;-).

Akshay0724 added a commit to Akshay0724/scikit-learn that referenced this issue Feb 17, 2017
Akshay0724 added a commit to Akshay0724/scikit-learn that referenced this issue Feb 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants