Skip to main content
QUICK REVIEW

[Paper Review] Super-efficiency of automatic differentiation for functions defined as a minimum

Pierre Ablin, Gabriel Peyré|arXiv (Cornell University)|Feb 10, 2020
Stochastic Gradient Optimization TechniquesComputer Science17 citations
TL;DR

This paper analyzes three gradient estimators for functions defined as a minimum, showing that automatic differentiation (AD) via backpropagation through iterative solvers exhibits super-efficiency: its error scales as the square of the analytic estimator's error. The AD estimator converges faster under sub-linear convergence of the solver, but is computationally more expensive, making the analytic estimator preferable when the solver converges linearly.

ABSTRACT

In min-min optimization or max-min optimization, one has to compute the gradient of a function defined as a minimum. In most cases, the minimum has no closed-form, and an approximation is obtained via an iterative algorithm. There are two usual ways of estimating the gradient of the function: using either an analytic formula obtained by assuming exactness of the approximation, or automatic differentiation through the algorithm. In this paper, we study the asymptotic error made by these estimators as a function of the optimization error. We find that the error of the automatic estimator is close to the square of the error of the analytic estimator, reflecting a super-efficiency phenomenon. The convergence of the automatic estimator greatly depends on the convergence of the Jacobian of the algorithm. We analyze it for gradient descent and stochastic gradient descent and derive convergence rates for the estimators in these cases. Our analysis is backed by numerical experiments on toy problems and on Wasserstein barycenter computation. Finally, we discuss the computational complexity of these estimators and give practical guidelines to chose between them.

Motivation & Objective

  • To compare the asymptotic convergence rates of three gradient estimators for functions defined as a minimum: analytic, automatic differentiation (AD), and implicit estimators.
  • To analyze how the convergence of the iterative solver affects the error of the AD estimator, particularly the role of the Jacobian of the iterates.
  • To provide theoretical convergence rates for the AD estimator under gradient descent and stochastic gradient descent in strongly convex settings.
  • To evaluate the trade-offs between estimation accuracy and computational cost in practical scenarios like Wasserstein barycenter computation.
  • To offer practical guidelines for choosing between estimators based on solver convergence speed and computational budget.

Proposed method

  • Proposes three gradient estimators: analytic (plugging in approximate minimizer), automatic differentiation (backpropagating through the solver), and implicit (using the implicit function theorem).
  • Derives asymptotic error bounds using first-order expansions, showing that the AD estimator's error is o(|zt − z*|), while the analytic estimator's error is O(|zt − z*|).
  • Analyzes the convergence of the Jacobian ∂zt/∂x using tools from Gilbert (1992), establishing bounds for gradient descent and stochastic gradient descent in the strongly convex case.
  • Applies the theoretical framework to a Wasserstein barycenter problem using the Sinkhorn algorithm, comparing estimator performance via mirror descent optimization.
  • Employs numerical experiments on toy problems and real-world applications to validate convergence rates and computational trade-offs.
  • Derives computational complexity comparisons, showing AD is roughly twice as expensive per iteration as the analytic estimator.

Experimental results

Research questions

  • RQ1How do the asymptotic errors of the analytic, automatic differentiation, and implicit gradient estimators compare when the minimizer is approximated via an iterative solver?
  • RQ2What is the dependence of the automatic differentiation estimator's error on the convergence rate of the solver's iterates and its Jacobian?
  • RQ3How do the convergence rates of the gradient estimators differ under gradient descent versus stochastic gradient descent?
  • RQ4In practical optimization settings, when is the super-efficiency of automatic differentiation worth the increased computational cost?
  • RQ5Can the theoretical convergence rates be observed empirically in non-trivial problems like Wasserstein barycenter computation?

Key findings

  • The automatic differentiation estimator exhibits super-efficiency: its error is asymptotically smaller than that of the analytic estimator, scaling as o(|zt − z*|) versus O(|zt − z*|).
  • The error of the implicit estimator scales as O(|zt − z*|²), making it the most accurate asymptotically, but it is computationally more expensive due to solving a linear system at each step.
  • For gradient descent in the strongly convex case, the Jacobian ∂zt/∂x converges linearly, leading to an O(|zt − z*|) error for the AD estimator.
  • For stochastic gradient descent with constant step size, the noise level of the analytic estimator scales as √ρ, while the AD and implicit estimators scale as ρ, confirming faster convergence of AD.
  • With decreasing step size ρt ∝ t⁻⁰·⁸, the AD and implicit estimators converge as O(t⁻⁰·⁸), while the analytic estimator converges as O(√t⁻⁰·⁸), validating the theoretical rates.
  • In the Wasserstein barycenter experiment, AD provides faster error decay per inner iteration, but the analytic estimator is more efficient overall due to lower cost per iteration.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.