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

Explain hashing vectorizer #12

Merged
merged 4 commits into from Sep 26, 2016
Merged

Explain hashing vectorizer #12

merged 4 commits into from Sep 26, 2016

Conversation

lopuhin
Copy link
Contributor

@lopuhin lopuhin commented Sep 26, 2016

When the hashing vectorizer is passed as-is (not wrapped into InvertableHashingVectorizer), then an InvertableHashingVectorizer is built when explaining predictions for this document, and then discarded. If the InvertableHashingVectorizer is passed, then it is assumed that it was already fit (it's also possible to call a partial fit for it, but it seems to complicate the API).

Fixes #9

@codecov-io
Copy link

codecov-io commented Sep 26, 2016

Current coverage is 91.78% (diff: 100%)

Merging #12 into master will increase coverage by 0.63%

@@             master        #12   diff @@
==========================================
  Files            12         12          
  Lines           565        572     +7   
  Methods           0          0          
  Messages          0          0          
  Branches         90         91     +1   
==========================================
+ Hits            515        525    +10   
+ Misses           28         27     -1   
+ Partials         22         20     -2   
Diff Coverage File Path
•••••••••• 100% eli5/sklearn/unhashing.py
•••••••••• 100% eli5/sklearn/explain_prediction.py
•••••••••• 100% eli5/sklearn/explain_weights.py
•••••••••• 100% eli5/sklearn/utils.py

Powered by Codecov. Last update 504d1e4...6da8bb3

Also add coef_scale to explain_prediction kwargs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants