question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

KBinsDiscretizer : Support inverse_transform for encode other than ordinal

See original GitHub issue

Currently, we only support encode='ordinal' in inverse_transform. Since we’ve supported inverse_transform in OnehotEncoder, it’s natural to support inverse_transform for encode='onehot' and encode='onehot-dense'. Store the fitted encoder will be a reasonable solution here. (See https://github.com/scikit-learn/scikit-learn/pull/11467#issuecomment-403995635)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:11 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
qinhanmin2014commented, Jul 12, 2018

It’s not uncommon to set attributes in fit? I don’t think it will cause a test failure. Maybe you can submit a PR for us to review.

0reactions
qinhanmin2014commented, Jul 21, 2018

Resolved in #11489

Read more comments on GitHub >

github_iconTop Results From Across the Web

sklearn.preprocessing.KBinsDiscretizer
Ignored features are always stacked to the right. 'ordinal': Return the bin identifier encoded as an integer value. strategy{'uniform', 'quantile' ...
Read more >
How to use KBinsDiscretizer to make continuous data into ...
I am working on a ML algorithm in which I tried to convert the continuous target values into small bins to understand the...
Read more >
KBinsDiscretizer encodes wrong bin identifiers for quantile ...
When KBinsDiscretizer is used with quantile strategy to create ordinal encoding the created ID doesn't match the quantile identifier.
Read more >
cuML API Reference — cuml 22.10.00 documentation
An nvcategory based implementation of ordinal label encoding ... from cuml.preprocessing import KBinsDiscretizer >>> import cupy as cp >>> X = [[-2, 1,...
Read more >
17: Scikit-learn 14: Preprocessing 14: KBinsDiscretizer()
The video discusses the code to implement KBinsDiscretizer () in ... notebook 00:34 - Data 00:57 - KBinsDiscretizer : encode =' ordinal ', ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found