SAGA with Arbitrary Sampling

Xun Qian, Zheng Qu, Peter Richtárik

This paper, presented at ICML 2019, provides a significant theoretical and practical upgrade to SAGA, one of the most popular variance-reduced optimization algorithms in machine learning. By introducing SAGA-AS, the authors generalize the SAGA algorithm to support "arbitrary sampling"—allowing for any combination of minibatches and importance sampling. Crucially, they prove that this new variant achieves linear convergence rates even for problems that aren't strictly "strongly convex," matching the performance of state-of-the-art primal-dual methods.

The Problem: Limitations of Standard SAGA

In modern machine learning, we often solve "finite-sum" problems: minimizing the average loss over a massive dataset of $n$ samples. While Stochastic Gradient Descent (SGD) is the standard tool, its inherent "noise" (variance) slows it down near the optimum. Variance-reduced methods like SAGA were designed to fix this, offering much faster (linear) convergence.

However, SAGA had a major theoretical gap. While practitioners wanted to use minibatches (processing multiple samples at once) or importance sampling (prioritizing "harder" samples), the math for SAGA was notoriously difficult to generalize beyond picking one sample at a time uniformly. Previous attempts were either too specific or couldn't handle "nonsmooth" components (like L1 regularization) without strong convexity.

Methods: Introducing SAGA-AS

The authors bridge this gap by introducing SAGA-AS (SAGA with Arbitrary Sampling). The key technical innovations include:

  • Bias-Correcting Random Vectors (BCRV): Standard SAGA uses a gradient estimator that is technically biased. To handle arbitrary sampling, the authors developed a random vector $\theta_S$ that corrects this bias for any chosen sampling strategy, ensuring the gradient estimate remains unbiased.
  • Jacobian Sketching Framework: They utilize a "sketch-and-project" approach to track the gradients of individual functions (the Jacobian). SAGA-AS updates this Jacobian estimate based on whichever samples are selected in a given iteration.
  • New Lyapunov Functions: Proving convergence for SAGA is hard because the "state" of the algorithm includes a massive table of stored gradients. The authors constructed new stochastic Lyapunov functions (mathematical tools to track progress) that allowed them to prove convergence for this much more complex, generalized version.

Key Insights and Theoretical Advances

  • Closing the Primal-Dual Gap: For years, the dual-space method Quartz was the only algorithm with a clean "arbitrary sampling" analysis. This paper shows that SAGA (a primal-space method) can match those same theoretical rates, simplifying the landscape of optimization theory.
  • Linear Convergence Without Strong Convexity: Most fast algorithms require "strong convexity" to guarantee linear convergence. SAGA-AS is shown to converge linearly under a much broader "quadratic functional growth" condition. This is a big deal for practitioners working with models that are convex but not strongly convex (like standard logistic regression without heavy L2 regularization).
  • The "Best" Correction: The paper doesn't just say a bias correction exists; it identifies the optimal bias-correcting vector that minimizes the theoretical complexity bound for a given sampling strategy.

Experimental Results

The authors evaluated SAGA-AS on standard binary classification datasets from the LIBSVM repository, including w8a, a9a, and ijcnn1.

Importance Sampling and Linear Speedups

In experiments, SAGA-AS with importance sampling (SAGA-IP) achieved nearly linear speedups. For example, increasing the minibatch size by a factor of 50 only increased the number of required epochs marginally. Furthermore, the results clearly demonstrate that importance sampling significantly outperforms uniform sampling (SAGA-UNI), often requiring fewer total passes over the data even when using large minibatches.

Comparison of SAGA with Importance Sampling (SAGA-IP) vs Uniform Sampling (SAGA-UNI) across different minibatch sizes.

SAGA vs. Coordinate Descent

The authors also demonstrated that SAGA-AS is much more efficient than Coordinate Descent (CD) when the number of samples ($n$) is significantly larger than the number of features ($d$), which is the typical "big data" regime.

SAGA-AS demonstrates vastly superior efficiency compared to Coordinate Descent (CD) on the ijcnn1 and a9a datasets.

Limitations and Future Work

While SAGA-AS is a powerful step forward, it has a few limitations:

  • Convexity Constraint: The analysis is strictly for convex problems. While many ML tasks fit this (Logistic Regression, SVMs, Lasso), it does not directly apply to deep learning's non-convex landscapes.
  • Parameter Knowledge: While the algorithm can work without knowing the strong convexity parameter $\mu$, the "optimal" step size still depends on knowing the smoothness constants ($L_i$) of the individual functions, which may not always be easy to estimate.

A natural next step for future research would be extending this arbitrary sampling framework to non-convex variance-reduced methods or exploring asynchronous parallel implementations where different workers use different sampling strategies.

Summary updated

BibTeX
@inproceedings{qian2019saga,
  author = {Xun Qian and Zheng Qu and Peter Richtárik},
  title = {{SAGA with Arbitrary Sampling}},
  booktitle = {International Conference on Machine Learning},
  year = {2019},
  url = {https://openreview.net/forum?id=HJNsKiZd-H},
}
Figure