On the Convergence of Stochastic Gradient Descent in Low-precision Number Formats

Matteo Cacciola, Antonio Frangioni, Masoud Asgharian, Alireza Ghaffari, Vahid Partovi Nia

TL;DR

This paper investigates the convergence of Stochastic Gradient Descent (SGD) when computations are performed using low-precision floating-point numbers, a common practice for efficiency in deep learning. The authors provide theoretical bounds and experimental evidence showing how numerical errors introduced by low precision affect convergence, offering insights into how much precision can be reduced without compromising performance.

What Problem Does This Paper Address?

Deep learning models have become ubiquitous, and training them often relies on Stochastic Gradient Descent (SGD). Traditionally, SGD computations are done using single-precision floating-point numbers, which offer a good balance between accuracy and performance. However, as deep learning models grow exponentially in size (as illustrated in Figure 1), there's a strong push to use even lower precision formats (like Bfloat, float16, int8) to reduce computational cost, memory usage, and energy consumption. The challenge is that these low-precision formats introduce numerical errors, which can potentially disrupt the theoretical convergence guarantees of SGD that hold for real numbers. This paper aims to bridge this gap by analyzing SGD's convergence behavior under these low-precision constraints.

Methods

The core of this paper lies in its theoretical analysis of SGD convergence. The authors extend existing deterministic and stochastic analysis of SGD to account for numerical errors introduced by low-precision computations. They analyze quasi-convex loss functions, a broader class than strictly convex functions, which is more representative of real-world deep learning loss landscapes (as hinted at by Figure 2).

Key methodological contributions include:

  • Deterministic Analysis: Developing bounds for SGD convergence that explicitly incorporate errors from both weight updates and gradient computations. This analysis leads to identifying optimal learning rates that minimize these error bounds.
  • Stochastic Analysis: Extending the deterministic analysis to a stochastic setting, considering noisy quasi-subgradients and computational errors. This provides convergence guarantees under more relaxed assumptions.
  • Theoretical Framework: The analysis is grounded in the concept of Hölder continuity for loss functions, allowing them to derive bounds that depend on the function's properties and the magnitude of the numerical errors.

Datasets

  • MNIST: Used for evaluating logistic regression models.
  • CIFAR10: Used to illustrate the concept of quasi-convex regions in loss landscapes (Figure 15).

Key Insights and Ideas

  • Low Precision Isn't Free: While low-precision computations offer efficiency, they introduce numerical errors that directly impact SGD's convergence. The paper quantifies this impact.
  • Quasi-Convexity Matters: The authors extend the analysis to quasi-convex functions, which are more general than convex functions. This is motivated by the observation that loss landscapes in deep learning can be non-convex, and quasi-convex regions are often larger than strictly convex ones, making the analysis more broadly applicable.
  • Weight Update Precision is Crucial: Experiments suggest that the precision of weight updates might be more critical for convergence than the precision of gradient computations alone.
  • Accumulator Size is Key: The precision of accumulators used in low-precision arithmetic significantly affects numerical errors and, consequently, SGD convergence. Larger accumulator sizes lead to better convergence.

Key Results

  • Theoretical Bounds: The paper derives new deterministic and stochastic bounds for SGD convergence in the presence of numerical errors. These bounds explicitly show the effect of precision on convergence.
  • Optimal Learning Rates: Corollaries are provided for optimal learning rates that minimize the derived error bounds, offering practical guidance.
  • Experimental Validation: Experiments on logistic regression with MNIST dataset and a simple quasi-convex function confirm the theoretical findings. The results show that the loss trajectory converges to a point near the optimum, and the derived bounds hold.
  • Impact of Bfloat: Experiments using Bfloat format demonstrate how reduced precision affects convergence, with findings suggesting that accumulator size plays a vital role in mitigating numerical errors.

Limitations and Future Work

  • Experimental Scope: The authors acknowledge that their experiments, while promising, are primarily on logistic regression and a simple quasi-convex function. They suggest that extending these experiments to more complex deep learning models is a crucial future direction.
  • Generalization to Non-Quasi-Convex Functions: The current analysis is limited to quasi-convex functions. Real-world deep learning loss landscapes can be highly non-convex, and extending the analysis to such scenarios would be valuable.
  • Specific Hardware Architectures: The paper focuses on the theoretical impact of low-precision arithmetic. Future work could explore how specific hardware implementations and their unique error characteristics influence convergence.

Summary updated

BibTeX
@inproceedings{cacciola2026convergence,
  author = {Matteo Cacciola and Antonio Frangioni and Masoud Asgharian and Alireza Ghaffari and Vahid Partovi Nia},
  title = {{On the Convergence of Stochastic Gradient Descent in Low-precision Number Formats}},
  booktitle = {Proceedings of the 12th International Conference on Pattern Recognition Applications and Methods},
  year = {2026},
  url = {https://openreview.net/forum?id=h48lANFHQ5},
}
Figure