marcotcr / lime

Lime: Explaining the predictions of any machine learning classifier
BSD 2-Clause "Simplified" License
11.55k stars 1.8k forks source link

explain_instance can't be passed in keyarg "sampling_method" #619

Closed triper1022 closed 3 years ago

triper1022 commented 3 years ago

Hi~

When I ran the notebook, Latin Hypercube Sampling.ipynb

I found that lime.lime_tabular.LimeTabularExplainer.explain_instance() can't be passed in _keyarg "samplingmethod". If I remove the keyarg, It works.

I have checked the source code, but I can't find the reason.

I put the notebook I ran into my forked repo. If you have time, please check it, thanks!

marcotcr commented 3 years ago

Which version of lime are you running?

triper1022 commented 3 years ago

lime-0.2.0.1 Python 3.7.10

marcotcr commented 3 years ago

We probably haven't incorporated that feature in the pypi version yet, but it should work if you install from source (clone the repo and run pip install -e .