[Paper Review] AdaScale SGD: A User-Friendly Algorithm for Distributed Training
AdaScale SGD is a user-friendly algorithm that automatically adapts learning rates to large-batch training by dynamically scaling them based on gradient variance, enabling near-perfect linear speed-ups without hyperparameter tuning. It preserves model quality across diverse tasks and batch sizes, outperforming fixed scaling rules like linear or square root scaling, and naturally induces warm-up-like behavior without explicit warm-up phases.
When using large-batch training to speed up stochastic gradient descent, learning rates must adapt to new batch sizes in order to maximize speed-ups and preserve model quality. Re-tuning learning rates is resource intensive, while fixed scaling rules often degrade model quality. We propose AdaScale SGD, an algorithm that reliably adapts learning rates to large-batch training. By continually adapting to the gradient's variance, AdaScale automatically achieves speed-ups for a wide range of batch sizes. We formally describe this quality with AdaScale's convergence bound, which maintains final objective values, even as batch sizes grow large and the number of iterations decreases. In empirical comparisons, AdaScale trains well beyond the batch size limits of popular "linear learning rate scaling" rules. This includes large-batch training with no model degradation for machine translation, image classification, object detection, and speech recognition tasks. AdaScale's qualitative behavior is similar to that of "warm-up" heuristics, but unlike warm-up, this behavior emerges naturally from a principled mechanism. The algorithm introduces negligible computational overhead and no new hyperparameters, making AdaScale an attractive choice for large-scale training in practice.
Motivation & Objective
- To address the challenge of maintaining model quality during large-batch distributed training, where fixed learning rate scaling rules often degrade performance.
- To eliminate the need for manual hyperparameter tuning or heuristic warm-up schedules in large-scale training.
- To develop a principled, adaptive method that scales learning rates based on the intrinsic variance of stochastic gradients.
- To enable reliable, user-friendly large-batch training across diverse machine learning tasks, including image classification, object detection, machine translation, and speech recognition.
- To provide a theoretically grounded alternative to linear or square root learning rate scaling that maintains convergence and model accuracy at scale.
Proposed method
- AdaScale dynamically adjusts the learning rate at each iteration by scaling it inversely with the estimated variance of the stochastic gradient, ensuring that the expected update magnitude remains stable across batch sizes.
- The algorithm maintains invariance of the quantity $\eta_t \mathbb{E}[\|\bar{\mathbf{g}}_t\|^2]$ across scales, which is central to its convergence bound and ensures consistent optimization progress.
- It introduces no new hyperparameters and incurs negligible computational overhead, making it practical for large-scale training systems.
- The method naturally produces warm-up-like behavior in learning rate schedules without requiring explicit warm-up phases, emerging from the adaptive scaling mechanism.
- AdaScale is compatible with standard learning rate schedules (e.g., exponential decay), which it automatically adapts to different batch sizes and scales.
- The algorithm is derived from a theoretical convergence bound that guarantees preservation of final objective values even as batch size increases and iteration count decreases.
Experimental results
Research questions
- RQ1Can a learning rate adaptation strategy be designed that maintains model quality across a wide range of batch sizes without requiring manual re-tuning?
- RQ2How does adaptive learning rate scaling based on gradient variance compare to fixed rules like linear or square root scaling in terms of model accuracy and training speed?
- RQ3Does an adaptive mechanism exist that naturally produces warm-up-like behavior without explicit warm-up hyperparameters?
- RQ4To what extent can AdaScale achieve linear speed-ups in large-batch distributed training while preserving final model performance?
- RQ5Can AdaScale be applied effectively across diverse machine learning tasks, including image classification, object detection, machine translation, and speech recognition?
Key findings
- AdaScale achieves near-perfect linear speed-ups in large-batch training across multiple benchmarks, including ImageNet with a batch size of 32,000 and Transformers with 262,000 max tokens per batch.
- For CIFAR-10, AdaScale maintains model quality across a 13×13 grid of exponential decay learning rate schedules at scale 16, outperforming direct hyperparameter search for scaled SGD.
- Unlike linear scaling with warm-up, which degrades model accuracy as batch size increases, AdaScale preserves validation accuracy even at extreme scales.
- AdaScale’s convergence bound ensures that final objective values are maintained as batch size grows and iteration count decreases, providing theoretical justification for its robustness.
- The algorithm produces warm-up-like learning rate behavior naturally, without requiring explicit warm-up hyperparameters or schedule modifications.
- Empirical results show that AdaScale systematically preserves model quality across diverse tasks and scales, demonstrating its reliability and practicality for real-world distributed training.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.