Gradients without Backpropagation
Atılım Güneş Baydin, Barak A. Pearlmutter, Don Syme, Frank Wood, Philip Torr
TL;DR
This paper tackles the dominance of backpropagation in gradient based ML training by proposing forward gradient descent, an unbiased gradient estimation method computed entirely with forward mode automatic differentiation. The core idea is to replace the true gradient with a forward gradient g(θ) = (∇f(θ)·v) v where v is a random direction with independent zero-mean unit-variance components, yielding an unbiased estimator of the gradient. The authors provide a formal unbiasedness proof, implement a forward mode AD engine in PyTorch, and compare forward gradient descent to standard backpropagation across logistic regression, MLPs, and CNNs, observing substantial speedups (up to about 2x) with comparable memory usage and learning performance. The findings suggest that gradient based ML pipelines can operate without backpropagation, opening avenues for faster training, different hardware tradeoffs, and potential insights into biological learning mechanisms.
Abstract
Using backpropagation to compute gradients of objective functions for optimization has remained a mainstay of machine learning. Backpropagation, or reverse-mode differentiation, is a special case within the general family of automatic differentiation algorithms that also includes the forward mode. We present a method to compute gradients based solely on the directional derivative that one can compute exactly and efficiently via the forward mode. We call this formulation the forward gradient, an unbiased estimate of the gradient that can be evaluated in a single forward run of the function, entirely eliminating the need for backpropagation in gradient descent. We demonstrate forward gradient descent in a range of problems, showing substantial savings in computation and enabling training up to twice as fast in some cases.
