PatternNet and PatternLRP - Improving the interpretability of neural networks

Pieter-Jan Kindermans, Kristof T. Schütt, Maximilian Alber, Klaus-Robert Müller, Sven Dähne

Abstract

DeConvNet, Guided BackProp, and LRP were invented to better understand deep neural networks. We show that these methods do not produce the theoretically correct explanation for a linear model. Yet they are used on multi-layer networks with millions of parameters. This is a cause for concern since linear models are simple neural networks. We argue that explanation methods for neural nets should work reliably in the limit of simplicity, the linear models. Based on our analysis of linear models we propose a generalization that yields two explanation techniques (PatternNet and PatternAttribution) that are theoretically sound for linear models and produce improved explanations for deep networks.

The Problem: Why Weights Are Not Signals

As deep learning models have grown more complex, researchers have developed numerous techniques to peek inside the "black box" and understand why a model made a specific decision. Methods like DeConvNet, Guided BackProp, and Layer-wise Relevance Propagation (LRP) attempt to do this by propagating the network's output backward through its weights to highlight important input pixels.

However, the authors of this paper take a step back and ask a fundamental question: Do these methods work on the simplest possible neural network—a linear model?

The surprising answer is no. In a linear model, the input data consists of a "signal" (what we want to detect) and a "distractor" (noise or irrelevant data). To accurately detect the signal, the model's weights (the "filter") must be optimized to cancel out the distractor. Therefore, the weights align with the distractor's null space, not the signal itself.

Decomposition of data into signal and distractor, illustrating why weights (w) may not align with the signal (as).

Because existing explanation methods rely on these weights or gradients, they end up visualizing how the network extracts the signal (the filter) rather than what the signal actually is. This fundamental flaw carries over to deep, non-linear networks, resulting in noisy and misleading visualizations.

Methods: PatternNet and PatternAttribution

To fix this, the authors propose explicitly learning a "signal estimator" from the data. They define a mathematical objective for a good signal estimator: once the estimated signal is subtracted from the input data, the remaining "distractor" should have zero correlation with the network's output.

  • PatternNet (Signal Visualization): A technique that modifies the standard backward pass. Instead of using the network's learned weights, it swaps in the learned signal directions. This projects the network's activations back into the original input space (e.g., RGB pixels) to show what pattern caused the activation.
  • PatternAttribution (Attribution): An extension of the Deep Taylor Decomposition / LRP framework. It uses the learned signal directions to accurately assign "relevance" to individual input pixels, creating a heatmap of exactly how much each pixel contributed to the final prediction.

Key Results and Insights

The methods were evaluated using a pre-trained VGG-16 image classification model on the ImageNet dataset.

Qualitative Clarity

PatternNet produces strikingly clear, natural-looking reconstructions of the detected objects (e.g., the actual shape and color of an elephant) in the input space, whereas DeConvNet and Guided BackProp produce noisy, distorted artifacts.

Comparison of explanation methods on a VGG-16 elephant classification.

Quantitative Validation

  • Correlation Analysis: The proposed two-component estimator successfully removes the correlation between the distractor and the output across all layers of VGG-16, vastly outperforming gradient-based estimators which fail to remove distractor information.
  • Image Degradation: To prove their heatmaps highlight the most important pixels, the authors progressively corrupted image patches based on the importance assigned by different methods. Corrupting pixels based on PatternAttribution caused the VGG-16 classifier's confidence to drop significantly faster than baseline methods, proving it more accurately identifies the pixels the model actually relies on.

Conclusion

The authors propose a crucial philosophical baseline for the field of interpretability: any explanation method designed for deep neural networks should at least yield the mathematically correct answer for a simple linear model. By shifting the focus from model weights to data-aware signal estimation, PatternNet and PatternAttribution provide a more theoretically grounded and visually accurate window into the inner workings of deep neural networks.

Summary updated

BibTeX
@inproceedings{kindermans2018patternnet,
  author = {Pieter-Jan Kindermans and Kristof T. Schütt and Maximilian Alber and Klaus-Robert Müller and Sven Dähne},
  title = {{PatternNet and PatternLRP - Improving the interpretability of neural networks}},
  booktitle = {International Conference on Learning Representations},
  year = {2018},
  url = {https://openreview.net/forum?id=Hkn7CBaTW},
}
Figure