VOICE: Variance of Induced Contrastive Explanations to quantify Uncertainty in Neural Network Interpretability

Mohit Prabhushankar, Ghassan AlRegib

TL;DR

How much should you trust an AI's explanation? This paper introduces VOICE (Variance of Induced Contrastive Explanations), a framework that quantifies the uncertainty of post-hoc visual explanations by measuring their stability across different contrastive scenarios. It reveals a critical "trust gap": when models make incorrect predictions, they often base their explanations on the very features they are most uncertain about.

What Problem Does This Paper Address?

Deep neural networks are notoriously "black boxes." To make them more interpretable, researchers use post-hoc explainability techniques (like Grad-CAM) to generate heatmaps showing which image features led to a specific prediction. However, these explanations themselves can be unreliable.

While we have well-established methods to measure a model's predictive uncertainty (how unsure it is about a label), we lack rigorous ways to measure explanation uncertainty. If a model points to a dog's snout to justify a "Bullmastiff" prediction, is it doing so with high confidence, or is that attribution just a fluke of the gradient calculation? The authors argue that current evaluation methods—which often involve masking parts of an image to see if accuracy drops—only tell half the story because they fail to account for the residual uncertainty inherent in the explanation process itself.

Methods

The authors propose a "plug-in" framework called VOICE that works with any gradient-based explanation method. The core idea is rooted in a theoretical decomposition of predictive uncertainty.

The process follows three main steps, as illustrated in Figure 2:

  1. Forward Pass: The image $x$ is passed through the network $f(\cdot)$ to get a prediction $P$.
  2. Induce Contrastive Explanations: Instead of just asking "Why $P$?", the system asks a series of contrastive questions: "Why $P$ rather than $Q$?" for all classes $Q$ that had a non-negligible probability. This is done by backpropagating a loss function $J(P, Q)$ rather than just the logit of the predicted class.
  3. Calculate Variance: The resulting stack of contrastive explanation maps is analyzed pixel-wise. The variance across these maps becomes the uncertainty map. If a feature appears consistently across all "Why $P$ rather than $Q$?" scenarios, uncertainty is low. If it fluctuates wildly, uncertainty is high.
Fig. 2. Proposed VOICE uncertainty generation explained using three steps. A prediction P is made in Step 1. Contrastive explanations are induced using R contrast classes in Step 2. R is the number of class probabilities that exceed a threshold pt. In Step 3, variance across vertically stacked explanations is calculated pixelwise and normalized to produce VOICE uncertainty. The red boxes are plug-in frameworks. Green pt is a hyperparameter.

To quantify this, they introduce two metrics:

  • Intersection over Union (IoU): Measures the overlap between the explanation and the uncertainty map.
  • Signal-to-Noise Ratio (SNR): A no-reference metric measuring the dispersion of the uncertainty map.

Datasets

The researchers evaluated VOICE across a diverse set of models and data:

  • ImageNet: Used for primary validation on clean images.
  • CIFAR-10C: A benchmark for robustness, containing images corrupted by 19 different types of noise (blur, weather, digital artifacts) at varying severity levels.
  • Architectures: They tested six different neural networks, ranging from classic CNNs like AlexNet and VGG-16 to modern architectures like the Swin Transformer.

Key Insights and Ideas

  • The Overlap of Doubt: A major finding is that for incorrect predictions, there is a significantly higher overlap (IoU) between the explanation and the uncertainty map. Essentially, when the model is wrong, it tries to justify its decision using features it isn't actually sure about. This is clearly visible in Figure 1.
  • Uncertainty is Unique: Every combination of an image, a specific network architecture, and an explanation technique produces a unique "uncertainty fingerprint."
  • Evaluation Bias: The authors theoretically demonstrate that standard XAI evaluation strategies (like masking) only reduce one component of predictive uncertainty. VOICE captures the "residual" uncertainty that these methods ignore.
  • Epistemic Behavior: The VOICE metrics empirically behave like epistemic uncertainty (uncertainty due to lack of knowledge). As noise levels increase in CIFAR-10C, the VOICE uncertainty metrics track closely with traditional measures like log-likelihood.
Fig. 1. GradCAM [6] explanations and the proposed uncertainty visualization. Top row are results obtained on VGG-16 [14] while bottom row are results obtained on Swin Transformer [15]. Figs. (a), (b), (e), and (f) are obtained on a clean image where both VGG-16 and Swin Transformer predict correctly while Figs. (c), (d), (g), and (h) are results on noisy image where both networks predict incorrectly.

Key Results

  • Quantifying the Trust Gap: Across almost all architectures, the IoU between explanation and uncertainty increased by 9% to 68% when the network made a wrong prediction compared to a correct one. For VGG-16 using Grad-CAM, the IoU jumped from 0.39 (correct) to 0.52 (wrong).
  • Robustness to Noise: In experiments with Additive White Gaussian Noise (AWGN), the authors showed that as noise increases, the explanation and its uncertainty become more dispersed and overlapping, signaling a breakdown in the trustworthiness of the XAI method.
  • Swin Transformer Nuance: The authors noted that Transformers initially showed different behavior due to their low-resolution (7x7) attention maps being interpolated. By adjusting the threshold $t$ for the IoU calculation, they were able to align the Transformer's results with the CNNs, proving the framework's broad applicability.

Limitations and Future Work

  • Gradient Dependency: VOICE is currently a "white-box" method that requires access to model gradients. It cannot yet be applied to non-gradient methods like LIME, SHAP, or TCAV.
  • Adversarial Detection: While the paper shows that uncertainty maps change spatially for adversarial images (Figure 7), the authors admit that simple overlap metrics aren't yet enough to reliably detect sophisticated attacks.
  • Computational Cost: Generating $R$ contrastive explanations for every image is more computationally expensive than generating a single standard explanation. Future work could focus on optimizing the selection of contrast classes $Q$.

Summary updated

BibTeX
@article{prabhushankar2025voice,
  author = {Mohit Prabhushankar and Ghassan AlRegib},
  title = {{VOICE: Variance of Induced Contrastive Explanations to quantify Uncertainty in Neural Network Interpretability}},
  journal = {IEEE J. Sel. Top. Signal Process.},
  year = {2025},
  doi = {10.1109/jstsp.2024.3413536},
}
Figure