Abstract
Adaptive gradient methods such as RMSProp and Adam use exponential moving estimates of the squared gradient to compute adaptive step sizes, achieving better convergence than SGD in the face of noisy objectives. However, Adam can have undesirable convergence behaviors due to unstable or extreme adaptive learning rates. In this paper, we propose an adaptive learning rate principle, in which the running mean of squared gradient in Adam is replaced by a weighted mean, with weights chosen to maximize the estimated variance of each coordinate. This results in a faster adaptation to the local gradient variance, which leads to more desirable empirical convergence behaviors than Adam. We demonstrate the improved efficacy of our adaptive averaging approach on machine translation, natural language understanding, and large-batch pretraining of BERT.
Introduction
Stochastic Gradient Descent (SGD) and adaptive methods like Adam are the workhorses of deep learning. Adam works by keeping an exponential moving average (EMA) of past squared gradients (the "second moment") to compute coordinate-specific learning rates. It typically uses a constant decay rate (denoted as $\beta$) to weight these past gradients.
However, this constant $\beta$ can be a liability. When gradients have heavy-tailed noise—a common issue when training Transformer architectures—Adam's learning rates can become unstable or extreme, causing the model to overshoot optimal parameters or fail to converge. Previous attempts to fix this, like AMSGrad or AdaBound, often underperform standard Adam in practical, large-scale tasks. The authors sought a way to make adaptive learning rates highly responsive to sudden gradient changes without losing stability.
The Maximum Variation Averaging (MaxVA) Principle
The authors propose Maximum Variation Averaging (MaxVA). Instead of using a fixed, constant $\beta$ to average the squared gradients, MaxVA calculates a dynamic $\beta_t$ at every training step for every parameter coordinate. The core mechanism is to choose the $\beta_t$ that maximizes the estimated variance of the gradient.
By maximizing variance, the optimizer acts as a smart shock absorber:
- Large Gradients: If a gradient suddenly spikes, MaxVA assigns it a higher weight. This increases the variance estimate, which in turn shrinks the adaptive step size to prevent overshooting.
- Flat Regions: If the gradient is abnormally small, it adapts to take a larger step, helping the model escape spurious, flat local minima.
- Convergence: If the gradient is stable, it defaults to a steady step size to ensure convergence.
Experimental Evaluation
The authors evaluated their methods across a wide spectrum of tasks, integrating the mechanism into Adam (creating MAdam) and LaProp (creating LaMAdam).
Image Classification and Translation
Historically, adaptive methods lag behind carefully tuned SGD in image classification. MaxVA significantly closes this gap. On ImageNet (ResNet18), LaMAdam achieved 70.16% top-1 accuracy, nearly matching exhaustively fine-tuned SGD (70.18%) and vastly outperforming standard Adam (66.54%). In machine translation (IWSLT'14 DE-EN), LaMAdam reached a BLEU score of 36.09, outperforming LaProp and AdaBelief.
Large-Batch BERT Pretraining
In large-batch pretraining (like BERT), the total number of update steps is drastically reduced. Because there are fewer steps, adapting quickly to the loss landscape's curvature in each individual step becomes critical. In a massive-batch setting (up to 64K), MAdam converged faster and achieved a lower training loss (1.492) than both LAMB (1.507) and Adam (1.568).
Conclusion
MaxVA provides a robust framework for stabilizing adaptive learning rates by maximizing observed gradient variance. Empirical results across vision and NLP tasks demonstrate that MAdam and LaMAdam offer superior convergence and generalization compared to standard adaptive optimizers, making them highly effective for training modern, large-scale deep learning models.
Summary updated