Adam: A Method for Stochastic Optimization
This research paper explains how combining momentum-like first moments with RMSProp-style second moments, plus bias correction, yields a robust default optimizer for deep networks.
Stochastic gradients are noisy, scaled differently across parameters, and change as training progresses. A single global SGD step size is a blunt instrument: too large and some coordinates explode; too small and sparse features crawl. Adam combines two successful ideas — momentum (first moment) and RMSProp-style scaling (second moment) — into one update with bias correction for the fact that exponential averages start at zero.
The punchline: per-parameter adaptive rates with defaults that “just work” across many deep-learning problems, which is why Adam became a default optimizer for a decade of training recipes.
What this paper explains
Let be the minibatch gradient at step . Adam maintains:
with default , . Because , early estimates are biased toward zero. Bias-corrected moments:
Parameter update (learning rate ):
with a small constant (paper default ).
Prior limits
- SGD — simple, but learning-rate schedules and gradient scaling are fragile.
- Momentum / Nesterov — accelerate in consistent directions but still one global scale.
- AdaGrad — accumulates squared gradients forever; effective rates can shrink too aggressively.
- RMSProp — uses an exponential second moment but lacks Adam’s first-moment + bias-correction packaging.
The mechanism
First moment smooths the gradient direction (momentum-like). Second moment estimates a per-coordinate curvature/noise scale; dividing by down-weights steps where gradients have historically been large. Bias correction matters most while is small — especially for close to 1, where warms up slowly.
Adam is invariant to diagonal rescaling of the gradients in a useful practical sense: if you multiply a coordinate’s gradients by a constant, the ratio adjusts accordingly.
Algorithm / figure walkthrough
- Initialize , , , .
- Sample minibatch; compute .
- Update , with , .
- Form , .
- Apply the scaled step; optionally add weight decay outside this paper’s original algorithm (AdamW is later work).
The opening visual shows dual EMA meters feeding a single adaptive step.
What to notice when reading
- Bias correction is not optional trivia — it is why early steps are well-scaled with .
- Adam estimates uncentered second moments (), not .
- The paper’s theory section sketches regret-style arguments under standard online-convex assumptions; practice on deep nets is broader than the theorems.
Results and evidence
Kingma & Ba demonstrate competitive or better training curves vs SGD variants, AdaGrad, and RMSProp on logistic regression, multi-layer nets, and convolutional models in the paper’s experiments. They emphasize robustness to hyperparameter choices with the quoted defaults. Later literature debated generalization vs SGD on some vision tasks — that debate is downstream; this paper’s claim is efficient, robust stochastic optimization with adaptive rates.
Limitations
- Adaptive methods can underperform carefully tuned SGD on some generalization benchmarks (later empirical literature).
- Original Adam interacts awkwardly with L2 regularization → AdamW decouples weight decay.
- Second-moment EMA can be slow to react when gradient noise statistics shift abruptly.
- Memory: stores and (two extra buffers per parameter) — relevant for sharded optimizers like ZeRO.
How to read the paper
- Abstract + §1–2 — motivation vs AdaGrad/RMSProp.
- §2 — algorithm box (the whole method fits on one page).
- §2.1 — bias correction derivation.
- §4 — experiments.
- §3 — convergence discussion (read with calibrated expectations).
Knowledge check
What do and estimate in Adam?
Why divide by ?
In the Adam step, what role does play?
Keep reading
- Original paper (arXiv:1412.6980)
- Related Fanout Daily: ZeRO (optimizer-state memory), modern training stacks.
Sources
- Kingma & Ba, Adam: A Method for Stochastic Optimization, ICLR 2015 — arXiv:1412.6980