TL;DR
This paper introduces Projection Weighted CCA (PWCCA), a powerful metric to compare the internal representations of different neural networks. The authors discover that networks that generalize well converge to surprisingly similar internal "logic," while wider networks and specific learning rates lead to more consistent and distinct clusters of solutions.
Introduction: The Challenge of Representational Similarity
Deep neural networks are notoriously difficult to interpret. Even if two networks are trained on the exact same data and achieve the same accuracy, their internal "neurons" often look completely different. This happens because networks are sensitive to random initialization—one might represent a feature in neuron A, while another represents it in a combination of neurons B and C.
To understand if networks are actually learning the same concepts, we need a way to measure representational similarity that isn't fooled by simple linear transformations (like rotating or scaling the data). While previous tools like SVCCA made progress, they often struggled to distinguish between the meaningful "signal" used for the task and the random "noise" inherent in high-dimensional activations.
Methods: Projection Weighted CCA (PWCCA)
The authors build upon Canonical Correlation Analysis (CCA), a statistical technique that finds the best linear relationship between two sets of variables.
The key innovation here is Projection Weighted CCA (PWCCA). Standard CCA-based methods (like SVCCA) tend to treat all correlated directions as equally important. However, the authors observed that many of these directions are "noise"—they change constantly during training and don't actually help the network perform better.
PWCCA solves this by:
- Identifying the "canonical directions" where two layers align.
- Weighting these directions based on how much they actually account for the original neuron activations.
- Calculating a similarity score that prioritizes the "signal" over the "noise."
This makes the metric much more robust and better at identifying when two networks have truly reached a similar functional solution.
Datasets
The researchers validated their method across several standard benchmarks:
- CIFAR-10: Used for image classification experiments with Convolutional Neural Networks (CNNs).
- Penn Treebank (PTB) & WikiText-2: Used for language modeling experiments with Recurrent Neural Networks (RNNs/LSTMs).
Key Insights and Ideas
- Generalization breeds Similarity: Networks that learn to generalize (trained on real labels) converge to much more similar internal representations in their final layers than networks that simply memorize (trained on random labels). Memorizing networks are "unhappy in their own way"—each one finds a unique, idiosyncratic way to overfit.
- The Power of Width: Wider networks (those with more filters/neurons) converge to more similar solutions than narrow ones. This suggests that having more "room" makes it easier for the optimization process to find a standard, high-quality solution.
- Learning Rate "Islands": Networks trained with different learning rates converge to distinct clusters of solutions. Even if the final accuracies are similar, a network trained at a high learning rate "thinks" differently than one trained at a low learning rate.
- Bottom-Up Convergence: Both CNNs and RNNs learn in a "bottom-up" fashion. The layers closest to the input stabilize early in training, while the deeper layers continue to shift and refine their representations until the very end.
Key Results
- Robustness: In synthetic tests, PWCCA remained stable as the signal-to-noise ratio decreased, whereas unweighted mean CCA scores plummeted.
- Predicting Performance: For a group of identical networks with different initializations, the correlation between their test accuracy and their pairwise PWCCA distance was a staggering -0.96. This suggests that representational similarity is a very strong predictor of how well a network has learned.
- RNN Dynamics: The authors found that hidden states in RNNs are highly variable over a sequence. Even after accounting for linear transforms, the "thought process" of an RNN changes significantly from the first word of a sentence to the last.
Limitations and Future Work
The authors note that PWCCA is technically a pseudo-distance because it is non-symmetric (the similarity of A to B isn't identical to B to A, though they are usually close).
While the paper proves that networks are similar, it doesn't fully explain what those shared directions represent in plain English (e.g., "this direction represents 'pointy ears'"). Future work could involve using PWCCA as a regularizer during training—essentially forcing a new network to mimic the representational "logic" of a proven, high-performing model. They also suggest exploring "freeze training" for RNNs, where early layers are locked once they stabilize to speed up convergence.
Summary updated