Abstract
Classical optimization theory often relies on the assumption of global Lipschitz smoothness, a condition frequently violated by modern deep learning architectures such as Transformers and LSTMs. This paper investigates why Adam-style optimizers remain robust in these "unbounded smoothness" regimes even without explicit gradient clipping. We introduce a coordinate-wise $(L_0, L_1)$ smoothness framework and a Generalized SignSGD algorithm to demonstrate that momentum provides a natural "implicit clipping" effect. Our findings explain the empirical success of sign-based optimizers and provide a theoretical foundation for their stability in the presence of exploding gradients.
Introduction
In the landscape of mathematical optimization, the standard convergence proofs for Stochastic Gradient Descent (SGD) typically hinge on the assumption that the objective function is smooth—specifically, that its gradient is Lipschitz continuous. In practical terms, this implies that the slope of the function does not change abruptly. However, modern architectures like Recurrent Neural Networks (RNNs) and Transformers often exhibit "unbounded smoothness," where the rate of change in the gradient (the Hessian) grows in proportion to the gradient itself. This phenomenon is the mathematical driver behind the notorious "exploding gradient" problem.
While practitioners traditionally mitigate this instability using manual gradient clipping, the popular Adam optimizer often succeeds on large-scale Transformers without such interventions. This paper addresses this discrepancy, proposing that the inherent structure of Adam-like optimizers—specifically their sign-based update mechanism and use of momentum—provides a built-in robustness to the very instabilities that derail vanilla SGD.
Theoretical Framework: Coordinate-wise Smoothness
To model the complex loss landscapes of modern networks, we refine the recently proposed "relaxed smoothness" condition into a Coordinate-wise $(L_0, L_1)$ Smoothness assumption. Rather than evaluating the global gradient norm, we analyze smoothness at the level of individual parameters.
Empirical analysis of Transformers reveals that different layers, and even different parameters within the same layer, exhibit vastly different smoothness behaviors. By adopting a coordinate-wise lens, we can more accurately capture the local geometry of the loss surface, proving that Transformers do indeed satisfy this $(L_0, L_1)$ condition even when global Lipschitz constants are undefined.
The Generalized SignSGD Algorithm
We introduce Generalized SignSGD as a theoretical bridge between standard SignSGD (which utilizes only the direction of the gradient) and Adam. While Adam scales updates using a moving average of squared gradients ($g_t^2$), Generalized SignSGD utilizes the moving average of the momentum squared ($m_t^2$).
This subtle shift allows for a rigorous convergence analysis. We prove that this algorithm handles unbounded smoothness gracefully by leveraging momentum as a stabilizer. In the presence of exploding gradients, momentum acts as an "implicit clipper," exponentially reducing the impact of sudden noise and preventing the update size from reaching catastrophic levels.
Experimental Results
We validated the Generalized SignSGD algorithm and our theoretical insights across several benchmarks, comparing performance against Adam and clipped SGD variants.
Image Classification and Language Modeling
On CIFAR-10 using a 20-layer ResNet, Generalized SignSGD achieved a test accuracy of 88.35%, slightly outperforming Adam's 88.23%. In language modeling tasks using an AWD-LSTM on the Penn Treebank (PTB) and GPT-2 on Wikitext-103, the algorithm showed similar parity with established optimizers.
Machine Translation
The advantages of the proposed approach were most evident in high-complexity tasks. On the WMT’16 (German-English) translation task using a 6-layer Transformer, Generalized SignSGD achieved a test perplexity of 7.27, significantly outperforming Adam’s 8.90.
Redundancy of Manual Clipping
Our theory suggests that for sign-based optimizers, manual gradient clipping is often redundant. We confirmed this empirically by training GPT-2 on Wikitext-103; adding manual clipping to the optimizer had virtually no impact on training loss or final perplexity, supporting the conclusion that the optimizer’s internal dynamics already manage unbounded smoothness.
Discussion and Limitations
While Generalized SignSGD provides a robust framework for understanding modern optimization, several challenges remain:
- Weight Decay Sensitivity: All tested optimizers showed high sensitivity to weight decay parameters, with the "optimal" value varying significantly between algorithms. This suggests a need for scale-free regularization methods.
- The $\beta_2$ Parameter: Theoretical analysis suggests that setting $\beta_2 = 0$ (recovering SignSGD with momentum) yields the best worst-case convergence. However, in practice, values closer to 1 (as used in Adam) often yield better results. Reconciling this gap between theory and practice remains an open question.
- Architectural Origins: While we have proven that Transformers satisfy the $(L_0, L_1)$ condition, the specific roles of Attention mechanisms or Layer Normalization in creating this smoothness profile require further investigation.
Conclusion
This work clarifies the "mystery" of why Adam-style optimizers excel in deep learning without the need for manual gradient clipping. By treating Adam as a sign-based optimizer in disguise and recognizing the implicit clipping effect of momentum, we provide a more robust theoretical foundation for the optimization of modern, non-smooth architectures.
Summary updated