Papers
Topics
Authors
Recent
Search
2000 character limit reached

AdamW Timescale Framework

Updated 19 January 2026
  • AdamW Timescale is a conceptual framework that interprets the weight decay hyperparameter as controlling an exponential moving average (EMA) timescale, defining memory and regularization characteristics.
  • The framework provides explicit scaling rules, indicating that weight decay should decrease inversely with dataset size and increase linearly with model width under μP scaling.
  • Empirical studies on models like ResNet-18, ViT, and NanoGPT validate that maintaining a constant EMA timescale leads to robust generalization and consistent convergence across varying training conditions.

AdamW timescale designates the conceptual and practical framework linking the weight decay hyperparameter in AdamW (decoupled weight decay Adam) to an underlying exponential moving average (EMA) timescale, providing explicit scaling rules for optimizer configuration across model and data scales. Underlying this framework are key theoretical, algorithmic, and empirical insights into adaptive optimization, scale-freeness, and robust generalization in deep learning.

1. AdamW as an EMA and the Definition of Timescale

AdamW performs parameter updates as

wt=(1ηλ)wt1ηm^tv^t+ϵw_t = (1 - \eta\lambda)w_{t-1} - \eta\, \frac{\hat m_t}{\sqrt{\hat v_t} + \epsilon}

where wtw_t is the parameter vector at step tt, η\eta the learning rate, λ\lambda the decoupled weight decay, and m^t,v^t\hat m_t,\hat v_t are bias-corrected first and second moment EMAs of the stochastic gradients. This update is structurally equivalent to an ordinary EMA:

EMAt=(11/τ)EMAt1+(1/τ)qt\mathrm{EMA}_t = (1 - 1/\tau)\, \mathrm{EMA}_{t-1} + (1/\tau)\, q_t

with EMA timescale τiter=1/(ηλ)\tau_\mathrm{iter} = 1/(\eta\lambda). Interpreting the parameter update as an EMA over negative gradient steps yields a direct correspondence: λ\lambda tunes the “memory” of the EMA process—large λ\lambda means short memory and aggressive decay, small wtw_t0 means long memory and gentle regularization (Wang et al., 2024).

Converting to epochs, for a dataset with wtw_t1 minibatches per epoch,

wtw_t2

which allows timescale analysis in units natural to model and dataset scaling.

2. Timescale–Weight Decay Mapping and Scaling Laws

There exists a one-to-one mapping between the EMA timescale and the AdamW weight decay hyperparameter for a fixed learning rate:

wtw_t3

wtw_t4

Setting an optimal wtw_t5 (in the “sweet spot” of 1–5 epochs, empirically stable across problem scales) gives explicit scaling rules:

  • Increasing dataset size wtw_t6 while keeping wtw_t7 fixed requires wtw_t8
  • Under μP learning rate scaling (wtw_t9), keeping tt0 fixed implies tt1, i.e., tt2 should increase linearly with model width (Wang et al., 2024)

This formalism underlies robust optimizer transfer across dataset and model sizes.

3. Proximal Perspective and Timescale Robustness

AdamW can be derived as a first-order approximation to a diagonal proximal step for the composite objective tt3. The AdamProx rule,

tt4

with tt5, Taylor expands for small tt6 to the AdamW update. The proximal step effectively decouples the regularization “pull” toward zero from the noisy direction of the adaptive gradient, conferring robustness against heterogeneity in gradient magnitudes—i.e., differing timescales for parameter drift across layers. AdamW maintains a consistent contraction rate for all coordinates, even with vanishing or exploding gradients (Zhuang et al., 2022).

4. Scale-Freeness and Invariance Across Timescales

AdamW is scale-free: its iterates are invariant when the per-coordinate gradients are rescaled by any fixed positive vector. This property is absent in, for example, Adam-tt7, where the inhomogeneous regularizer term entangles gradient and parameter scales. Scale-freeness is operationally a type of automatic diagonal preconditioning: by neutralizing disparities in local gradient scales, the effective convergence timescales of all parameters are equalized, even in highly ill-conditioned or deep architectures (Zhuang et al., 2022). This is critical for consistent optimization when batch normalization is absent or depth-induced scaling pathologies are present.

5. Empirical Evidence and Prescriptive Rules

Empirical studies with ResNet-18 and ViT on CIFAR-10 and ImageNet, and NanoGPT on OpenWebText, demonstrate:

  • Optimal tt8 (best test accuracy) lies in the range tt9 epochs, invariant across large variations in dataset size
  • Optimal η\eta0 drops sharply as dataset size increases when η\eta1 is held constant
  • μP model scaling (varying network width) with η\eta2 keeps learning curves and optimal learning rates synchronized across widths (Wang et al., 2024)

Further, large-scale LLM pretraining (Llama 1 & 2, Stable-LM) operate with initial/final η\eta3, confirming the practical invariance across scales.

Table: AdamW Weight Decay–Timescale Relations

Parameter Formula Scaling Rule
η\eta4 η\eta5 Hold constant across architectures
η\eta6 η\eta7 Hold constant across datasets
η\eta8 η\eta9 λ\lambda0, λ\lambda1 model fan-in

6. Theoretical Convergence and Practical Timescales

The AdamW theoretical convergence rate,

λ\lambda2

holds under standard assumptions (L-smoothness, unbiased gradients, bounded variance, and λ\lambda3-confinement of iterates). Under a Gaussian-gradient model, λ\lambda4, making the λ\lambda5 convergence directly analogous to the optimal λ\lambda6 SGD bound in λ\lambda7 norm (Li et al., 17 May 2025).

Empirical validation shows this scaling holds in practice—gradient norms during training satisfy λ\lambda8 for ResNet50 and GPT2, and training loss decays smoothly at this theoretical rate (Li et al., 17 May 2025).

7. Practical Guidance and Implications

AdamW timescale analysis prescribes that practitioners:

  • Fix an EMA timescale λ\lambda9 in the interval m^t,v^t\hat m_t,\hat v_t0
  • For a given learning rate and batch configuration, set m^t,v^t\hat m_t,\hat v_t1
  • Halve m^t,v^t\hat m_t,\hat v_t2 when doubling the dataset size at fixed m^t,v^t\hat m_t,\hat v_t3; increase m^t,v^t\hat m_t,\hat v_t4 linearly with model width under μP scaling
  • Monitor test accuracy as a function of m^t,v^t\hat m_t,\hat v_t5 (not m^t,v^t\hat m_t,\hat v_t6), exploiting empirical invariance for transferability between training regimes

A plausible implication is that AdamW’s timescale framing unifies adaptive regularization choice across scales, mitigating the need for hand-tuning and supporting robust, predictable optimization behavior in modern deep networks (Wang et al., 2024, Zhuang et al., 2022).

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to AdamW Timescale.