2

Is there a way to do the above? The SHAP Package is very helpful and works pretty well for PyTorch Neural Nets. For PyTorch RNNs i get the error message below (for LSTMs its the same):

enter image description here

Seems like it doesn't work but is there a workaround or something? Does anyone have experience with PyTorch and SHAP?

1 Answer 1

5

'RNNs aren't yet supported for the PyTorch DeepExplainer (A warning pops up to let you know which modules aren't supported yet: Warning: unrecognized nn.Module: RNN). In this case, the explainer assumes the module is linear, and makes no change to the gradient. Since RNNs contain nonlinearities, this is probably contributing to the problem.' That was an answer I found at Shap.

Try to check captum.ai that is built on PyTorch.

Sign up to request clarification or add additional context in comments.

1 Comment

I am having the same issue with shap=0.46.0. The think with captum.ai is that it does not have the something similar to shap.DeepExplainer

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.