Similarity of Neural Network Representations Revisited
Simon KornblithMohammad NorouziHonglak LeeGeoffrey E. Hinton
Establishes centered kernel alignment (CKA) as a reliable method for comparing hidden representations across differently initialized neural networks while exposing the mathematical limitations of canonical correlation analysis.
Neural networks often produce internal representations that are difficult to compare directly, raising questions about whether models with the same architecture but different random starts learn similar features, whether layers can be matched across architectures, and how training data or design choices affect those features. These comparisons matter because they can reveal whether networks converge to consistent solutions or develop redundant layers, which in turn affects decisions about model scaling, reuse, and interpretability.
The article set out to identify a reliable scalar index for comparing neural-network representations and to test it on practical questions about layer correspondence, network width, depth, and training data.
The authors first analyzed the invariance properties required of any useful index, showing that full invariance to invertible linear transforms renders many existing measures uninformative once the number of neurons exceeds the number of examples. They then introduced centered kernel alignment (CKA), a normalized measure of similarity between the pairwise similarity matrices of two sets of activations. CKA is invariant to orthogonal transformation and isotropic scaling yet remains sensitive to the relative scale of important directions; it can be computed with either linear or RBF kernels and requires only modest numbers of examples.
When applied to families of convolutional and transformer networks trained on CIFAR-10 and CIFAR-100, CKA recovered the correct layer-to-layer mapping in more than 99 percent of cases across random initializations, whereas canonical correlation analysis, singular-vector CCA, projection-weighted CCA, and linear regression succeeded in fewer than half. CKA further showed that representations become steadily more similar as layer width increases, that similarity saturates earlier in shallow layers than in deep ones, and that early-layer representations remain aligned even when networks are trained on different datasets. In very deep plain networks, CKA detected large blocks of nearly identical representations that coincided with stalled improvements in classification accuracy.
These results indicate that CKA supplies a practical diagnostic for representational consistency, redundancy, and cross-architecture alignment—information that loss curves alone do not provide. Practitioners can therefore use the measure to decide when widening is likely to add value, when depth has become counterproductive, or whether a layer from one model can safely replace the corresponding layer in another.
The main limitations are that the study examined only image-classification and translation models on modest datasets, that the preferred linear kernel may miss structure captured by other kernels, and that CKA, like other summary statistics, collapses rich geometric relationships into a single number. Additional experiments on larger models, different modalities, and alternative kernels would strengthen before the method is treated as a default tool for architectural search or model auditing.
- Paper: Intriguing properties of neural networks, Christian Szegedy et al. (2014). This paper establishes the fundamental observation that representation spaces rather than individual neuron activations carry semantic meaning, directly motivating coordinate-invariant similarity metrics.
- Paper: How transferable are features in deep neural networks?, Jason Yosinski et al. (2014). This work experimentally establishes layer-by-layer representational specificity and transferability across networks, which the source paper quantifies and analyzes using Centered Kernel Alignment.
- Paper: The Unreasonable Effectiveness of Deep Features as a Perceptual Metric, Richard Zhang et al. (2018). This study demonstrates that internal deep network activations naturally form perceptual similarity geometries across architectures, setting the stage for evaluating representation alignment.
- Paper: Visualizing the Loss Landscape of Neural Nets, Hao Li et al. (2017). This paper illustrates how network width, depth, and skip connections structurally alter representation landscapes, providing the architectural phenomena that CKA diagnoses.
- Paper: Interpretability Beyond Feature Attribution: Quantitative Testing with Concept Activation Vectors (TCAV), Been Kim et al. (2018). This work explores linear geometric structures in network activation spaces, providing foundational context for analyzing network representations via linear mappings and vector directions.
- Paper: Understanding Contrastive Representation Learning through Alignment and Uniformity on the Hypersphere, Tongzhou Wang et al. (2020). This work builds on geometric principles of representational alignment and uniformity to explain the mechanics of self-supervised representation learning.
- Paper: On the Relationship between Self-Attention and Convolutional Layers, Jean-Baptiste Cordonnier et al. (2020). This paper examines cross-architectural feature correspondence between self-attention and convolutional layers, extending the cross-architecture representational comparisons investigated in the source.
- Paper: A Simple Framework for Contrastive Learning of Visual Representations, Ting Chen et al. (2020). Co-authored by the source's lead author, this paper leverages insights into representational invariance and projection heads to optimize contrastive visual representations.
- Paper: Barlow Twins: Self-Supervised Learning via Redundancy Reduction, Jure Zbontar et al. (2021). This paper uses cross-correlation matrices between embedding representations to reduce redundancy in self-supervised learning, echoing the pairwise similarity matrix foundations of CKA.
- Paper: Exploring Simple Siamese Representation Learning, Xinlei Chen et al. (2021). This work examines representation dynamics and feature collapse prevention in Siamese architectures, providing practical contexts for representational similarity diagnostics.
- Paper: Spectral Lens: Activation and Gradient Spectra as Diagnostics of LLM Optimization, Andy Zeyi Liu et al. (2026). This work continues the investigation into activation covariance geometry by introducing spectral diagnostics of optimization dynamics beyond aggregate loss curves.
