TeamHG-Memex / eli5

A library for debugging/inspecting machine learning classifiers and explaining their predictions
http://eli5.readthedocs.io
MIT License
2.75k stars 331 forks source link

Explaining multi-input model #404

Open dmirecki opened 3 years ago

dmirecki commented 3 years ago

I am working on deep multi-input classification model (first input is an image, second input is a text).

Explaining text part while keeping image constant is easy, because in TextExplainer I am able to put any function. But now, I would like to explain image part with GradCam, keeping text constant. Is it possible? In eli5.show_prediction function I have to put keras model, which is multi-input. How to explain only image part in eli5?

Thanks in advance for any advice!

teabolt commented 3 years ago

Hey @dmirecki. If you're using keras can you pass a sublist of model.layers, passing only the image layers for explanation?