Coordinate Descent
Minimises by optimising one variable at a time while holding the others fixed.
The idea
Instead of moving in the gradient direction, cycle through the coordinates and minimise the loss along each axis in turn. When each one-dimensional problem is easy (for example in lasso, where it is a soft-threshold), this is very fast. The path is a staircase of axis-parallel moves.
Watch it run
This is a real computation, not a drawing. Pause, step, change the settings, or try new random data.
- current weights
- minimum
- last update
Start somewhere on the bowl. Rings are lines of equal loss; the minimum is at the centre.
- step:
- 0
- loss:
- 3.4617
Loss landscape seen from above: a long narrow valley. Final loss 0.0005.
Step by step
- 1Start from an initial point.
- 2Pick one coordinate.
- 3Minimise the loss over that coordinate alone.
- 4Move to the next coordinate and repeat.
- 5Stop when a full cycle changes nothing.
Where it is used
Lasso and elastic net, SVM solvers, sparse problems.
Watch out for
Slow when variables are strongly coupled, and it can stall on non-smooth, non-separable objectives.