-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
DeepExplainer fails for PyTorch Pretrained Alexnet Model #593
Comments
Hi! As you noted, the warning you are getting is to let you know one of the modules is not explicitly supported by the deep explainer. The warning had a typo that was fixed, and should now let you know which module caused the error. When this happens, the default is to not change the gradient calculated by PyTorch. The warning will be thrown by the adaptive average pooling, as you pointed out, but also for the Note that the warning is intentional, and doesn't necessarily mean the deep explainer failed: For the I'm not familiar with adaptive average pooling, but the correct way for the deep explainer to backpropagate through an average pooling layer also to leave the gradient unchanged, since it is linear. This means the default behaviour might lead to correct shap values, despite the warnings. You are welcome to add support for adaptive average pooling! If not, I can do it so that it is explicitly supported. |
This issue has been inactive for two years, so it's been automatically marked as 'stale'. We value your input! If this issue is still relevant, please leave a comment below. This will remove the 'stale' label and keep it open. If there's no activity in the next 90 days the issue will be closed. |
This issue has been automatically closed due to lack of recent activity. Your input is important to us! Please feel free to open a new issue if the problem persists or becomes relevant again. |
The output of the
e.shap_values
call is belowThe architecture of alexnet
Maybe AdaptiveAvgPool2d used in alexnet architecture is missing
op_handlers
. This happens for pre trained models likevgg16, resnet, inception_v3
.What could be the reason for the failure?
The text was updated successfully, but these errors were encountered: