Stochastic compositional gradient descent: algorithms for minimizing compositions of expected-value functions

Mengdi Wang, Ethan X. Fang, Han LiuMath. Program 2017 · DOI

TL;DR

This paper introduces Stochastic Compositional Gradient Descent (SCGD), a novel class of algorithms designed to optimize functions that are compositions of expected-value functions. This is a significant advancement because traditional methods struggle with this "two-level" stochasticity, and SCGD offers provable convergence guarantees for a wide range of problems, including those that are nonsmooth or nonconvex.

What Problem Does This Paper Address?

Many real-world optimization problems involve minimizing a function that itself depends on an expected value, or even a composition of two such functions. A common example is minimizing $F(x) = E_v[f_v(E_w[g_w(x)])]$, where $f_v$ and $g_w$ are functions that depend on random variables $v$ and $w$. Traditional stochastic gradient descent (SGD) methods, which are highly effective for minimizing single expected-value functions ($E[f(x)]$), fail here because they require unbiased gradient estimates, which are not directly available when dealing with nested expectations. The core challenge is the "two-level stochasticity" – randomness in both the inner function ($g_w(x)$) and the outer function ($f_v(\cdot)$) – which breaks the assumptions of standard SGD. This problem arises in diverse fields like risk-averse optimization, dynamic programming, and statistical learning.

Methods

The authors propose Stochastic Compositional Gradient Descent (SCGD), a family of algorithms that tackle the nested expectation problem. SCGD employs a two-timescale approach:

  1. Estimating the inner function's expectation: An auxiliary variable, $y_k$, is maintained to track the expected value of the inner function, $E_w[g_w(x)]$. This variable is updated using a weighted average of past noisy samples of $g_w(x)$.
  2. Updating the main variable: The primary optimization variable, $x_k$, is updated using a stochastic quasi-gradient step. This step involves a noisy gradient of the outer function $f_v$ evaluated at the estimated inner function value $y_k$, and a noisy gradient of the inner function $g_w$ evaluated at $x_k$.

The paper also introduces an accelerated SCGD variant. This version incorporates an extrapolation step before querying the sampling oracle. This extrapolation helps to reduce bias in the gradient estimates, leading to faster convergence, especially for smooth objective functions. The theoretical analysis relies on coupled supermartingale convergence lemmas to handle the interplay between the two error sequences (one for $x_k$ and one for $y_k$).

Datasets

Not discussed in the paper. The paper focuses on theoretical analysis and algorithmic development, with numerical experiments conducted on synthetic data generated from specific models (Sparse Additive Model and a Stochastic Shortest Path Problem).

Key Insights and Ideas

  • The "two-level stochasticity" is the key difficulty: The paper clearly articulates why standard SGD fails for compositional objectives, highlighting the challenge of obtaining unbiased gradient estimates for nested expectations.
  • Two-timescale approach is crucial: The SCGD algorithm's success hinges on its ability to simultaneously track the unknown inner expectation and perform gradient descent on the outer function. This requires careful management of two interacting stochastic processes.
  • Averaging improves stability and convergence: Similar to classical stochastic approximation, averaging iterates (via the $y_k$ variable and averaged $x_k$) is essential for achieving almost sure convergence and better rates.
  • Smoothness offers acceleration: The accelerated SCGD demonstrates that exploiting the smoothness of the objective functions can significantly improve convergence rates, a common theme in optimization theory.
  • SCGD is a general framework: The authors show that SCGD can be applied to a broad range of problems, including nonsmooth and nonconvex settings, and can be extended to derivative-free optimization.

Key Results

The paper provides theoretical guarantees for the SCGD algorithms:

  • Almost Sure Convergence: For convex problems, SCGD converges to an optimal solution with probability 1. For nonconvex problems, it converges to a stationary point with probability 1.
  • Convergence Rates:
    • Basic SCGD: Achieves $O(k^{-1/4})$ for general convex problems and $O(k^{-2/3})$ for strongly convex problems (non-smooth). For smooth problems, rates improve to $O(k^{-2/7})$ and $O(k^{-4/5})$ respectively.
  • Accelerated SCGD: Achieves $O(k^{-2/7})$ for general convex problems and $O(k^{-4/5})$ for strongly convex problems.
  • Sample Complexity: The paper provides benchmarks for sample error complexities, showing that SCGD requires only a sub-quadratic number of samples to achieve small optimization errors, despite the two levels of expectation.
  • Numerical Validation: Experiments on synthetic data (Sparse Additive Model and Stochastic Shortest Path Problem) demonstrate that SCGD algorithms converge and that the accelerated version is faster.

Limitations and Future Work

  • Sample Complexity vs. Classical SGD: While SCGD achieves good rates, they are still slightly inferior to the optimal rates for simpler problems (like $O(k^{-1/2})$ for general convex problems without composition). The authors conjecture that the compositional structure inherently makes the problem harder.
  • Future Work:
    • Lower Bounds: Investigating lower bounds for sample error complexity for compositional problems to determine if current rates are improvable.
  • More Complex Compositions: Extending SCGD to problems involving compositions of more than two stochastic functions.
  • Derivative-Free Extensions: Further exploring and analyzing derivative-free versions of SCGD.
  • Adaptive Sampling: Combining SCGD with adaptive Monte Carlo sampling for improved efficiency in specific applications like rate function estimation.

Summary updated

BibTeX
@article{wang2017stochastic,
  author = {Mengdi Wang and Ethan X. Fang and Han Liu},
  title = {{Stochastic compositional gradient descent: algorithms for minimizing compositions of expected-value functions}},
  journal = {Math. Program.},
  year = {2017},
  doi = {10.1007/s10107-016-1017-3},
}
Figure