TL;DR
This paper introduces a new benchmarking framework for representational alignment metrics, specifically focusing on the temporal dynamics of neural networks. The authors demonstrate that Dynamical Similarity Analysis (DSA) significantly outperforms traditional metrics like CKA and Procrustes in identifying how Recurrent Neural Networks (RNNs) learn to solve complex tasks by compositionally combining simpler dynamical "motifs."
What Problem Does This Paper Address?
As neural network architectures grow more complex, researchers in both neuroscience and AI need ways to compare how different models "think." Representational alignment metrics (like CKA or Procrustes) have become the standard tool for this, allowing us to measure how similar the internal activations of two networks are.
However, most of these metrics were designed for static data (like images). When applied to Recurrent Neural Networks (RNNs) or State Space Models (SSMs), they often treat time as just another dimension or a static geometric trace. The "catch" is that these metrics can be fooled by spurious signals and fail to capture the underlying vector fields—the rules governing how a state evolves into the next. This paper seeks to identify which metrics can truly link internal dynamics to actual computation and behavior.
Methods
The authors compare three primary metrics:
- Centered Kernel Alignment (CKA): A popular metric that compares the kernel matrices of feature spaces.
- Procrustes Transformation: A geometric approach that tries to align two sets of activations through rotation, translation, and scaling.
- Dynamical Similarity Analysis (DSA): A newer metric specifically designed for dynamics. It embeds neural traces into a high-dimensional space and compares the transition matrices (the "momentum" of the system) rather than just the static shapes of the paths.
To test these, the authors developed two benchmarks:
- Attractor-based test case: Using simulated Lorenz attractors to test noise robustness and the ability to identify combined dynamical motifs.
- RNN-based test case: Training networks on "compositional" tasks. For example, if a network learns a "Delay" task and an "Anti" task, how does its representation change when it learns a combined "DelayAnti" task?
Datasets
- Simulated Dynamics: Lorenz attractors with varying levels of Gaussian noise.
- Neurogym: A suite of cognitive tasks (Pro-choice, Anti-choice, Delay-match) used to train 72 RNNs (Leaky RNNs and GRUs) and 64 Mamba SSMs. The primary benchmark is the DelayAnti task, which requires combining memory (Delay) and logic inversion (Anti).
Key Insights and Ideas
- Dynamics vs. Geometry: Traditional metrics look at the shape of the neural trajectory. DSA looks at the rules (the vector field) that create that shape. This makes DSA much better at ignoring noise that doesn't affect the actual computation.
- Compositional Learning as a Benchmark: The paper leverages the fact that RNNs solve compound tasks by stitching together dynamical motifs from subtasks. A good metric should be able to "see" this overlap. DSA correctly identified that networks pretrained on more subtasks had representations more similar to the final "Master" network.
- Linking Representation to Computation: A major goal of interpretability is showing that similar internal representations lead to similar behavior. The authors found that only DSA showed a significant correlation between representational similarity and accuracy similarity.
- Mamba's "Reservoir" Behavior: In a surprising twist, applying DSA to the modern Mamba architecture suggested that Mamba doesn't change its internal dynamics much during learning for these simple tasks. Instead, it seems to function like a reservoir, where the hidden states stay relatively fixed and the learning happens primarily in the output layers.
Key Results
- Noise Robustness: In the attractor test, DSA showed the lowest sensitivity to noise, with a "dissimilarity gap" of only $1.7 \times 10^{-2}$, compared to $4.5 \times 10^{-2}$ for CKA.
- Identifying Composition: Only DSA correctly ordered the training groups by their expected similarity to the "Master" task (Untrained < Partial Pretraining < Full Pretraining). CKA and Procrustes failed to distinguish between these groups meaningfully.
- Predicting Behavior: DSA was the only metric where representational dissimilarity was a strong predictor of differences in task accuracy ($R^2 = 0.12, p < 10^{-46}$).
Limitations and Future Work
- Normalization: While DSA is robust, it doesn't naturally behave like a "ratio" (where 0 is perfect similarity). The authors suggest it may need additional normalization for easier interpretation.
- Metric Scope: The study did not include other recent dynamical metrics like Diffeomorphic Vector Field Alignment (Dform), which could be a candidate for future benchmarking.
- Task Complexity: The tasks used were relatively simple cognitive tasks. Future work should explore whether these findings hold for large-scale language models or more complex, non-linear behaviors.
- Empirical Data: The study relied entirely on artificial networks. Validating these metrics against real neural recordings from animals performing similar tasks is a logical next step.
Summary updated