lime
lime copied to clipboard
How to get explanations for all classes
Dear Team, @marcotcr,
How can I get explanations for multiple classes? Currently, I am only getting for the top three classes with the below code.
exp.show_in_notebook()
The "label" field only takes the top three class labels. If I pass all the class labels (e.g., I have six classes), it throws the keyerror.
exp.show_in_notebook(labels=[0, 2, 5]) - This code working (top three classes)
exp.show_in_notebook(labels=[0, 1, 2, 3, 4, 5]) - This code is not working (all classes), throwing keyerror with key 1.
Any help is appreciated. I can give more details if necessary.
Just check this link
https://lime-ml.readthedocs.io/en/latest/lime.html#lime.lime_tabular.LimeTabularExplainer.explain_instance
and set "top_labels" =6 .
I may solve the problem