SAGA: A Fast Incremental Gradient Method With Support for Non-Strongly Convex Composite Objectives
Paper · 2014 · Aaron Defazio, Francis Bach and Simon Lacoste-Julien
Summary
Many machine learning problems ask for a parameter vector that makes the average loss over a dataset as small as possible. A full gradient measures how that average changes, but computing it requires work across the dataset. A gradient from a single example is cheaper and can point in a very different direction. The difference matters near a solution, where the average gradient can be small while the individual gradients remain substantial. SAGA addresses this problem by keeping a record of past gradients and using it to correct each new sample.
The algorithm draws one example at random, calculates its gradient at the current parameters, and subtracts the gradient previously recorded for that example. It adds this difference to the mean of the stored gradients, then takes a step in the resulting direction. The correction has a useful property. Averaged over the possible draws, it gives exactly the current full gradient, even when the stored entries come from different stages of the run. As the parameters and the stored gradients approach their values at a solution, the variation in the corrected direction can also shrink. For an objective with a separate convex penalty, SAGA follows the gradient step with a proximal operation, which balances the penalty against staying close to the proposed point.
The paper proves geometric convergence in expected squared distance to a solution under strong convexity, a condition that gives the loss a uniform lower bound on its curvature. It also proves a bound on expected objective error for the average of the iterates when the losses are smooth and convex without that curvature guarantee. This second result uses a step size set from gradient smoothness. The same choice gives a geometric guarantee when suitable strong convexity is present, even though the step size does not use its value. The proofs cover the separate proximal penalty as well.
The experiments compare SAGA and related methods on binary classification and least squares, with L2 regularization and, where supported, L1 regularization. SAGA behaves similarly to ordinary Finito and SDCA in the reported comparisons. Finito with a permuted order does best when progress is counted in equivalent passes, while SVRG’s favorable showing on that scale becomes more modest when its extra gradient evaluations are counted. The paper’s case for SAGA rests on the combination of its convergence guarantees, the kinds of objectives it handles, and the cost of keeping its gradient records. For losses such as least squares, a record can be a single scalar per example.
Deep dive: SAGA: A Fast Incremental Gradient Method With Support for Non-Strongly Convex Composite Objectives
SAGA speeds up finite-sum optimization by reusing past gradients and handles both nonsmooth penalties and objectives without strong convexity. · about 36 minutes to read
The problem and its context
An average with useful structure
An empirical loss is often assembled from contributions that can be evaluated separately. For a classifier, a contribution describes how well the current parameters account for an example. In least squares, it measures a prediction discrepancy through a squared loss. The optimizer wants to improve the average. Changing the parameters in a direction that helps a particular example can harm other examples, so there is a distinction between the gradient of a term and the gradient of the whole loss.
Full gradient descent uses the average of the component gradients at the same parameter vector. This gives it a direction informed by the whole objective, at the cost of visiting every component for each update. Stochastic gradient descent can update after seeing a single component. With uniform sampling, the sampled gradient averages to the full gradient over the possible choices. This makes the sample useful even when its direction on a particular step differs substantially from the average.
The paper focuses on what happens as those steps approach a solution. In a finite sum, the contributions can balance at an optimum even if many individual gradients are still large. With an ordinary sampled gradient and a fixed step size, different choices can continue to move the parameters in different directions. Reducing the step size shrinks those movements. The paper describes this as the obstacle that motivates variance reduction. The aim is to make the direction itself more consistent as the calculation proceeds, so the step size can stay fixed.
Past evaluations give an optimizer leverage over this problem. Each loss term has an identity, and a later draw can revisit the same term. A previous gradient for that term can serve as a reference for its current gradient. If the two parameter vectors are close, smoothness limits the change in gradient. Even if gradients vary widely from example to example, changes within the same example can be much smaller. An optimizer can exploit that distinction because it is working with a fixed collection of functions. The paper places SAGA among methods that use this finite-sum structure to obtain faster guarantees than would be available from treating the objective as an undivided function.
Smooth loss, curvature, and a separate penalty
The paper assumes each component is convex and has a Lipschitz-continuous gradient. Convexity means that the tangent at a point gives a lower bound on the function. Lipschitz continuity of the gradient limits how quickly that tangent can change as the point moves. It is the smoothness assumption. Strong convexity adds another restriction. The function must rise above its tangent by at least a quadratic amount governed by a positive curvature constant. A loss can have a smooth gradient in every direction and still have directions in which such a uniform quadratic lower bound is unavailable.
That distinction matters for both the algorithm’s inputs and its guarantees. The commonly used quadratic penalty can supply strong convexity. If an optimizer requires strong convexity, adding a small quadratic can make a problem fit the assumptions, but it changes the function being minimized and introduces a regularization amount to choose. The authors seek an algorithm with a direct guarantee for smooth convex losses, including losses for which a positive curvature bound is unavailable.
The objective can also contain a separate convex term that is difficult to differentiate everywhere. An L1 penalty is relevant here because its corners prevent a gradient-based treatment at every point. The paper assumes that a proximal operation for the separate term is easy to evaluate. This operation minimizes the penalty plus a quadratic cost for moving away from a proposed point. It gives the optimizer a way to include the penalty while using smooth gradients for the data terms. An objective written as a smooth average plus a penalty of this kind is what the authors call composite.
These requirements put different demands on an incremental method. The method needs to make progress while consulting only a small portion of the smooth loss on each step. Its analysis needs to account for the randomness of those steps. The penalty needs to fit the same update and proof. A method can have a strong convergence guarantee for one arrangement of the objective and require a different update when the curvature or penalty is placed elsewhere.
The methods the authors build on
The Stochastic Average Gradient method, SAG, keeps a collection of past component gradients and uses their mean after refreshing an entry. It brings information from the entire dataset into an update without recalculating the entire gradient. The resulting direction is biased, meaning that its conditional mean at a given step need not be the current full gradient. The authors treat that bias as a possible reason for the complexity of the SAG proof and for the lack, in the work they discuss, of a comparable proof with a proximal update.
Stochastic Variance Reduced Gradient, or SVRG, uses a common reference point. At that point it computes the full gradient. Between reference updates it corrects a sampled current gradient using the gradient of the same term at the reference point. The correction is unbiased. The related S2GD method uses the same update and differs in its rule for the length of the inner loop. The paper groups the two together for the comparison with SAGA. Their use of a common reference gives them a different balance between storage and computation from a method with a table.
Finito and MISOµ retain past parameter vectors and use their average together with a gradient sum. Their updates make stored points part of the algorithmic state. In the versions discussed, their theory relies on strong convexity. The authors connect their update to an equivalent form of SAGA to show how one can replace the actual mean of those stored points with an auxiliary quantity that follows its expected change.
Stochastic Dual Coordinate Ascent, or SDCA, approaches regularized optimization through a dual problem. A dual update changes a block at a time, and the authors show how to express the exact block update in terms of the original loss functions. That connection makes it easier to compare SDCA with the other methods. It also exposes a different computational requirement. In the exact version, the proximal operation applies to the selected loss term. In SAGA, the selected loss provides a gradient and the proximal operation applies to the separate penalty. The authors also discuss earlier incremental regularized methods and proximal SVRG. The issue they pursue is how to obtain a favorable rate while accommodating the different convex objective forms with the same basic update.
The method, step by step
What the algorithm keeps
Imagine that each training example has a record of what it last told the optimizer about the direction of greatest increase in its loss. Early in the run all those records describe the same initial parameter vector. Later, recently sampled examples describe more recent vectors and other entries can lag behind. SAGA uses the whole collection as a reference. It asks a sampled example how its own gradient has changed, then adds that change to the reference average.
The full target has a smooth part and, in the composite case, a separate convex term. The paper writes the smooth part as an average:
f(x) = (1/n) ∑ᵢ₌₁ⁿ fᵢ(x)
Here x is the parameter vector in a space of dimension d, fᵢ is the smooth convex loss term with index i, and n is the number of terms. The sum runs over all term indices. The common smoothness constant L bounds how fast each term’s gradient can change with x.
F(x) = f(x) + h(x)
Here F is the complete objective, f is the smooth average, and h is the separate convex function of the same parameter vector x. The paper assumes the proximal operation for h is easy to compute. In the case with only a smooth objective, the proximal step leaves its input as it is.
The initial table contains the gradient of every term evaluated at the starting vector. This gives it a well-defined average before the first sample. During iteration, the table is indexed by loss term. The algorithm also uses the current parameter vector and a step size. The paper denotes the point behind each record by a separate symbol. This is bookkeeping for the analysis. Evaluating a new gradient and replacing the old record requires the old gradient itself, so the basic SAGA implementation can dispense with the points behind those records.
A SAGA run with a proximal penalty
The steps in order.
The order in the diagram highlights an important dependency. The direction uses the mean from before the refresh, together with the old and new gradients of the sampled term. An implementation can write the new record earlier if it preserves those quantities for the calculation. If it maintains a running sum of the records, updating that sum requires only the difference between the replacement and the old entry. Summing the entire table for every update would squander much of the advantage of sampling.
One update in detail
Let xᵏ denote the parameter vector at iteration k, before the next random draw. Let φᵢᵏ be the point at which the entry for term i was evaluated. Initially all those points are x⁰, the starting vector. At the next step the optimizer draws an index j uniformly from the terms. The sample identifies both the function to evaluate now and the old gradient to read. The new record for j uses xᵏ. Every other entry carries forward from the previous table.
The gradient stage produces an intermediate point:
wᵏ⁺¹ = xᵏ − γ [∇fⱼ(xᵏ) − ∇fⱼ(φⱼᵏ) + (1/n) ∑ᵢ₌₁ⁿ ∇fᵢ(φᵢᵏ)]
Here wᵏ⁺¹ is the proposal before the penalty is applied, xᵏ is the current vector, and γ is the step size. The symbol ∇ denotes a gradient. The index j picks the same loss function fⱼ in the fresh and stored terms. The sum over i averages the n gradients in the old table, with φᵢᵏ denoting the evaluation point for each entry. The superscripts mark iteration numbers.
The difference in brackets compares values within one loss function. Suppose the sampled example has always had a relatively large slope in some direction. Much of that slope may be present in both its new gradient and its stored one. Subtracting the old entry removes that shared part from the random correction. The table mean then contributes information about the ordinary level of gradients across the dataset. The method still reacts to changes in the selected component, including large changes when a stale entry is refreshed.
To see why the correction has the right mean, fix the current parameters and the gradient table, then consider all possible choices of j. The mean of the fresh term is the gradient of the smooth average at the current point. The mean of the subtracted term is the table mean. That cancels with the explicitly added mean. This calculation holds even if some entries are old. The age and diversity of the entries matter for the variation of the direction, but no assumption about their recency is required for the cancellation.
The next operation incorporates the penalty:
xᵏ⁺¹ = proxₕᵞ(wᵏ⁺¹)
Here xᵏ⁺¹ is the next iterate and wᵏ⁺¹ is the gradient-stage proposal. The symbol proxₕᵞ denotes the proximal operator of the penalty h with step size γ. Its input is a vector in the same parameter space as the iterate.
proxₕᵞ(y) = argminₓ∈ℝᵈ {h(x) + (1/(2γ)) ‖x − y‖²}
Here y is the input vector, ℝᵈ is the space of real parameter vectors of dimension d, and argmin means the value of x that minimizes the expression. The function h assigns a penalty to the candidate vector. The squared Euclidean norm ‖x − y‖² measures the cost of moving away from the input, with γ setting its weight. The search involves the penalty and a quadratic, so its computational difficulty depends on the structure of h.
The full procedure satisfies the right equilibrium condition for a composite problem. At an optimizer, the gradient of the smooth loss can be non-zero because the penalty supplies the countervailing force. The point obtained by moving along the negative smooth gradient and then applying the proximal operation is the same optimizer. This is the fixed point used in the proof. If the iterate is already optimal and every table entry is evaluated there, the sampled difference vanishes, the table supplies the exact smooth gradient, and the composite step stays at the solution.
Why the correction differs from SAG and SVRG
The authors explain the family of updates through a standard sampling idea. Suppose a random quantity is expensive to average directly, and a related random quantity has a known mean. Subtract the related quantity from the sample, then add its mean. When the quantities vary together, their difference can fluctuate less than the original sample. The paper includes a parameter that lets the correction follow the reference more closely at the cost of bias.
θᵅ = α(X − Y) + E[Y]
Here X is a sample of the quantity whose mean is wanted, Y is the correlated reference sample, and E[Y] is the known expectation of that reference. The scalar α ranges from 0 to 1 and controls the size of the difference term. The resulting estimator is θᵅ. For SAGA, X and Y are the new and stored gradients of the same sampled loss.
E[θᵅ] = αE[X] + (1 − α)E[Y]
Here E denotes expectation and θᵅ, α, X, and Y have the meanings just given. The expression shows how the estimator’s mean moves between the target mean and the reference mean. With α set to 1, the reference disappears from the expectation. That gives the unbiased direction used by SAGA.
Var(θᵅ) = α² [Var(X) + Var(Y) − 2 Cov(X,Y)]
Here Var denotes variance and Cov denotes covariance between the sampled quantity X and the reference Y. The estimator θᵅ uses the multiplier α, whose square governs the effect of this random difference on its variance. A sufficiently positive covariance can make the difference less variable than X. Shrinking α lowers the variance of the estimator from the same reference at the cost of bringing its expected value closer to E[Y].
For SAG, α is 1/n. Refreshing a single record contributes only its share of the entire mean. From identical table contents, the SAG direction therefore varies less with the draw, and the paper gives the variance as 1/n² times that of SAGA. SAGA applies the entire sampled change in the update to the parameters. Its running table mean still changes by only the share represented by the refreshed entry. These are separate operations. The scaling of the table maintenance comes from averaging records, while the scaling of the correction determines the estimator’s mean.
SVRG uses α equal to 1, as SAGA does. Its reference entries come from one common point, denoted x̃, and its mean is the full gradient at that point. Over an inner loop, the algorithm preserves the reference. At the beginning of another outer iteration it can change that point and recompute the full gradient. The paper presents the smooth SVRG update as:
xᵏ⁺¹ = xᵏ − γ [∇fⱼ(xᵏ) − ∇fⱼ(x̃) + (1/n) ∑ᵢ₌₁ⁿ ∇fᵢ(x̃)]
Here xᵏ and xᵏ⁺¹ are successive iterates, γ is the step size, j is the sampled index, and ∇fⱼ is the gradient of its loss. The reference vector is x̃. The sum over all n terms gives the full gradient at that vector. A single reference vector and the full gradient there suffice for this form of SVRG. It evaluates a reference gradient as needed while the reference is held fixed.
For SAGA, each reference follows its own update history. The sampled entry moves to the current point every time it is visited. This changes where the work occurs. SVRG has concentrated work at the reference refresh and reevaluates selected reference gradients between refreshes. SAGA initializes and maintains the table, then retrieves its reference gradients from storage. The SVRG inner-loop length is another setting to choose. The authors describe m = n as a conservative choice, with m the number of inner iterations, and say that it falls short of the best practical performance available from tuning that parameter.
A second view of the SAGA state
For the version without a separate penalty, the paper gives a different expression for the very same SAGA iteration. It introduces an auxiliary vector and subtracts a scaled sum of stored gradients from it:
xᵏ = uᵏ − γ ∑ᵢ₌₁ⁿ ∇fᵢ(φᵢᵏ)
Here xᵏ is the iterate recovered from the auxiliary vector uᵏ, γ is the step size, and the sum collects the gradients of all n loss terms at their remembered points φᵢᵏ. The index i identifies a table entry. The starting u⁰ is chosen as the starting iterate plus the scaled sum of the initial gradients, so the relation also holds at initialization.
uᵏ⁺¹ = uᵏ + (1/n)(xᵏ − uᵏ)
Here uᵏ⁺¹ is the next auxiliary vector, uᵏ is its previous value, xᵏ is the current iterate, and n is the number of loss terms. This step moves the auxiliary vector toward the current iterate. The gradient table is then refreshed at a randomly selected entry. Recovering the next iterate with the new sum yields the original smooth SAGA update.
Finito and MISOµ have an update built from an actual average of remembered points and a scaled sum of gradients. Under a uniform draw, replacing a remembered point with the current iterate moves the mean towards that iterate in expectation. The auxiliary-vector update has precisely that expected form. This is the sense in which the authors connect Finito with SAGA. The trajectory of an actual table mean depends on which point was replaced, while the change in u is determined before the draw. The connection explains how SAGA can inherit the form of part of the update and avoid maintaining those individual parameter vectors.
The authors also use SDCA to show how much depends on the job assigned to the selected component. In the primal form of exact SDCA, the current gradient records for the other components determine an input to a proximal calculation on fⱼ. The solution of that calculation gives a new gradient record. A separate strongly convex regularizer supplies the curvature in this version. The equivalence comes from the Moreau decomposition, which relates a proximal operation on a convex function to one on its convex conjugate. A conjugate represents a convex function through the values associated with possible slopes. Converting the proximal calculation in the dual block update to one on the original loss lets the authors express the iteration using primal quantities.
That version of SDCA can be attractive when the proximal operation of the loss is cheap. The authors discuss variants that trade the exact proximal calculation for an interpolation between the stored gradient and the current gradient. Their distinction concerns how the interpolation weight is chosen. A choice based on the smoothness and curvature constants dispenses with operations on the conjugate. A more practical variant, in the authors’ account, uses a line search involving the conjugate. The appendix also describes a version between SDCA and Finito that uses curvature within each loss. Its refreshed point occurs on both sides of the update relation, and a proximal calculation resolves the resulting implicit step.
What storage and sparsity change
A direct implementation of SAGA can save a full gradient vector per term. The paper explains why a full vector is unnecessary for several losses. In logistic regression and least squares, the gradient of a term can be written as its data vector multiplied by a scalar. The data vector is already part of the input. The table can keep the scalar, since the gradient can be reconstructed when the term is sampled. For a classifier with p classes, the authors describe a related representation storing p − 1 values per example. These savings depend on the functional form of the loss and features.
Sparsity introduces a different problem. A term’s current and old gradients may be non-zero only on the coordinates used by the example. The average of the table can still have contributions from many coordinates. Applying that mean to the full parameter vector at every step would make each iteration expensive even when evaluating the sampled term is cheap. The paper’s implementation discussion therefore considers delaying the effect of the mean on coordinates that will be read later.
In the sparse implementation, a coordinate carries information about when it was last brought up to date. Before evaluating a loss on a particular example, the algorithm applies the accumulated changes to the coordinates used by that example. It then reads the updated coordinates for the prediction. The difference between the old and new record can change the table average on those same coordinates. Other coordinates can wait because the new record leaves their average contributions unchanged. At the end, all delayed changes must be applied so the returned vector reflects the completed sequence of steps.
A quadratic penalty can be split evenly into the loss terms to put the curvature in the form required by the componentwise theorem. The paper also describes an implementation with an explicit shrinkage of the parameters:
xᵏ⁺¹ = (1 − γµ)xᵏ − γ [∇fⱼ(xᵏ) − ∇fⱼ(φⱼᵏ) + (1/n) ∑ᵢ₌₁ⁿ ∇fᵢ(φᵢᵏ)]
Here xᵏ and xᵏ⁺¹ are successive iterates, γ is the step size, and µ is the coefficient that gives the quadratic its curvature. The gradients ∇fᵢ refer to the smooth loss terms with the explicit quadratic handled separately. The sampled index is j, the table points are φᵢᵏ, and n is the number of terms. The factor on xᵏ accounts for the gradient of the quadratic penalty.
Multiplying every coordinate by the shrinkage factor at each iteration would also require dense work. The supplementary least-squares and ridge regression example keeps a separate scaling factor for the iterate and updates the factor itself. It combines this representation with delayed coordinate updates. A table of geometric sums accounts for how repeated shrinkage changes the accumulated contributions from the mean. The example uses Cython and stores data points as sparse matrix columns, so each step can access the values and coordinate indices for the selected example.
The paper discusses an initialization heuristic in which a first pass introduces data in a fixed order and averages over terms seen so far. The authors point to its use with SAG. The supplementary least-squares example also uses a fixed order in its first sweep, but starts by preparing the gradient average at its zero initial vector. Later sweeps sample uniformly. These details belong to the implementation discussion. The convergence analysis begins with the table populated at the starting point and takes expectations under uniform draws.
What the proof needs to keep track of
Unbiasedness gives the correct average direction conditionally on the current state. On its own it leaves open how large the individual steps can be and how frequently the memory becomes useful. The proof therefore assigns a measure of error to both the current iterate and the stored information. It uses a Lyapunov function, a non-negative quantity designed to decrease under the update in expectation. Its decrease is easier to show than a decrease in the objective at every step.
A stored point’s contribution measures how far its component loss lies above the tangent taken at a solution. Convexity makes that difference non-negative. Smoothness links the difference to the squared error between the stored gradient and the component gradient at the solution. That link allows the proof to use function values at remembered points as a way to bound the uncertainty caused by old gradients. The relevant comparison is per term, so it remains meaningful when the gradient at the solution varies across the dataset.
Tᵏ = (1/n) ∑ᵢ₌₁ⁿ [fᵢ(φᵢᵏ) − fᵢ(x*) − ⟨∇fᵢ(x*), φᵢᵏ − x*⟩] + c‖xᵏ − x*‖²
Here Tᵏ is the Lyapunov function evaluated at iteration k, x* is an optimizer of F, and xᵏ is the current iterate. The first term averages over the n component functions fᵢ, using the corresponding stored points φᵢᵏ. The angle brackets denote an inner product with the gradient ∇fᵢ(x*). The bracket subtracts the value of the tangent at the stored point from the function value there. The second term uses the squared Euclidean distance and a positive weight c.
A uniform draw replaces one summand in the memory part of this function. In expectation, the old memory contributions shrink in weight and a contribution from the current iterate enters. The iterate part requires a different calculation, since the update includes both the random correction and the proximal operation. The proof uses the fact that the proximal operation is nonexpansive. Applying it to two inputs can preserve or reduce their distance. One input is the proposed step. The other is the proposal obtained by taking a smooth gradient step from the solution, whose proximal output is again the solution.
Expanding the resulting squared distance exposes a term linear in the random step and a term quadratic in it. The conditional mean property simplifies the linear term using the current full gradient. The quadratic term requires a bound on how much the sampled correction can differ from its mean. The authors derive a bound using the errors in the old sampled gradient and the fresh sampled gradient relative to their values at the solution. Their weighted inequality for the sum of two vectors lets the proof control the relative contributions of those errors. It also retains a subtractive term involving the squared difference of the full gradients. The proof then combines the new memory and iterate bounds and chooses constants so that troublesome terms have nonpositive coefficients.
E[Tᵏ⁺¹] ≤ (1 − 1/κ)Tᵏ
Here E denotes expectation over the next index, conditional on the current state, Tᵏ and Tᵏ⁺¹ are the Lyapunov quantities before and after the step, and κ determines the contraction. In the main strongly convex proof, the paper sets 1/κ to γµ, with γ the step size and µ the common strong convexity constant. Repeated application controls the expected value of Tᵏ over the full sequence of draws.
How to read the convergence rates
For the main strongly convex result, each smooth component has strong convexity constant µ and smoothness constant L. The paper takes:
γ = 1/(2(µn + L))
Here γ is the fixed step size, µ measures the curvature lower bound of the components, n is the number of components, and L bounds the change in their gradients. The convergence statement for the parameter vector follows because the Lyapunov function includes its squared distance to the solution with a positive weight.
E[‖xᵏ − x*‖²] ≤ (1 − µ/(2(µn + L)))ᵏ [‖x⁰ − x*‖² + (n/(µn + L))(f(x⁰) − f(x*) − ⟨∇f(x*), x⁰ − x*⟩)]
Here the expectation E is over the draws up to iteration k. The vectors xᵏ, x⁰, and x* are the current iterate, the starting point, and the optimizer of the full objective. The norm is Euclidean, µ and L are the curvature and smoothness constants, and n is the number of losses. The function f is their smooth average. Its gradient ∇f(x*) appears in the inner product that defines the initial smooth loss’s deviation from its tangent at the solution. The factor raised to k gives geometric decay of the bound, also called a linear convergence rate.
The initial bracket combines two measures of how far the calculation has to go. One measures the parameter displacement. The other measures the start’s smooth loss above the tangent from the solution. With a separate penalty, the tangent correction matters because the smooth gradient alone need not vanish at the optimizer. The bound concerns expected squared distance of the actual iterate. It gives a statement about repeated random draws, with no requirement that every draw move the iterate closer.
The authors also state a geometric bound when the smooth average has strong convexity even though the individual terms need only be convex. With step size 1/(3(µn + L)), the stated contraction factor is 1 − µ/(6(µn + L)). The distinction is about where the curvature assumption holds. The theorem with curvature in every component can use more information in the bound on each component gradient. With curvature supplied only by the average, the paper gives a weaker factor.
For convex losses without a positive strong convexity constant, the quantity reported in the guarantee changes. The analysis controls the objective at the average of the iterates reached after initialization:
x̄ᵏ = (1/k) ∑ₜ₌₁ᵏ xᵗ
Here x̄ᵏ denotes the average, k is the number of completed steps, and xᵗ is the vector after step t. The sum starts with the first update, so the initial vector x⁰ is excluded. Averaging belongs to the output used in this guarantee. The algorithm still evaluates each new gradient at its current iterate.
E[F(x̄ᵏ) − F(x*)] ≤ (4n/k)[(2L/n)‖x⁰ − x*‖² + f(x⁰) − f(x*) − ⟨∇f(x*), x⁰ − x*⟩]
Here E averages over all draws up to step k, F is the full objective, and x̄ᵏ is the averaged iterate. The optimizer is x*, the starting vector is x⁰, n counts the components, and L is their common smoothness constant. The squared norm is the initial squared distance. The remaining terms use the smooth average f, its gradient at the solution ∇f(x*), and the inner product with the initial displacement. The bound decays inversely with the number of steps for a fixed problem and starting point.
This proof uses the fixed step size 1/(3L). The authors add weight to the squared distance term in the Lyapunov function and bound that additional term through a proximal inequality that exposes the expected objective gap at the new iterate. The noise term in that inequality is controlled using the zero mean of the gradient estimation error and the errors of the fresh and remembered gradients. Once the coefficients are chosen, summing the expected decreases across iterations leaves the initial Lyapunov value as a bound on accumulated objective gaps. Convexity gives the final step. The objective at the average vector is at most the average of the objective values at the vectors that went into it.
The same step size can also yield geometric decay when the componentwise curvature of the main analysis is present. The paper states the factor as:
1 − min{1/(4n), µ/(3L)}
Here min takes the smaller of the terms in braces, n counts the component functions, µ is the available strong convexity constant, and L is the smoothness constant. This is the factor that is raised to the iteration count in the squared-distance bound. The algorithm uses L to set the step size. The actual curvature enters the analysis of how fast the run can converge, even though its value is absent from that setting. This is the adaptivity the authors claim.
Experiments and results
What was compared
The experiments cover binary classification on MNIST, COVTYPE, and IJCNN1, with least squares on MILLIONSONG. The authors refer readers to the Finito work for dataset details. The tasks supply finite sums for which it is meaningful to compare how much a method improves its optimization progress over a given amount of data access. The reported comparisons concern convergence on those objectives. They give no split-level predictive accuracy or prediction error with which to rank the methods on generalization.
The authors use the same code base for the methods and change the main update rule. This makes the construction of the update the primary difference in the experimental setup. Each method’s step size is chosen for fast convergence in the comparison. SVRG refreshes its reference and recalculates the gradient every n iterations, with n the number of terms in the training objective for the corresponding dataset. The different methods thus share the task and the step-size selection goal, while retaining their characteristic memory and reference operations.
The figure groups the benchmarks by dataset and separates the regularizers. All tested methods support the L2 setting. The L1 setting is shown for a subset of methods, since some of the updates under comparison lack the required support. L2 regularization supplies a quadratic penalty. L1 tests the role of a penalty whose proximal operation can be used directly even where the penalty fails to have a derivative. The L1 comparisons establish which of the tested updates the authors ran in that setting and how those runs progressed. They do not form the same baseline set as the L2 comparisons.
What an equivalent pass measures
The authors describe the plotted progress by epoch equivalent, a scale that groups incremental steps into units comparable in count to passes through the terms. One such unit can involve different total computation across algorithms. A random draw can revisit an example before reaching others, and a method with a reference refresh can do work outside the ordinary incremental steps. Epoch equivalents help compare how fast the objectives improve against a common unit of iteration. They do not determine elapsed time.
Permuted Finito performs best on this scale in the authors’ account. The same account qualifies the comparison by pointing to its potentially greater cost per step. Finito’s use of a permuted access order and its stored variables matter when interpreting why it can have strong progress per pass. The reported position in the curves is a statement about progress on that horizontal scale.
SVRG also progresses quickly per epoch equivalent. The authors report that its gradient evaluations per epoch are double those of the other methods for this problem. When they account for those additional evaluations, they place it in the middle of the comparison. Elsewhere in their discussion of the computational tradeoff, they describe SVRG as making 2x-3x more gradient evaluations for equivalent practical convergence. That is their broader comparison of the cost of using a reference point in place of a table, distinct from the evaluation count they describe for the benchmark runs.
SAGA’s progress is similar to ordinary Finito and SDCA in the reported tests. SAG starts more slowly than the others with the fixed step size used for these runs. The authors say that an adaptive step-size rule is needed to obtain SAG’s best results. The observed early behavior thus belongs to the tested constant-step configuration. The paper’s experimental conclusion is that several methods have similar enough convergence behavior for their storage, objective support, and tuning requirements to matter in the choice.
The numerical comparison in the guarantees
The paper reports its benchmark results as curves and discusses their ordering. The following comparison uses the exact numerical coefficients from its two geometric guarantees for SAGA. In both cases the factor has the form of one minus a curvature-dependent fraction. The metric shown is the coefficient multiplying the common expression µn + L in that fraction’s denominator. Holding the curvature, smoothness, and term count fixed, a smaller denominator coefficient gives a stronger guaranteed contraction. These are analytical settings with different assumptions about curvature.
SAGA geometric guarantees for smooth finite sums, denominator coefficient
The componentwise curvature assumption gives the stronger contraction guarantee.
The numbers
| System or setting | coefficient in the contraction denominator |
|---|---|
| Strong convexity of the average | 6 |
| Strong convexity of every component (this paper) | 2 |
The chart quantifies the difference between two bounds, and its coefficients are independent of any particular experimental dataset. Each guarantee has its own assumptions and step-size prescription. The experiments tune the step sizes for empirical convergence, so the plotted order of algorithms does not directly test the coefficients. Likewise, the headline theoretical comparison with SAG, SVRG, and SDCA concerns bounds. The authors report stronger rates than those for SAG and SVRG and put the strongly convex rate within a factor of 2 of SDCA’s rate under the conditions they compare.
What the ablations show
The paper presents no dedicated component ablation of SAGA. Its evidence about the roles of the pieces comes from algebraic comparisons, convergence proofs under different assumptions, and benchmark comparisons that vary the update, regularizer, or data order. Those kinds of evidence answer different questions. The estimator analysis can isolate the consequence of a specific change with the same table held fixed. The runs show what happens when complete optimizers maintain their own states over many steps.
Bias and variance at a fixed state
The SAG comparison isolates the multiplier on the fresh-minus-stored gradient. Under identical memory, the authors can compare the conditional variance exactly. The paper’s 1/n² variance factor for SAG follows from shrinking the random part of the same direction. At the same time, the mean of that direction shifts towards the old table average. The SAGA multiplier keeps the full gradient as the conditional mean. These are properties of the estimator at a fixed point and table.
This calculation makes clear why lower conditional variance alone does not establish a better optimization update. An estimator can be consistent across sampled indices while leaning toward a direction that reflects earlier iterates. Conversely, an unbiased step can vary substantially if some stored gradients differ greatly from their current values. Over a run, the current vectors and records produced by SAG and SAGA differ. The paper’s fixed-state calculation makes no quantitative prediction for the ratio of their variances once those trajectories diverge.
The proof shows what the unbiasedness buys in the composite analysis. When the squared distance to the optimizer is expanded, the mean of the term linear in the update can be written with the full smooth gradient. The authors then use convexity and smoothness to control it along with the memory error. The proximal operator enters via nonexpansiveness and the fixed point at the solution. This is a demonstrated route from the correction to the theorem. The paper suggests bias as an explanation for the difficulty of extending the available SAG analysis, while stopping short of proving that a biased table method cannot have a proximal convergence theory.
Refreshing one record or a shared reference
The comparison with SVRG isolates another design choice in the algebra. Both directions are unbiased. One uses a different last evaluation point for each example, and the other uses a single point for all examples during an inner loop. Under either design, the aggregate reference gradient restores the mean after the subtraction. Consequently, the common mean property leaves the algorithms free to organize memory and gradient evaluations differently.
The experimental interpretation changes when the extra reference work is counted. On the equivalent-pass scale, SVRG looks competitive with the fastest runs. Counting gradient evaluations moves it towards the middle in the authors’ assessment. This comparison supports the practical significance of bookkeeping the work of an update. It does not isolate a universal overhead because the cost of an evaluation and the value of extra storage depend on the objective and its representation. The fixed refresh interval used in the experiments also ties the observation to a particular SVRG configuration.
Access order, regularizers, and the scope of the comparison
The permuted and ordinary Finito runs provide a comparison between access schedules. The authors discuss reshuffling the examples on each pass and report that Finito and MISOµ have shown speedups of up to 2x with this ordering. They describe smaller empirical gains for other methods. In the benchmark discussion, permuted Finito’s stronger showing per epoch equivalent illustrates how an optimizer’s access schedule can affect the observed ordering of methods. The uniform-sampling proofs for SAGA address a different access process.
The regularizer comparison establishes that the authors tested the construction beyond a quadratic penalty. The L1 case brings the proximal step into practical use and admits only the subset of baselines the authors ran for that penalty. Changing from L2 to L1 changes the objective and may change its curvature, so a difference between the rows cannot identify the effect of the proximal step alone. The paper gives its strongest account of that step through the theorem, which includes the separate convex term from the outset.
The convex and strongly convex analyses provide a comparison of guarantees using the same update. In the convex case, the proof sums expected objective gaps and controls the averaged output. With sufficient curvature, it controls squared distance by a geometric factor. The step size based on L connects the cases because it serves both the general convex theorem and the adaptive strongly convex result. The paper demonstrates this relationship analytically. The benchmark comparisons do not vary known curvature while holding the rest of the objective fixed to measure the adaptation directly.
Limitations
Limits identified by the authors
The memory table is an explicit cost of SAGA. The authors explain why it can be inexpensive for a scalar loss applied to a linear prediction. That saving depends on being able to reconstruct the gradient from a small amount of stored information and the data already in memory. Where the full gradient has to be retained, the cost grows with both the number of examples and the dimension of that gradient. The authors contrast this with SVRG’s use of a shared reference. They also point out that the comparison between storage and extra gradient evaluations can depend on the computer architecture.
The authors identify a further cost for sparse objectives. The average-gradient direction can touch many more coordinates than the sampled example. Maintaining the benefit of sparse data calls for delayed updates, and combining this with quadratic shrinkage makes the implementation more intricate. The supplementary code demonstrates a way to manage these interactions for least squares and ridge regression. Its construction relies on the form of those losses and on the way the quadratic can be handled through a scaling factor.
The paper assumes an efficiently computable proximal operation for the separate penalty. An objective fits the formal decomposition whenever it can be written as a smooth sum plus a convex term, but the useful per-step cost also depends on the work required for that proximal calculation. The authors’ comparison with exact SDCA illustrates the importance of where the operation falls. If it is cheap for each loss and strong convexity comes from the separate regularizer appropriate to that method, SDCA has a viable exact update without a step-size parameter to tune. The SAGA theorem addresses a different set of operations on the pieces of the objective.
The authors give a weaker geometric factor when strong convexity is available only in the average. They also observe that the best practical SVRG behavior calls for tuning the inner-loop length and that SAG’s best behavior calls for adaptive step sizes. The settings used in the experiments leave those qualifications in place. The convergence tests support comparisons of the methods as implemented and run there. Their account also emphasizes that the fastest method on a pass-equivalent scale can have comparatively expensive steps.
Limits visible in the setup
The guarantees concern convex losses with Lipschitz-continuous gradients. A separate nonsmooth penalty is compatible with the method under the proximal assumption. Nondifferentiability inside the sampled loss terms is a different situation, since the update asks for their gradients and the proof uses their smoothness. The discussion of exact SDCA includes the possibility of working through loss proximal operations in such a case. The demonstrated SAGA results do not extend to an arbitrary nonsmooth finite sum.
The results also use different output quantities. For the strongly convex guarantee, the bound is on the expected squared distance of the iterate itself. For the convex guarantee, it is on the expected objective gap of the averaged iterate. A last-iterate objective guarantee in the convex setting would need its own argument. Similarly, an expected bound allows fluctuations on individual runs. The Lyapunov function includes a memory term as well as a point error, so the contraction proof does not imply a monotonic decrease in the measured objective at every step.
The analyzed initialization uses gradients evaluated at a common starting point, and the conditional mean calculation uses uniform sampling. The paper discusses ordered passes and shows a sparse implementation with a deterministic first sweep. These choices raise separate questions about their guarantees. Under a fixed order, the next index is determined by the schedule. Under sampling from what remains in a permutation, it is drawn from a changing subset. The cancellation used for SAGA’s conditional mean is calculated over all indices at each step. The uniform-draw analysis therefore does not itself establish the same factors for a permuted or deterministic schedule.
The benchmark evidence is about optimization on the selected objectives. The description gives the task types, regularizer families, baseline settings, and convergence ordering. It provides no tabulated objective values at common work budgets, uncertainty across repeated runs, or matched elapsed-time results. Converting visual differences into exact effect sizes would require numerical observations that the paper does not state. The tuning description also gives no common tuning budget or selection protocol from which to judge how much the rankings depend on the search for step sizes.
Using a common implementation base makes the update rules easier to compare, but some costs stem from operations that differ intrinsically. Counting gradient evaluations captures an important part of the difference between SAGA and SVRG. It leaves out memory access, the cost of transferring and maintaining stored vectors, and the work of evaluating a proximal operation. The paper’s sparse least-squares example shows that access patterns and the treatment of the regularizer can affect which operations dominate. A claim about runtime on another task would need measurements for that task. Claims about predictive performance would likewise need data splits and evaluation measures beyond the optimization comparisons reported here.
What came after
The later citations span general treatments of optimization and papers on specific learning tasks. The citations establish where SAGA was referenced. The available descriptions identify the subjects of the citing papers, but give no account of how each used the method. They support a distinction between continued attention to the optimization problem and citations from applied work, while leaving direct adoption, modification, and benchmarking unconfirmed.
The two general treatments place the citation in the context of optimization itself. One addresses optimization methods for large-scale machine learning, the setting in which the cost of evaluating and storing gradients motivates SAGA. The other addresses algorithms and complexity for convex optimization, the setting in which the finite-sum structure, smoothness, and curvature assumptions determine the rate that can be proved. The titles indicate the scope of the treatments. The citation relationship alone supplies no specific result either treatment derived from SAGA. Optimization Methods for Large-Scale Machine Learning · Convex Optimization: Algorithms and Complexity
The applied citations include text classification and related work on textual structure. The argument-mining paper concerns structured SVMs and recurrent neural networks. The German news paper concerns fine-grained classification of political bias and reports a dataset and initial experiments according to its title. These citations give two settings in which later authors referred to SAGA. Their descriptions leave open whether the reference was to an optimizer used in training, a baseline, or background on optimization. Argument Mining with Structured SVMs and RNNs · Fine-grained Classification of Political Bias in German News
The readability paper studies assessment using a Transformer and attention together with handcrafted linguistic features. The CausalGym paper benchmarks causal interpretability methods on linguistic tasks. Both cite SAGA, but the descriptions give no specific connection between its gradient table and the experimental procedures in either work. The MedGemma Technical Report also cites the paper, with no stated role for the algorithm. These records document the reach of the citation beyond work devoted to convex optimization. They leave the particular uses of its update and guarantees unspecified. Pushing on Text Readability Assessment · CausalGym · MedGemma Technical Report
Cite
Cite as Aaron Defazio, Francis Bach and Simon Lacoste-Julien. 2014. SAGA: A Fast Incremental Gradient Method With Support for Non-Strongly Convex Composite Objectives. arXiv (Cornell University).
@misc{defazio2014saga,
title = {{SAGA: A Fast Incremental Gradient Method With Support for Non-Strongly Convex Composite Objectives}},
author = {Aaron Defazio, Francis Bach and Simon Lacoste-Julien},
year = {2014},
doi = {10.48550/arxiv.1407.0202},
eprint = {1407.0202},
archivePrefix = {arXiv},
url = {https://doi.org/10.48550/arxiv.1407.0202}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/defazio-2014-saga-fast-incremental-gradient-method/