Superposition, Memorization, and Double Descent: A Comprehensive Report

Original Paper: Superposition, Memorization, and Double Descent
Authors: Tom Henighan, Shan Carter, Tristan Hume, Nelson Elhage, Robert Lasenby, Stanislav Fort, Nicholas Schiefer, Christopher Olah‡
Affiliation: Anthropic
Published: January 5, 2023


Table of Contents


1. Introduction and Motivation

This paper extends the investigation of superposition from the authors’ foundational work (“Toy Models of Superposition,” 2022) by moving from the infinite-data, underfitting regime to finite datasets. The central question: What happens when toy models of superposition overfit and memorize?

Why Mechanistic Interpretability Should Care About Overfitting

Despite overfitting being a central problem in machine learning, we have remarkably little mechanistic understanding of what happens when deep learning models overfit or memorize examples. Previous work has hinted at an important link between overfitting and learning interpretable features.

Consider a language model that verbatim memorizes text. One naive implementation: create a lookup table mapping sequences to continuations, dedicating one neuron per memorized sequence. This is extremely inefficient — but it’s a perfect candidate for superposition, since each memorized case is mutually exclusive and cannot interfere with others.

Three Key Findings

  1. Overfitting corresponds to storing data points, rather than features, in superposition
  2. Models fall into two regimes: an overfitting regime (data points in superposition) and a generalizing regime (features in superposition)
  3. Double descent is observed as the model transitions between these regimes

2. Experiment Setup

Data Generation

Input vectors with dimensions are generated as follows:

  • Sparsity: Each feature with probability ; otherwise
  • Normalization: Vectors are rescaled so (facilitating memorization; in the limit of large , training examples naturally have equal norms via CLT)
  • Finite datasets: Training set of size (the key variable), denoted

Model Architecture: ReLU Output Autoencoder

where is Xavier-initialized, with tied weights.

Loss Function

with uniform importance for all .

Training Details

ParameterValue
OptimizerAdamW (full-batch)
Training steps50,000
LR schedule2,500-step linear warmup to , then cosine decay to 0
Weight decay (default)
SeedsMultiple; lowest training loss selected

Full-batch optimization and annealed learning rate are critical because extremely sparse features () make gradients noisy.


3. Datapoint Features vs. Generalizing Features

Normal Superposition (Infinite Data)

In the infinite-data regime from the previous paper, models embed features as regular polytopes. For example, with hidden dimensions, sparse features organize as a pentagon in the 2D hidden space.

The Core Discovery: Data Points as Features

Data points forming T-gons in hidden space
Figure 1: Left — columns of (feature vectors) look “messy” for small datasets. Right — hidden-layer activations for training examples form clean T-gons (regular polygons) in the 2D hidden space.

When trained on finite, small datasets, the models reveal a striking pattern:

  • From the feature perspective: the columns of look messy and uninterpretable
  • From the data point perspective: hidden vectors form clean T-gons (regular polygons with vertices)

Key insight: For small , it is easier to represent training examples than features in dimensions. The model stores data points in superposition rather than features.

Additional T-gon examples
Figure 2: Additional examples of data points forming regular polygons in hidden space for various dataset sizes.

Naive Mechanistic Theory of Overfitting: Memorization and overfitting occur when models operate on “data point features” (useful for memorization) instead of “generalizing features” (useful for generalization).


4. How Models Change with Dataset Size

Measuring Data-Point Dimensionality

Extending the feature dimensionality from the original paper, the authors define training-example dimensionality:

where is the hidden vector for training example , and is the unit vector in its direction. If training examples form a -gon in , each should have dimensionality .

Three Regimes

Three regimes across dataset size
Figure 3: Top — test loss vs. dataset size showing double descent bump. Middle — feature and training-example dimensionalities. Bottom — hidden and feature vectors for selected dataset sizes.

Small Data Regime (Memorization):

  • Feature dimensionalities are small (features not learned)
  • Training-example dimensionalities follow as expected for T-gons
  • Models memorize via regular polytopes of data points
  • Parameter norms grow with (larger polygons need larger weights)
  • The model can memorize any number of orthonormal training examples using T-gons given infinite precision

Large Data Regime (Generalization):

  • A few features (e.g., 5) have large dimensionalities
  • These features form a pentagon in hidden space; all others are ignored
  • Most data examples activate ≤1 of the 5 pentagon features, so hidden vectors also trace a pentagon
  • Parameter norms plateau; the infinite-data solution gives

Middle Regime (Transition):

  • Behavior is “messy” and hard to interpret
  • Strange dynamics as models transition between strategies
  • This is where double descent occurs

Parameter Norm Behavior

Parameter norms vs. dataset size
Figure 4: Parameter norms (hidden vectors, feature vectors, , ) vs. dataset size, showing growth in the memorization regime, a peak, and plateau in the generalization regime.


5. Superposition Double Descent

The Core Phenomenon

Double descent in test loss
Figure 5: Test loss exhibits a clear bump at the transition between the memorization regime and the generalization regime — this is double descent.

The transition between regimes produces a distinctive bump in test loss: as dataset size increases from the memorization regime, test loss gets worse before it gets better, violating the naive intuition that more data always reduces overfitting.

  • For each dataset size , 4 models with different random seeds are trained; average test loss is plotted
  • The bump occurs precisely at the transition between “data points in superposition” and “features in superposition”

Double Descent Without Label Noise

This finding is remarkable because double descent is observed in the absence of label noise — the autoencoder’s inputs and targets are identical. The “noise” arises from lossy compression: it is impossible to encode 10,000 features into 2 neurons with a linear projection, even in the sparse limit. Imperfect reconstruction gives rise to unavoidable error.

This provides a mechanistic explanation for double descent: it occurs at the transition between two qualitatively different representation strategies.


6. Effect of Hidden Dimension

The double descent is not an artifact of .

2D sweep over (T, m)
Figure 6: Test loss as a function of both dataset size and hidden dimension , showing clear regions of double descent in 2D parameter space.

A 2D sweep over with 4 models per configuration reveals:

  • Clear regions where bigger models or more data hurt performance
  • Optimization yields more consistent results for
  • The phenomenon persists across all hidden dimensions tested

Sensitivity Analysis

Effect of weight decay
Figure 7: Effect of weight decay on the double descent bump. Higher weight decay suppresses the bump; weight decay of 1.0 removes it entirely.

Effect of training epochs
Figure 8: Effect of training duration. More epochs lead to a larger bump in test loss.

Key sensitivities:

  • Weight decay: Increasing from to removes the bump entirely (consistent with prior literature)
  • Training epochs: More epochs increase the bump
  • Both consistent with the double descent literature’s findings about regularization

7. Replications and Extensions

The paper includes extensive external replications that strengthen and extend the findings.

7.1 What Controls the Generalization Scale?

Generalization scale hypothesis testing
Figure 9: Testing what controls when models transition from memorization to generalization.

Two hypotheses tested:

Hypothesis 1: Generalization occurs when T-gon superposition fails due to weight decay constraints.

  • Prediction: Increasing weight decay should decrease the generalization scale.
  • Result: Refuted. The generalization scale does not shift with weight decay.

Hypothesis 2: Generalization occurs when features appear multiple times in different combinations, allowing them to be distinguished.

  • Prediction: Generalization at .
  • Result: Supported. Models generalize once datasets are large enough to see each feature ~10 times:

Generalization scale collapse
Figure 10: Feature dimensionalities approximately collapse when plotted against , confirming the hypothesis.

7.2 Repeated Data Points

Repeated data points analysis
Figure 11: Analysis of how repeated data points interact with feature learning.

Key findings:

  • Small repeats (2–3): phenomenology unchanged
  • More repeats: models learn a mixture of datapoints and features
  • A datapoint repeated 5 times gets embedded alongside 4 generalizing features, suppressing the 5th
  • With >5 repeated datapoints: all 5 generalizing features are suppressed

Memorization threshold: Datapoints are memorized when:

where is the number of repeats, is dataset size, and is the number of features. Empirically: .

Memorization threshold
Figure 12: Empirical verification of the memorization threshold. Red markers indicate memorized datapoints.

7.3 MNIST Application: Maximal Data Dimensionality

MNIST data dimensionality
Figure 13: Data dimensionality applied to MNIST, revealing potential memorized examples as outliers.

A preliminary investigation of detecting memorized examples in a real network (512-hidden-unit MNIST model). The maximal data dimensionality metric:

picks the direction maximizing dimensionality. Examples with unusually high tend to be weird outliers — potentially “memorized” special cases. This provides a form of mechanistic anomaly detection.

Anomalous MNIST examples
Figure 14: Examples of MNIST digits with anomalously high data dimensionality — unusual or ambiguous digits that may be memorized rather than generalized from.

7.4 Optimization Failures in 2D

Two-circle optimization failures
Figure 15: Optimization failures where data points organize on two concentric circles instead of a single T-gon.

When training models in the low-data regime, some models organize points on two circles of different radii instead of a single circle — a fascinating optimization failure that requires large angular gaps at the interface.

7.5 Broader Replications

Replication results from Hobbhahn
Figure 16: Independent replication results confirming double descent across modified settings.

  • Adam Jermyn: Replicated for ; qualitatively agreed but with quantitative differences (onset of generalization at vs. )
  • Marius Hobbhahn (Univ. of Tuebingen): Replicated with modified setup (10× reduced sparsity and features); found double descent in multiple settings including different loss functions and added ReLU layers

8. Key Mathematical Formulations

QuantityFormulaInterpretation
Hidden representationEncoding into bottleneck
ReconstructionDecoding with nonlinearity
Training lossImportance-weighted MSE
Training-example dimensionalityHow many dimensions a data point “uses”
Maximal data dimensionalityDirection-optimized version
Memorization thresholdWhen repeated points get memorized
Generalization scaleEach feature seen ~10 times

9. Conclusions and Open Questions

Core Finding

In toy models, memorization can be understood as models learning “single data point features” in superposition. These models exhibit double descent as they transition from representing data points to representing generalizing features.

This provides a mechanistic account of double descent: the phenomenon arises from the competition between two qualitatively different representation strategies, both implementable via superposition but serving different purposes (memorization vs. generalization).

Open Questions

  1. Mixed representations: What happens when models learn a mixture of features and data point features? (Partially explored via repeated data experiments)
  2. The middle regime: What are models doing mechanistically during the transition where losses spike?
  3. Feature definition: Is there a unified notion of “feature” that encompasses both generalizing features and single data points?
  4. Real-world applicability: Does this mechanistic picture of double descent generalize to large-scale models?
  5. Practical anomaly detection: Can data dimensionality metrics reliably identify memorized examples in production models?

Key Takeaways

  1. Memorization IS superposition — just of data points instead of features
  2. Two regimes with a sharp transition — small data → memorize data points as T-gons; large data → learn features as polytopes
  3. Double descent has a mechanistic explanation — it occurs at the competition boundary between representation strategies
  4. No label noise required — lossy compression alone is sufficient for double descent
  5. Generalization scale is predictable — models generalize when (each feature seen ~10 times)
  6. Practical applications possible — data dimensionality metrics may enable mechanistic anomaly detection in real models

This report was generated from the original Anthropic publication. All figures are screenshots from the original interactive article.