Introduction
Deep learning models often achieve comparable performance on benchmark tasks while relying on fundamentally different internal logic. As these models are increasingly deployed in critical domains, understanding these representational differences becomes essential for debugging, auditing for bias, and scientific discovery. However, existing Explainable AI (XAI) tools are primarily designed to explain a single model in isolation. When applied to model comparison, these tools struggle with concept overlap and high cognitive load, as users must mentally subtract complex explanations to find the differences. To address this, we present Representational Difference Explanations (RDX), a training-free method for directly visualizing the conceptual delta between two models.
The Challenge of Model Comparison
Standard XAI methods like Sparse Autoencoders (SAEs) or Non-negative Matrix Factorization (NMF) often fail to highlight subtle distinctions between models. This is due to three primary hurdles:
- Concept Overlap: Models often share many "easy" concepts (e.g., both models recognize a "car"), making it difficult to isolate nuanced differences.
- Incomplete Explanations: Standard methods focus on prototypical examples, often missing the edge cases where model representations actually diverge.
- Cognitive Load: Comparing two sets of complex explanations is imprecise and difficult for human auditors.
The RDX Framework
RDX shifts the focus from explaining individual models to explaining the relationship between them. The method operates on the relative geometry of data in the embedding space through a four-step process:
- Distance Matrices: Pairwise distance matrices ($D_A$ and $D_B$) are computed for a shared set of images across both models.
- Locally Biased Difference Function: Instead of simple subtraction, RDX employs a specialized function that prioritizes pairs of items considered similar by Model A but dissimilar by Model B. This effectively filters out shared structural information.
- Spectral Clustering: The resulting difference matrix is clustered to identify "differential concepts"—groups of images that Model A groups together while Model B does not.
- Visualization: These clusters are presented as image grids, providing a human-interpretable view of what makes Model A's representation unique.
Crucially, RDX is training-free and can be applied to any model that produces embeddings, making it significantly more efficient than dictionary learning baselines.
Experimental Validation
The authors validated RDX across several benchmarks, including Modified MNIST, CUB-200-2011 (Birds), and subsets of ImageNet and iNaturalist. To quantify performance, a new metric called the Binary Success Rate (BSR) was introduced, measuring how well a method identifies pairs of items that are closer in one model than another.
Key results include:
- Quantitative Superiority: RDX consistently outperformed NMF and SAE baselines in BSR scores across all "known difference" experiments.
- Concept Recovery: In bird classification tasks, RDX successfully isolated specific human-defined concepts (like "spotted wings") when they were removed from one model, whereas baseline methods produced generic, unrelated clusters.
- Knowledge Discovery: When comparing DINOv2 to DINO, RDX revealed that DINOv2 better organizes primates by species, whereas DINO was more influenced by background elements like greenery or fencing.
Discussion and Limitations
While RDX provides a powerful tool for comparative analysis, it faces certain limitations. The computation of pairwise distance matrices is $O(n^2)$ in memory, currently limiting the method to approximately 10,000 data points. Additionally, the reliance on Euclidean distances may not perfectly capture the manifold of all representation spaces, though neighborhood-based approaches mitigate this. Future work will explore extending RDX to multi-modal representations and incorporating classifier information to link representational shifts directly to performance gaps.
Summary updated