Provable Adaptivity of Adam under Non-uniform Smoothness

Bohan Wang, Yushun Zhang, Huishuai Zhang, Qi Meng, Ruoyu Sun, Zhi-Ming Ma, Tie-Yan Liu, Zhi-Quan Luo, Wei Chen

TL;DR

This paper provides the first theoretical proof for why Adam outperforms SGD in modern deep learning by ditching the unrealistic assumption of "global smoothness." By analyzing Adam under a more realistic $(L_0, L_1)$-smoothness condition—where curvature can grow with the gradient—the authors demonstrate that Adam’s coordinate-wise adaptivity gives it a provable edge that standard gradient descent lacks.

What Problem Does This Paper Address?

Most classical convergence analyses for optimizers like Adam rely on the $L$-smooth condition, which assumes the objective function's curvature (the Hessian) is globally bounded by a constant $L$. However, empirical evidence suggests this assumption is false for modern architectures like Transformers and LSTMs. In these models, the landscape is "non-uniform": the steeper the slope (gradient), the more volatile the curvature becomes.

Furthermore, assuming global smoothness actually hides Adam's primary strength. If the landscape were uniformly smooth, there would be no need for an adaptive learning rate. This paper aims to bridge the gap between theory and practice by analyzing Randomly Reshuffled Adam (RR Adam)—the version most commonly used in deep learning—under a relaxed, non-uniform smoothness assumption.

Methods

The authors study RR Adam with a diminishing learning rate. Their analysis centers on the $(L_0, L_1)$-smooth condition, which allows the spectral norm of the Hessian to grow linearly with the gradient norm: $$\|\nabla^2 f_i(w)\| \leq L_0 + L_1 \|\nabla f_i(w)\|$$

To tackle the theoretical challenges of non-uniform smoothness and the bias introduced by random shuffling (as opposed to i.i.d. sampling), the authors:

  1. Developed a novel potential function: They introduced an auxiliary function to handle the misalignment between the update direction and the negative gradient caused by Adam's momentum.
  2. Established trajectory-wise convergence: Unlike previous works that only show "convergence in expectation," this paper proves that Adam converges for every possible shuffling trajectory.
  3. Refined SGD lower bounds: They established a new lower bound for SGD under $(L_0, L_1)$-smoothness to allow for a fair, rigorous comparison with Adam.

Datasets

The paper uses a mix of empirical verification and synthetic tasks:

  • WMT 2014: Used to train a Transformer model to empirically verify that the $(L_0, L_1)$-smooth condition holds in real-world NLP tasks.
  • CIFAR-10: Used with a ResNet-110 architecture to demonstrate Adam's robustness to different random shuffling orders.
  • Synthetic Counterexamples: Specifically designed functions (like the one in Equation 5) to illustrate why Adam converges to a neighborhood of a stationary point rather than an exact point.

Key Insights and Ideas

  • Adaptivity is the "Secret Sauce": Under non-uniform smoothness, Adam's ability to adjust its update magnitude based on local gradient information allows it to navigate volatile landscapes where SGD might struggle or require extreme hyperparameter tuning.
  • The $\beta_2$ Trade-off: The theory reveals that Adam converges to a neighborhood of stationary points. The size of this neighborhood is inversely related to how close $\beta_2$ is to 1. This explains the common practice of setting $\beta_2 = 0.999$; it shrinks the "ambiguity zone" to a negligible size.
  • Adam vs. SGD: The authors show that SGD's convergence rate is bottlenecked by a factor related to the global maximum gradient norm ($M$). Adam’s upper bound is independent of this $M$, providing a theoretical explanation for why Adam often converges faster in practice.
Figure 1: Experiments on the WMT 2014 dataset trained with the transformer. (a): The training loss of SGD and Adam. (b): The gradient norm vs. the local smoothness on the training trajectory. The blue line in (b) stands for log(local smoothness) = log(gradient norm) + 1.4. It can be observed that (𝑒1.4, 0)-smooth condition holds in this task. Similar results can be seen in Zhang et al. [43].

Key Results

  • First Convergence Proof for RR Adam: The authors established the first convergence results for the standard version of Adam without assuming bounded gradients or global smoothness.
  • Provable Advantage: They demonstrated that for functions where curvature grows with the gradient, Adam is rigorously faster than SGD.
  • Robustness: Figure 3 shows that Adam's performance is highly robust across different random seeds and shuffling orders, supporting the "trajectory-wise" convergence theory.
Figure 3: Performance of Adam on CIFAR-10 across 10 different random shuffling orders, showing consistent convergence.

Limitations and Future Work

  • The Role of Momentum: While the paper proves convergence for Adam, the current analysis does not mathematically distinguish between the performance of Adam ($\beta_1 > 0$) and RMSProp ($\beta_1 = 0$). The specific theoretical benefit of the momentum term remains an open question.
  • Higher-Order Smoothness: The authors suggest exploring even more severe smoothness conditions, such as those where curvature grows polynomially (rather than linearly) with the gradient norm.
  • Exact Convergence: Because Adam converges to a neighborhood when noise is present ($D_0 > 0$), it may not reach a perfect zero-gradient stationary point. While this is rarely an issue in machine learning (where we avoid overfitting), it remains a theoretical distinction from SGD.
Figure 2: Experiments showing that while a larger $\beta_2$ makes the limiting gradient norm smaller, Adam typically stabilizes in a neighborhood rather than at zero.

Summary updated

BibTeX
@inproceedings{wang2022provable,
  author = {Bohan Wang and Yushun Zhang and Huishuai Zhang and Qi Meng and Ruoyu Sun and Zhi-Ming Ma and Tie-Yan Liu and Zhi-Quan Luo and Wei Chen},
  title = {{Provable Adaptivity of Adam under Non-uniform Smoothness}},
  booktitle = {ACM SIGKDD Conference on Knowledge Discovery and Data Mining},
  year = {2022},
  url = {https://openreview.net/forum?id=qVGPBG32pf},
}
Figure