sanity checks for saliency maps
play

Sanity Checks for Saliency Maps Julius Adebayo PhD Student, MIT. - PowerPoint PPT Presentation

Sanity Checks for Saliency Maps Julius Adebayo PhD Student, MIT. Joint work with 1 Some Motivation [Challenges for Transparency, Weller 2017, & Doshi-Velez & Kim, 2017 ] Developer/Researcher: Model Debugging. Safety


  1. Sanity Checks for ‘Saliency’ Maps Julius Adebayo PhD Student, MIT. Joint work with 1

  2. Some Motivation [Challenges for Transparency, Weller 2017, & Doshi-Velez & Kim, 2017 ] • Developer/Researcher: Model Debugging. • Safety concerns. • Ethical concerns. • Trust: Satiate ‘societal’ need for reasoning to trust an automated system learned from data. 2

  3. Goals: Model Debugging • Model Debugging : reveal spurious correlations or the kinds of inputs that a model is most likely to have undesirable performance. [Ribeiro+ 2016] 3

  4. Promise of Explanations • Model Debugging : reveal spurious correlations or the kinds of inputs that a model is most likely to have undesirable performance. Husky 4

  5. Promise of Explanations • Model Debugging : reveal spurious correlations or the kinds of inputs that a model is most likely to have undesirable performance. Husky Explanation 5

  6. Promise of Explanations • Model Debugging : reveal spurious correlations or the kinds of inputs that a model is most likely to have undesirable performance. Husky Explanation Fix 6

  7. Agenda • Overview of attribution methods • This talk will mostly focus on post-hoc explanation methods for deep neural networks. • The selection conundrum • Sanity checks & results • Theoretical justification by Nie. et. al. 2018. • Passing sanity checks & recent results • Conclusion

  8. Saliency/Attribution Maps Predictions Corn Explanation 8

  9. Saliency/Attribution Maps Predictions Corn Explanation Attribution maps provide ‘relevance’ scores for each dimension of the input. 9

  10. Saliency/Attribution Maps Predictions Corn Explanation S : R d → R C E : R d → R d Attribution maps provide ‘relevance’ scores for each dimension of the input. 10

  11. How to compute attribution? Predictions Corn Attribution E grad ( x ) = ∂ S i ∂ x [SVZ’13] 11

  12. Some Issues with the Gradient Predictions Corn ‘Visually noisy’, and can violate sensitivity w.r.t. a baseline input [Sundararajan et. al., Shrikumar et. al., and Smilkov et. al.] 12

  13. Integrated Gradients Predictions Corn [STY’17] Sum of ‘interior’ gradients. 13

  14. SmoothGrad Predictions Corn [STKVW’17] Average attribution of ‘noisy’ inputs. 14

  15. Gradient-Input Predictions Corn Element-wise product of gradient and input. 15

  16. Guided BackProp Predictions Corn Zero out ‘negative’ gradients and ‘activations’ while back-propagating. 16

  17. Other Learned Kinds Predictions Corn Explanation [FV’17] Formulate an explanation as through learned patch removal. 17

  18. Non-Image Settings: Molecules 18

  19. The Selection Conundrum Predictions Corn 19

  20. The Selection Conundrum For a particular task and model, how should a developer/researcher select which method to use?

  21. Desirable Properties • Sensitivity to the parameters of a model to be explained. • Depend on the labeling of the data, i.e., reflect the relationship between inputs and outputs.

  22. Sanity Checks • We will use randomization as a way to test both requirements. Model parameter randomization test: randomize (re- • initialize) the parameters of a model and now compare attribution maps for a trained model to those derived from a randomized model. Data randomization test : compare attribution maps for a • model trained with correct labels to those derived from a model trained with random labels.

  23. Model Parameter Randomization Inception V3 • Cascading randomization from top to bottom layers. • Independent layer randomization.

  24. Model Parameter Randomization Conjecture: If a model captures higher level class concepts, then saliency maps should change as the model is being randomized. Cascading randomization Original Explanation Original Image from top to bottom layers Gradient Gradient-SG Gradient Input Guided Back-propagation GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG 24

  25. Model Parameter Randomization Conjecture: If a model captures higher level class concepts, then saliency maps should change as the model is being randomized. Cascading randomization Original Explanation Original Image from top to bottom layers logits Gradient Gradient-SG Gradient Input Guided Back-propagation GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG 25

  26. Model Parameter Randomization Conjecture: If a model captures higher level class concepts, then saliency maps should change as the model is being randomized. Cascading randomization Original Explanation Original Image from top to bottom layers mixed_6b mixed_7b mixed_6e mixed_6d mixed_7c mixed_7a mixed_6c logits Gradient Gradient-SG Gradient Input Guided Back-propagation GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG 26

  27. Model Parameter Randomization Conjecture: If a model captures higher level class concepts, then saliency maps should change as the model is being randomized. Cascading randomization Original Explanation Original Image from top to bottom layers conv2d_4a_3x3 conv2d_3b_1x1 conv2d_2b_3x3 conv2d_2a_3x3 conv2d_1a_3x3 mixed_6b mixed_5d mixed_7b mixed_6e mixed_6d mixed_6a mixed_5c mixed_5b mixed_7c mixed_7a mixed_6c logits Gradient Gradient-SG Gradient Input Guided Back-propagation GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG 27

  28. Model Parameter Randomization Conjecture: If a model captures higher level class concepts, then saliency maps should change as the model is being randomized. Cascading randomization Original Explanation Original Image from top to bottom layers conv2d_4a_3x3 conv2d_3b_1x1 conv2d_2b_3x3 conv2d_2a_3x3 conv2d_1a_3x3 mixed_6b mixed_5d mixed_7b mixed_6e mixed_6d mixed_6a mixed_5c mixed_5b mixed_7c mixed_7a mixed_6c logits Gradient Gradient-SG Gradient Input Guided Back-propagation GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG 28

  29. Metrics • Rank correlation of attribution from model with trained weights to those derived from partially randomized models. • Attribution sign changes. Roughly similar regions are, however, still attributed. Inception v3 - ImageNet See Caption Note Rank Rank Correlation Correlation ABS No ABS original logits 7c 7b 7a 6e 6d 6c 6b 6a 5d 5c 5b 4a 3b 2b 2a 1a original logits 7c 7b 7a 6e 6d 6c 6b 6a 5d 5c 5b 4a 3b 2b 2a 1a Mixed Conv2d Mixed Conv2d

  30. Model Parameter Randomization CNN MNIST Original Image Independent Randomization of Successive Randomization of Layers Layers original explanation original explanation conv_hidden2 conv_hidden1 conv_hidden2 conv_hidden1 output-fc output-fc fc2 fc2 Explanation Gradient Gradient-SG Gradient-VG Guided Backpropagation Guided GradCAM Integrated Gradients Integrated Gradients-SG

  31. Medical Setting Skeletal Radiograph Age Guided Backpropagation

  32. Random Labels Labels True Gradient Gradient-SG Absolute-Value Visualization Guided BackProp Data Randomization GradCAM Guided GradCAM Rank Correlation - Abs Integrated Gradients Integrated Gradients-SG Gradient Input 32 CNN - MNIST Random Labels Labels True Gradient Rank Correlation - No Abs Gradient-SG Guided Diverging Visualization BackProp GradCAM Guided GradCAM Integrated Gradients Integrated Gradients-SG Gradient Input

  33. Random Labels Labels True Gradient Gradient-SG Absolute-Value Visualization Data Randomization Guided BackProp Integrated Rank Correlation - Abs Gradients Integrated Gradients-SG Gradient Input MLP - MNIST 33 Random Labels Labels True Rank Correlation - No Abs Gradient Gradient-SG Diverging Visualization Guided BackProp Integrated Gradients Integrated Gradients-SG Gradient Input

  34. Some Insights • Nie et. al. (ICML 2018) theoretical showed that Guided back propagation is doing input reconstruction. • Observed in Mahendra et. al. 2014 (ECCV) as well. Figure from Nie et. al, 2018.

  35. Summary • We focused on gradient-based methods mostly. • Sanity checks don’t tell if a method is good, just if it is invariant. • Sole visual inspection can be deceiving.

  36. What about other methods Cascading randomization from top to bottom layers for VGG-16 LIME-5 { LIME-10 LIME Variants LIME-20 LIME-50 SHAP Gradient SmoothGrad Guided BackProp VGrad Input-Gradient Integrated Gradients DeepTaylor { Pattern Attribution LRP-Z Not Previously considered in LRP-EPS literature. LRP-SPAF LRP-SPBF PatternNet

  37. A Fix for Sanity Checks • Gupta et. al. fix this with competition for gradients (CGI). [Figure from Gupta et. al. 2019.] 37

  38. Other Assessment Methods • Hooker et. al. (to appear at Neurips 2019) propose to remove and retrain. • Adel et. al. propose FSM to ‘quantify’ information content. • Yang et. al. introduce a benchmark (w/ground truth) and other metrics to assess how well a map captures model behavior.

  39. Attacks • ‘Adversarial’ attack on explanations by Ghorbani et. al. • Mean-shift attack by Kindermans & Hooker et. al. 39

  40. Conundrum Persists • For methods that pass sanity checks how do we choose among these? • Can end-users (developers) use these methods to debug? • What about other explanation classes (concepts and global methods)?

Recommend


More recommend