AdamW 2026-11-05
AdamW combines the adaptive update of Adam with decoupled weight decay. It maintains exponentially weighted histories of the supplied data gradient and its componentwise square, while applying parameter shrinkage separately. Ilya Loshchilov and Frank Hutter presented the method in their work on decoupling decay from gradient-based regularization.[ref]
For minimization without optional algorithm variants, initialize . In the convention documented by PyTorch, step uses
The product is a Hadamard product; square roots and division are also coordinatewise. Assume , and the stated learning rate . The decay coefficient is . This explicitly fixes epsilon placement and the decay convention.[ref]
The denominators and perform Adam bias correction for zero-initialized histories. For a constant supplied scalar gradient , the corresponding geometric sums give and . Their corrected values are therefore and . The squared-gradient quantity concerns a raw second moment, rather than a centered variance: a constant gradient of 2 has square 4 even though its variance is zero.
For an original first-step example, choose , , , , , and . Then
and
The constants are chosen for transparent arithmetic. Feeding into the same adaptive formulas instead, with no separate shrinkage, would give approximately . That coupled L2 regularization also changes the stored histories. Resuming AdamW therefore requires the relevant optimizer state and step count as well as the parameter values and settings.
Frank Hutter 2026-11-05
Frank Hutter researches automated design and configuration of algorithms and machine learning systems. His work asks how experimental measurements of an algorithm's performance can guide the search for better settings, replacing some manual trial and error with an explicit computational procedure.[ref]
Hutter and colleagues developed ParamILS, an algorithm configuration framework described in 2009. It searches settings of a target algorithm and limits unpromising evaluation runs to use the experimental budget more effectively.[ref] A useful example is a solver with several search settings: choosing a setting changes the procedure used on the next problem instance, rather than changing that instance's answer. Performance measured on the tuning instances should therefore be checked on separate instances before claiming a general improvement.
With Ilya Loshchilov, Hutter also introduced the decoupled weight decay mechanism underlying AdamW. Their analysis showed why using coupled L2 regularization and directly shrinking parameters cease to be equivalent under general adaptive gradient scaling.[ref] This contribution connects algorithm design to a precise update equation: an option called weight decay can describe different mathematical operations in different optimizers.
Figure 1.
Frank Hutter, portrait linked from his Freiburg Machine Learning Lab profile
.
Ilya Loshchilov 2026-11-05
Ilya Loshchilov is a researcher in optimization and machine learning whose work with Frank Hutter includes SGDR and AdamW. His Freiburg institutional profile identifies the same author and lists the two papers; it is an alumni record, rather than evidence of a current appointment.[ref]
Their 2017 SGDR paper introduced a learning rate schedule that decreases the rate along a cosine curve, then raises it at a warm restart while retaining the current parameters. In one cycle,
Here is elapsed cycle progress and its length. With and , the rates at are . Raising the rate starts another exploration from the learned parameters; it does not reinitialize the model.[ref]
Their 2019 AdamW work separates decoupled weight decay from the gradient-based update. For ordinary gradient descent, adding gives . Coordinate-dependent scaling can act differently on the penalty contribution, so that equivalence does not extend unchanged to an adaptive gradient method.[ref] Writing the equation makes the contribution clearer than comparing optimizer names alone.
Figure 1.
Ilya Loshchilov, portrait linked from his Freiburg Machine Learning Lab alumni profile
.
SGDR 2026-11-05
SGDR means stochastic gradient descent with warm restarts. Its learning rate schedule repeatedly lowers the learning rate along a cosine curve, then raises it to begin another cycle while retaining the current parameters. Ilya Loshchilov and Frank Hutter's method uses this warm restart to continue an existing optimization trajectory.[ref]
In cycle , let be elapsed training time since the last restart and the cycle duration, measured in the same units. The cosine learning rate schedule is
It starts at , reaches the midpoint of the two bounds at , and reaches at the cycle endpoint. The original implementation updates the elapsed training epoch count within each mini-batch, allowing fractional epoch progress.[ref]
For an original schedule, choose bounds 0 and 0.1, initial duration epochs and duration multiplier 2. The successive cycle lengths are 4, 8 and 16 epochs, with restart boundaries at total elapsed times 4, 12 and 28. In the first continuous cycle, the rates at are respectively .
Figure 1.
Cosine learning-rate cycles with doubling restart periods
. Own chosen schedule with bounds0 and0.1 and durations4,8,16epochs. Open markers show end-of-cycle limits; filled markers show the rate after restart. The figure plots a schedule, not measured training performance. Details.
A discrete convention must specify which update uses the endpoint. For example, sampling phases in the first cycle and restarting before the next step gives rates approximately , followed by . The zero endpoint in the continuous curve is then a limit, rather than an additional zero-rate optimizer step.
Retaining parameters also has a concrete meaning. In an original deterministic gradient descent example with and current , resetting only the schedule leaves . The next step at learning rate0.1 gives0.45; a step at0.01 would give0.495. The restart changes the next movement rather than drawing a new initial parameter. Handling a momentum buffer is a further state convention; restarting the schedule and discarding all optimizer state are different operations. Record cycle phase, durations and rate bounds with an optimization checkpoint.