The Marginal Value of Momentum for Small Learning Rate SGD

Runzhe Wang, Sadhika Malladi, Tianhao Wang, Kaifeng Lyu, Zhiyuan Li

This paper challenges one of the most fundamental "best practices" in deep learning: the use of momentum. While momentum is a default setting in almost every optimizer (like SGD with Momentum or Adam), this research suggests that in many practical scenarios, its benefits are surprisingly marginal.

TL;DR

In training regimes with small learning rates and high gradient noise—common in fine-tuning and small-batch training—vanilla SGD performs just as well as SGD with momentum (SGDM). The authors provide theoretical and empirical evidence that momentum's primary value lies in stabilizing high-curvature directions at large learning rates, rather than reducing gradient noise as commonly believed.

What Problem Does This Paper Address?

In the "folklore" of deep learning, momentum is thought to accelerate training by smoothing out the "zig-zag" noise of stochastic gradients. While this is provably true for non-stochastic (deterministic) optimization, theoretical support for momentum in stochastic settings has been shaky. Previous analyses often failed to show that momentum offers any real acceleration over vanilla SGD when noise is present.

This paper aims to resolve this discrepancy by asking: Does the noise reduction provided by momentum actually benefit neural network training? The authors specifically look at the "small learning rate" regime, which is increasingly relevant as researchers move toward fine-tuning massive pre-trained models or training with smaller, more manageable batch sizes.

Methods

The authors employ a mix of rigorous mathematical analysis and controlled experiments:

  • Weak Approximation Theory: They use a mathematical framework to prove that the trajectories of SGD and SGDM are "close" in a distributional sense. They show that SGDM with a learning rate $\gamma$ and momentum $\beta$ behaves almost identically to vanilla SGD with an "effective" learning rate $\eta = \frac{\gamma}{1-\beta}$.
  • Stochastic Differential Equations (SDEs): To analyze long-term behavior, they model the optimization process as a continuous-time SDE. This allows them to show that both algorithms converge to the same "slow" dynamics and share the same implicit bias when they reach the manifold of local minimizers.
  • SVAG (Stochastic Variance-Augmented Gradient): A novel experimental technique used to isolate the effects of noise versus curvature. By artificially scaling the noise in the gradient, they test if momentum’s supposed "noise-dampening" ability actually leads to better performance.

Key Insights

  • The Effective Learning Rate Rule: The most important takeaway is that if you adjust the learning rate of vanilla SGD to match the "effective" learning rate of SGDM, the two algorithms perform nearly identically in small-LR regimes.
  • Momentum Doesn't "Fix" Noise: While momentum makes the training curve look smoother, it doesn't actually reduce the variance of the final solution. It simply correlates the noise across steps. The "turbulence" is hidden, but the underlying stochasticity remains.
  • Curvature vs. Noise: Momentum’s true "superpower" is handling high curvature. It allows practitioners to use much larger learning rates than vanilla SGD could handle without diverging. However, in regimes where the optimal learning rate is already small (like fine-tuning), this stabilization isn't needed, making momentum redundant.
  • Implicit Bias Parity: SGD and SGDM gravitate toward the same types of minima. They don't just reach the same loss; they reach solutions with similar generalization properties.

Key Results

ImageNet and Batch Size Dynamics

At a batch size of 1024, vanilla SGD achieved results comparable to SGDM. Momentum only showed a significant advantage at very large batch sizes (e.g., 8192), where the optimal learning rate is high enough to cause instability for vanilla SGD.

Validation accuracy vs. batch size for SGD and SGDM

Language Model Fine-tuning

In fine-tuning RoBERTa-large, the performance difference between SGD and SGDM was statistically insignificant across five diverse downstream tasks (SST-2, SST-5, SNLI, TREC, and MNLI). For example, on SST-2, SGD achieved 94.0% accuracy vs. 94.0% for SGDM.

Performance of SGD vs. SGDM on NLP downstream tasks

Noise Dominance

Using the SVAG method on CIFAR-10, the authors showed that as gradient noise increases, the performance gap between SGD and SGDM shrinks to zero. This confirms that momentum does not provide a "noise reduction" benefit that translates to better generalization.

Limitations and Future Work

The authors acknowledge that their theoretical results primarily apply to the small learning rate regime. In "large-batch, large-LR" training—the kind used to train foundation models from scratch—momentum remains a critical tool for stability.

Future work could extend this analysis to adaptive optimizers like Adam or Lion. While this paper focuses on "heavy-ball" momentum, the community would benefit from knowing if the "momentum" component of Adam is similarly redundant during the fine-tuning phases of LLMs, which could potentially save significant GPU memory by eliminating the need to store momentum buffers.

Summary updated

BibTeX
@inproceedings{wang2024marginal,
  author = {Runzhe Wang and Sadhika Malladi and Tianhao Wang and Kaifeng Lyu and Zhiyuan Li},
  title = {{The Marginal Value of Momentum for Small Learning Rate SGD}},
  booktitle = {International Conference on Learning Representations},
  year = {2024},
  url = {https://openreview.net/forum?id=3JjJezzVkT},
}
Figure