The Mathematics of Gradient Descent
The Largest Step a Curvature Will Tolerate
Last timeWhere the Gradient Comes From
On a quadratic the learning rate has an exact ceiling, and the loss curve of a run that exceeds it looks nothing like a run that is merely slow.
The previous two lessons produced a direction. A direction is not a step: it
has no length. Choosing the length is the one decision in training that a
practitioner still makes by hand, and it is the one with the sharpest
mathematics behind it.
The only function worth analysing
Take the simplest function with a minimum and some curvature, in one variable:
This looks too simple to be informative. It is not, for a reason worth being
explicit about. Expand any smooth function around its minimum . The
constant term is irrelevant to the update, the linear term is zero because the
gradient vanishes at a minimum, and what is left is the quadratic term plus
something that shrinks faster than quadratically. So near the bottom, every
loss is this function, with standing for the second derivative there.
The question of how large a step to take only becomes urgent near a minimum, so
the quadratic is the case that matters.
The lesson stops here
10 more paragraphs to go
You have read the opening. The rest of the argument, the problems that check whether it landed, and the lines worth keeping at the end all come with a plan.
The first lesson of every course in the library reads the whole way through, free, so you can see exactly what the rest of them are.
See the planThe contentsThis is the reading half
Starting the course gives you your own copy of it. Every idea on every page has problems standing under it, marked with a reason rather than a tick, and any sentence you do not believe can be opened and argued with. None of that can happen on a page nobody owns.
The contents