Double Descent & Grokking

Bigger models were supposed to overfit more. Deep learning breaks that rule.

🔴 advanced5 min readtheory
Classic statistics says that past a certain size, a bigger model overfits and gets worse on new data. Deep learning breaks that rule. As a model grows, test error falls, then rises sharply around the point where the model can only just fit every training example, and then falls again as the model keeps growing. This second fall is called double descent. A related effect, grokking, is when a model suddenly generalises long after it has already memorised its training data.

Breaking Classical Statistical Wisdom

For decades, introductory statistics taught the U-Shaped Bias-Variance Curve:

As model complexity increases, training error decreases, but test error eventually increases due to Overfitting.

  CLASSICAL BIAS-VARIANCE U-CURVE:
  Test Error
    │         \             / ◄── Classical Overfitting Spike!
    │          \           /
    │           \_________/  ◄── Optimal Capacity Point
  0 ┴─────────────────────────────────────────► Model Capacity / Parameters

However, modern deep neural networks (like 70B LLMs) have far more parameters than training samples, yet they achieve outstanding test generalization!

Mikhail Belkin et al. (2019) and Preetum Nakkiran et al. (2019) explained this paradox by discovering Deep Double Descent.

  DEEP DOUBLE DESCENT CURVE:
  Test Error
    │         \             /\
    │          \           /  \
    │           \_________/    \________________ ◄── Over-Parameterized Regime
  0 ┴───────────────────┼─────────────────────────► Model Capacity / Parameters
                    Interpolation
                      Threshold (N = D)

The 3 Regimes of Double Descent

┌──────────────────────────┬──────────────────────────┬──────────────────────────┐
│ 1. UNDER-PARAMETERIZED   │ 2. INTERPOLATION SPIKE   │ 3. OVER-PARAMETERIZED    │
├──────────────────────────┼──────────────────────────┼──────────────────────────┤
│ Classical U-Curve regime.│ Parameter count N equals │ Parameter count N >> D.  │
│ Increasing capacity      │ sample count D. Model is │ Multiple interpolating   │
│ reduces bias and test    │ forced to fit noise.     │ solutions exist. SGD     │
│ error toward minimum.    │ HUGE TEST ERROR SPIKE!   │ selects smooth low-norm! │
└──────────────────────────┴──────────────────────────┴──────────────────────────┘
  1. Under-Parameterized Regime (N<DN < D): Standard classical behavior. Adding parameters improves generalization.
  2. Interpolation Threshold (N≈DN \approx D): The exact point where model capacity is just large enough to fit 100%100\% of training samples. The model is forced to fit noisy outlier points, causing a severe test error spike!
  3. Over-Parameterized Regime (N≫DN \gg D): As parameter count grows far past DD, an infinite number of interpolating solutions exist. Gradient descent (SGD) acts as an implicit regularizer, selecting the smoothest, lowest-norm solution, causing test error to decrease again!

Types of Double Descent

Double Descent manifests across three axes:

What is Grokking? (Power et al., 2022 / OpenAI)

Grokking is an extreme temporal form of epoch-wise double descent observed in algorithmic tasks (like modular arithmetic or symbolic logic):

  Accuracy (%)
   100 ┤              TRAINING ACCURACY = 100%
       │  ═══════════════════════════════════════════════════
       │                                          GROKKING SPIKE!
    50 ┤                                                 /
       │                                                /
     0 ┼───────────────────────────────────────────────/─────► Training Epochs
          0             1,000         10,000        50,000
  1. The model achieves 100%100\% Training Accuracy within 1,000 epochs, but 0%0\% Validation Accuracy (pure memorization!).
  2. Training continues for 50,00050,000 extra epochs with 0.00.0 training loss.
  3. Suddenly, validation accuracy spikes to 100%100\% in a few steps!

The network transitions from memorizing training rows into discovering the underlying general mathematical algorithm long after training loss hit zero.

Say this out loud

Double Descent describes how test error decreases, spikes near the interpolation threshold where parameter count equals sample count, and then decreases again in over parameterized regimes. Past the interpolation threshold, implicit SGD regularization selects smooth low norm solutions. Grokking is an extreme form where models suddenly transition from memorization to perfect test generalization long after training loss hits zero.

Followups to expect

  1. How does L2 Weight Decay impact Double Descent? Proper L2 regularization suppresses or completely flattens the interpolation error spike, allowing models to transition smoothly into the over-parameterized regime.
  2. What is Implicit Bias in SGD? Stochastic Gradient Descent naturally favors solutions with smaller L2 norm of weights or minimal curvature, explaining why massive over-parameterized models generalize well without explicit regularization.

Check yourself

Question 1 of 3

What unexpected phenomenon occurs to test loss in deep neural networks past the classical Interpolation Threshold?

More in Deep Learning

See all →
Activation Functions4 minDropout4 minBackpropagation5 min