Evaluating Attribution for Graph Neural Networks

Benjamin Sanchez-Lengeling, Jennifer N. Wei, Brian K. Lee, Emily Reif, Peter Wang, Wesley Wei Qian, Kevin McCloskey, Lucy J. Colwell, Alexander B. WiltschkoNeurIPS 2020

Introduction

This paper introduces a rigorous, quantitative framework for benchmarking "attribution" methods—tools that explain which parts of a graph (nodes or edges) a Graph Neural Network (GNN) relies on for its predictions. By using synthetic graph tasks with mathematically "ground-truth" answers, the authors reveal that the Class Activation Map (CAM) paired with a Graph Convolutional Network (GCN) is currently the gold standard for reliable, stable, and faithful explanations.

The Challenge of Evaluating GNN Attribution

As machine learning models are increasingly deployed in high-stakes fields like drug discovery and social network analysis, we need to know why a model makes a specific prediction. This is the domain of attribution: assigning "credit" to specific input features (like a specific atom in a molecule) that influenced the output.

In image or text processing, evaluating these explanations is hard because "ground truth" is subjective—ask three people why a picture is a "dog," and you might get three different answers. However, graphs offer a unique opportunity. We can build synthetic graphs where the "answer" is a known motif (e.g., "Does this molecule contain a benzene ring?"). If the model predicts "Yes," a perfect attribution method should highlight exactly the atoms in that ring. This paper fills the gap in GNN research by moving away from qualitative heatmaps toward objective, quantitative benchmarking.

Methods and Evaluation Metrics

The authors evaluated six common attribution methods across four popular GNN architectures (GCN, MPNN, GAT, and Graph Nets). The attribution methods tested include CAM (Class Activation Maps), Integrated Gradients (IG), GradInput, SmoothGrad, and GradCAM.

To evaluate these methods fairly, they defined four "axes" of performance:

Evaluation Metrics
  1. Accuracy: How closely does the attribution match the known ground-truth motif?
  2. Consistency: Does the method give similar explanations across different model hyperparameters, or is it a "lucky" fluke?
  3. Faithfulness (Fidelity): If we intentionally degrade the model's performance (e.g., by adding noise to labels), does the attribution accuracy drop accordingly? A "faithful" method should reflect the model's actual internal state.
  4. Stability: If we slightly perturb the graph in a way that doesn't change the label, does the explanation stay the same?

Datasets with Computable Ground Truths

The study utilizes several synthetic and semi-synthetic datasets where ground truth is mathematically computable, allowing for objective evaluation:

Dataset Examples
  • Graph Classification: Molecular graphs from the ZINC database, where tasks involve identifying specific chemical groups (Benzene, Fluoride, Carbonyl, etc.) and logical combinations of them (e.g., "Amine AND Ether").
  • Graph Regression: The Delaney solubility dataset, using the Crippen LogP model to provide continuous ground-truth values for node importance.
  • Node Classification: Synthetic benchmarks like BA-shapes (house-shaped motifs attached to Barabasi-Albert graphs) and Tree-grid, where the goal is to identify a node's role within a specific structural motif.

Key Insights

  • The "Attention" Trap: Many researchers use "Attention Weights" as a built-in explanation for GAT models. This paper finds that attention weights are often poor indicators of actual feature importance, performing significantly worse than dedicated attribution methods like CAM or IG.
  • Simplicity Wins: Simpler architectures like GCNs tend to produce much more reliable and accurate attributions than highly parameterized models like Graph Nets. Graph Nets, while powerful, showed high variability, making their explanations harder to trust.
  • Training Time Matters: A surprising finding is that attribution accuracy often declines in later training epochs, even if the model's predictive accuracy remains high and stable. This suggests that models might "overfit" their reasoning process even when they aren't overfitting their predictions.
  • CAM is King (When Applicable): If your architecture supports it (i.e., it has a global average pooling layer), CAM is the most accurate, stable, and consistent method. If CAM isn't an option, Integrated Gradients (IG) is the best general-purpose runner-up.

Key Results

  • Top Performer: CAM applied to GCNs achieved the highest mean attribution accuracy (measured by AUROC) across almost all tasks.
  • Generalization: Integrated Gradients (IG) proved to be the most consistent method across different architectures when CAM could not be used.
  • Stability: CAM exhibited the lowest variance when inputs were perturbed, meaning it is less likely to give a "jittery" or nonsensical explanation due to minor noise.
  • Faithfulness: Using a new metric called PARC (performance-attribution relative correlation), the authors showed that CAM and IG are the most "faithful" to the model's actual predictive power.

Limitations and Future Work

The authors acknowledge that their study is limited to two main types of data (molecular and synthetic structural motifs). Real-world graph data can be much messier and larger. Furthermore, while they tested a standard implementation of "Attention," they suggest that more sophisticated ways of translating attention into attribution might yield better results.

Future work could expand this benchmarking suite to include more diverse graph types (like citation networks or social graphs) and explore how to maintain attribution accuracy during long training runs where "explanation drift" currently occurs.

Summary updated

BibTeX
@inproceedings{sanchezlengeling2020evaluating,
  author = {Benjamin Sanchez-Lengeling and Jennifer N. Wei and Brian K. Lee and Emily Reif and Peter Wang and Wesley Wei Qian and Kevin McCloskey and Lucy J. Colwell and Alexander B. Wiltschko},
  title = {{Evaluating Attribution for Graph Neural Networks}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2020},
  url = {https://openreview.net/forum?id=oemBzEf5Hwm},
}
Figure