Manuscript Offprint

arXiv:2610.24839

A Statistical Viewpoint on Adam, Shampoo and Muon

Tetiana Parshakova, Robert M. Gower, Paulo Orenstein

Abstract

We provide new statistical insights into designing stochastic optimization methods. By modeling the gradient via a normal distribution, we argue that the stochastic gradient should be whitened using its covariance. We give an online method for estimating the mean and variance of the gradients based on regularized likelihood or, equivalently, through a maximum a posteriori estimate. We then show how to use structured approximations to the covariance within this same framework, which includes diagonal and Kronecker-factored approximations. The diagonal approximation results in a method that is very closely related to Adam and performs as well in practice. The Kronecker approximation results in the new MN method, which is a variant of Shampoo and KL-Shampoo. We also recover Muon by applying this same statistical framework to the gradient direction rather than the full gradient. By combining this with a whitening step, we arrive at MN-Muon, a novel preconditioned version of Muon. Our experiments on GPT-2-type models at Chinchilla scale indicate that MND, the diagonal implementation of MN, outperforms both the Distributed Shampoo and the KL-Shampoo implementations in terms of stability, final validation loss and time taken. MND-Muon, the diagonal implementation of MN-Muon, improves on Muon in 21 of 24 paired GPT-small runs and achieves a lower best validation loss on GPT-medium, where it remains stable over the six tested learning rates. However, we found that NorMuon was comparable to MND-Muon and achieved a slightly lower validation loss on GPT-medium and at GPT-small batch 512 on FineWeb.

1 Introduction

Here we present a new viewpoint for modeling stochastic pretraining methods based on whitening. Stochastic gradients are noisy estimates of the full-batch gradient, with some components having high variance and others low variance. We need to take this variance into account; otherwise, we might accidentally take a large step in a high-variance direction, leading the method astray.

To explain this whitening, let ℓ(w)\ell(\boldsymbol{w}) be a loss we wish to minimize with parameters w∈Rd\boldsymbol{w} \in \mathbb{R}^d, and let gt∈Rd\boldsymbol{g}_t \in \mathbb{R}^d be a stochastic gradient evaluated at a given wt∈Rd\boldsymbol{w}_t \in \mathbb{R}^d. Thus E[gt∣wt]=∇ℓ(wt)\mathbb{E}\left[\boldsymbol{g}_t \mid \boldsymbol{w}_t\right] = \nabla \ell(\boldsymbol{w}_t). With a sampled stochastic gradient, we may update our parameters using

wt+1=wt−ηgt,w_{t+1}=w_{t}-\eta g_{t},

where η>0\eta > 0 is a step size. Suppose now that we fit a normal model to our stochastic gradients, and assume gt∼N(mt,Σt)g_t \sim \mathcal{N}(m_t, \Sigma_t). Instead of using gtg_t as our update direction, we could use an estimate m^t\hat{m}_t of the mean and update according to

wt+1=wt−ηm^t.w_{t+1}=w_{t}-\eta\hat{m}_{t}.

This approach corresponds to using the momentum algorithm (Schaipp et al., 2025). But this momentum update ignores the variance in the gradients. Some of the coordinates of the gradient may have a very high variance, in which case we should be cautious and take a smaller step in these coordinates. For coordinates that have low variance, we can safely take larger steps. We can implement this idea by using the covariance to whiten our estimate of the mean. That is, the whitened gradient Σt−1/2gt∼N(Σt−1/2mt,I)\mathbf{\Sigma}_t^{-1/2} \mathbf{g}_t \sim \mathcal{N}(\mathbf{\Sigma}_t^{-1/2} \mathbf{m}_t, \mathbf{I}) has independent coordinates, each with variance one. Taking a step using this whitened stochastic gradient corresponds to

wt+1=wt−ηΣt−1/2gt.(1)w_{t+1}=w_{t}-\eta\Sigma_{t}^{-1/2}g_{t}. \tag{1}

∗^{*}Joint first authors.

SGD Whitened SGD

Figure

Figure 1: SGD and Whitened SGD on ℓ(w)=12∥w∥2\ell(\boldsymbol{w}) = \frac{1}{2} \| \boldsymbol{w} \|^2 with stochastic gradients gt=wt+ξt\boldsymbol{g}_t = \boldsymbol{w}_t + \boldsymbol{\xi}_t, where ξt∼N(0,Σ)\boldsymbol{\xi}_t \sim \mathcal{N}(0, \boldsymbol{\Sigma}) and Σ=diag(0.1,100)\boldsymbol{\Sigma} = \text{diag}(0.1, 100). Right: final loss after 300 iterations versus base learning rate over five seeds. Left and middle: 300-step trajectories of SGD and Whitened SGD each with best base learning rate chosen from the right plot.

To illustrate, see Figure 1, where we compare SGD to Whitened SGD (1) on a simple quadratic loss with Gaussian noise. The left and middle panels of Figure 1 show the trajectories of the two methods, each with the best tuned base learning rate (over five seeds). SGD takes large, noisy steps in the high-variance direction, while Whitened SGD rescales those steps so it can make steadier progress toward the minimum.

In practice we will use an estimate of the mean whitened gradient and update according to

wt+1=wt−ηΣ^t−1/2m^t,(2)\begin{array}{r}{w_{t+1}=w_{t}-\eta\hat{\Sigma}_{t}^{-1/2}\hat{m}_{t},}\end{array} \tag{2}

where Σ^t\hat{\Sigma}_{t} and m^t\hat{m}_{t} are estimates of the covariance and mean. We refer to methods that fit the format (2) as the whitened momentum methods.

Our starting point is in Section 2 where we show that by modeling the gradient through a Bayesian recursion or, equivalently, by solving a regularized likelihood optimization problem, we arrive at an online method for estimating both the variance Σ^t\hat{\Sigma}_{t} and mean m^t\hat{m}_{t} of the gradients. Our method can be seen as a full covariance matrix variant of Adam (Kingma and Ba, 2014).

In practice we cannot store the full covariance matrix or approximate its inverse square root. To arrive at a practical method, in Section 3 we show how to use structured approximations to the full covariance matrix, such as diagonal matrices or Kronecker-factored matrices with full or diagonal factors.

We then show that using a diagonal approximation in Section 4 we recover the update of the first and second moment estimates of Adam as a special case (Orvieto and Gower, 2025). However, the Adam update does not exactly fit the format of a whitened momentum method, because Adam uses the uncentered second moment to whiten momentum, instead of the centered second moment (covariance) as is used in the whitened momentum method (2). Combining this diagonal covariance with the whitened momentum step (2) yields Centered Adam, a variant of both Adam and AdaBelief (Zhuang et al., 2020). We do several experiments showing that Centered Adam performs as well as the original Adam method. Thus, explaining the practical effectiveness of Adam-like methods may not require an exact account of Adam itself: the closely related method Centered Adam achieves comparable performance and admits a simple interpretation as online gradient whitening using a diagonal covariance approximation.

In Section 5, we move beyond diagonal covariance approximations to the richer class of Kronecker-factored matrices. Within this class, we show that square-root (as opposed to quarter-root) variants of Shampoo fit the whitened momentum format (2), giving them an interpretation as gradient whitening with a Kronecker-factored covariance. Applying our covariance estimation approach to these Kronecker factors then yields new variants of KL-Shampoo (Lin et al., 2026), which we call the MN (Matrix Normal) method. This name reflects the underlying probabilistic model: a Gaussian distribution over matrices with a Kronecker-factored covariance is known as a Matrix Normal distribution.

The MN method has storage and computational costs of the same order as Shampoo, but requires substantially more optimizer state storage than Muon. For layers with a 1:4 aspect ratio, Shampoo and MN require 5.25 times as much optimizer state storage as Muon, counting momentum and covariance factors at the same precision. To arrive at an algorithm with storage comparable to that of Muon, we propose MND, which is a variant of our MN where the factors are diagonal matrices. Our experiments 1^{1} in Section 6 compare the MND methods to the most well-established variants of Shampoo, namely Distributed Shampoo (Shi et al., 2023) and KL-Shampoo on GPT-small and GPT-medium at Chinchilla scale. These experiments show that MND was the most robust method to the choice of learning rate and achieved a significantly lower final validation loss.

In Section 7 we go on to show that Muon also admits a statistical interpretation by modeling the behavior of the gradient direction, rather than the gradient itself. Using this interpretation we derive a new preconditioned version of Muon that we call MND-Muon. Benchmarking MND-Muon, we find it consistently improves upon Muon, but falls a little short of NorMuon in Section 8.

Background. Our work is largely motivated by the empirical success of Muon (Jordan et al., 2024), Adam (Kingma and Ba, 2014), Shampoo (Gupta et al., 2018) and its variants such as KL-Shampoo and Distributed Shampoo (Lin et al., 2026; Kasimbeg et al., 2025; Shi et al., 2023). More recently, Muon (Jordan et al., 2024) has emerged as one of the most competitive methods, having already been used to train several frontier models (Liu et al., 2025; GLM-4.5 Team, 2025; Kimi Team, 2025; DeepSeek-AI, 2026). Our technique for estimating the mean and covariance of the gradients can be seen as an extension of Orvieto and Gower (2025), but where we unify methods through the lens of gradient whitening, consider other structured approximations to the covariance matrix, and introduce a complete Bayesian interpretation. Another closely related line of work is by Lin et al. (2026), where the authors use a KL divergence projection of the uncentered gradient second moment onto the space of Kronecker-factored matrices to derive a new variant of Shampoo. Our methods can also be seen as KL projections, but where we jointly model the mean and variance, and show that the target mean and variance are the posterior mode of a Bayesian model. See Section A for a more detailed discussion of related work.

References (100)

  • The Polar Express: Optimal matrix sign methods and their application to the Muon algorithm (opens arXiv in a new tab)
  • Old optimizer, new norm: An anthology, 2024
  • Streaming variational Bayes
  • DeepSeek-V4: Towards Highly Efficient Million-Token Context Intelligence
  • Aurora: A leverage-aware spectral optimizer, 2026
  • Fast approximate natural gradient descent in a Kronecker-factored eigenbasis
  • GLM-4.5 Team. GLM-4.5: Agentic, reasoning, and coding (ARC) foundation models. arXiv preprint arXiv:2508.06471, 2025. (opens arXiv in a new tab)
  • Shampoo: Preconditioned stochastic tensor optimization
  • N. J. Higham. Stable iterations for the matrix square root. Numerical Algorithms, 15(2):227–242, 1997. doi: 10.1023/A:1019150005407. (opens the publisher in a new tab)
  • N. J. Higham. Functions of Matrices: Theory and Computation. SIAM, Philadelphia, PA, 2008. ISBN 978-0-89871-646-7. doi: 10.1137/1.9780898717778. (opens the publisher in a new tab)
  • Training compute-optimal large language models
  • Muon: An optimizer for hidden layers in neural networks
  • Accelerating neural network training: An analysis of the AlgoPerf competition
  • modded-nanogpt: Speedrunning the NanoGPT baseline
  • The Bayesian learning rule
  • Kimi K2: Open Agentic Intelligence
  • Adam: A Method for Stochastic Optimization
  • An optimization-centric view on Bayes' rule: Reviewing and generalizing variational inference
  • On a general concept of forgetting (opens the publisher in a new tab)
  • Limitations of the empirical Fisher approximation for natural gradient descent
  • Noise is not the main factor behind the gap between SGD and Adam on transformers, but sign descent might be
  • NorMuon: Making Muon more efficient and scalable, 2025
  • Understanding and improving Shampoo and SOAP via Kullback–Leibler minimization
  • J. Liu, J. Su, X. Yao, Z. Jiang, G. Lai, Y. Du, Y. Qin, W. Xu, E. Lu, J. Yan, et al. Muon is scalable for LLM training. arXiv preprint arXiv:2502.16982, 2025. (opens arXiv in a new tab)
  • Muon $^{2}$: Boosting Muon via adaptive second-moment preconditioning, 2026
  • Structured and efficient variational deep learning with matrix Gaussian posteriors
  • Optimizing neural networks with Kronecker-factored approximate curvature
  • Variational continual learning
  • M. Opper. A Bayesian approach to on-line learning. In D. Saad, editor, On-line learning in neural networks, pages 363–378. Cambridge University Press, 1999. doi: 10.1017/CBO9780511569920.017. (opens the publisher in a new tab)
  • The FineWeb datasets: Decanting the web for the finest text data at scale
  • Tensor normal training for deep learning models
  • Online structured Laplace approximations for overcoming catastrophic forgetting
  • Tracking the median of gradients with a stochastic proximal point method
  • AdaMuon: Adaptive Muon optimizer, 2025
  • SlimPajama: A 627B token cleaned and deduplicated version of RedPajama
  • Bayesian forecasting and dynamic models (opens the publisher in a new tab)
  • A. Wiesel. Geodesic convexity and covariance estimation. IEEE Transactions on Signal Processing, 60(12):6182–6189, 2012. doi: 10.1109/TSP.2012.2218241. (opens the publisher in a new tab)
  • A. Zellner. Optimal information processing and Bayes's theorem. The American Statistician, 42(4):278–280, 1988. doi: 10.1080/00031305.1988.10475585. (opens the publisher in a new tab)
  • Noisy natural gradient as variational inference
  • Why are adaptive methods good for attention models? In Advances in Neural Information Processing Systems, volume 33, 2020
  • Mousse: Rectifying the geometry of Muon with curvature-aware preconditioning, 2026
  • AdaBelief optimizer: Adapting stepsizes by the belief in observed gradients
  • Their relationship depends on what the factors represent and how they enter the update
  • NorMuon tracks an EMA of the mean squared entry in each row of the orthogonalized update and uses it to scale that row
  • It divides accumulated momentum by the square root of a moving average of squared gradients, aiming to improve the conditioning of the subsequent Newton–Schulz iteration
  • For tall matrices, it alternates damped row normalization with polar computations, seeking updates with approximately orthonormal columns and equal row norms
  • Whenever this condition fails, we use the joint expression below as an unnormalized prior kernel
  • Hence we need to store only these two statistics, not the full posterior (Proposition B.2)
  • The scale matrix is positive definite and $\nu > d - 1$ by the assumptions
  • Assume $0 < \beta < 1$ and $\hat{\Sigma}_{t-1} \succ 0$
  • Since $\beta\hat{\Sigma}_{t-1} \succ 0$ and the remaining covariance term is positive semidefinite, $\hat{\Sigma}_t' \succ 0$
  • The KL divergence is nonnegative and vanishes exactly at $(m, \Sigma) = (\hat{m}_t, \hat{\Sigma}_t')$
  • For other values of $\beta$, the same algebra proves the statements for the unnormalized Bayesian objective
  • Since the restriction concerns only the covariance, this mean is optimal for every $\Sigma \in \mathcal{S}$
  • The same quadratic mean term appears in the structured joint KL projection, proving all the equivalences
  • By Proposition C.1, it suffices to minimize
  • The identity
  • This proves (13) when $\varepsilon = 0$ and the buffers are used without bias correction
  • Both initialize $\hat{m}_0=\hat{v}_0=0$ and use $\beta=0.95$ and $\varepsilon=10^{-8}$
  • Centered Adam uses the AdamW denominator for updates 1 to 50, then switches to the centered denominator at update 51
  • GPT-small uses 4,743 updates at batch 512 (2.49B tokens), with seeds 1, 2, and 42; GPT-medium uses 9,016 updates at batch 768 (7.09B tokens), with seed 42
  • Figure 3 displays the range 0.0003–0.01: solid lines are three-seed means, shading spans the seed minimum and maximum, and dashed lines use only one seed
  • We prove the closed-form block updates, existence and uniqueness after trace normalization, and convergence of alternating minimization
  • Assume $0 < \beta < 1$ and that $\hat{\mathbf{R}}_{t-1}$ and $\hat{\mathbf{C}}_{t-1}$ are positive definite
  • Left: GPT-small, with learning rate 0.003 for both methods; lines show means over three seeds; shading: seed ranges
  • $(\hat{\mathbf{R}}_t^{(k)}, \hat{\mathbf{C}}_t^{(k)}) \xrightarrow{k \to \infty} (\hat{\mathbf{R}}_t^\star, \hat{\mathbf{C}}_t^\star)$
  • Symmetrically, for fixed $\mathbf{R}$, the function $\mathbf{C} \mapsto f(\mathbf{C} \otimes \mathbf{R})$ is uniquely minimized at $\mathbf{C} = \mathcal{C}(\mathbf{R})$, which gives (20)
  • $\mathcal{R}(a\mathbf{C}) = a^{-1}\mathcal{R}(\mathbf{C})$ and $\mathcal{C}(a^{-1}\mathbf{R}) = a\mathcal{C}(\mathbf{R})$ for $a > 0$
  • Fix $c \in \mathbb{R}$
  • On that set, $f(\mathbf{C} \otimes \mathbf{R})$ and $\text{tr}(\mathbf{R}) - \text{tr}(\mathbf{C})$ are continuous, so $\mathcal{K}_c$ is closed in it and hence compact
  • Choosing $s = \sqrt{\mathrm{tr}(\mathbf{C}) / \mathrm{tr}(\mathbf{R})}$ makes the traces equal
  • For positive definite matrices A and B of equal size and $s \in \mathbb{R}$, let
  • Let $\sum_i \lambda_i \boldsymbol{u}_i \boldsymbol{u}_i^\top$ be an eigendecomposition of $\mathbf{A}^{-1/2} \mathbf{B} \mathbf{A}^{-1/2}$, and take $\mathbf{A}, \mathbf{B} \in \mathbb{R}^{mn \times mn}$
  • Then $\mathbf{A}^{\pm1/2} = \mathbf{C}_1^{\pm1/2} \otimes \mathbf{R}_1^{\pm1/2}$, and by the mixed-product property $\mathbf{A}^{-1/2} \mathbf{B} \mathbf{A}^{-1/2} = (\mathbf{C}_1^{-1/2} \mathbf{C}_2 \mathbf{C}_1^{-1/2}) \otimes (\mathbf{R}_1^{-1/2} \mathbf{R}_2 \mathbf{R}_1^{-1/2})$
  • By (57) and Step 4, $\varphi$ is convex
  • This limit is a positive definite pair with $\mathrm{tr}(\bar{\mathbf{R}}) = \mathrm{tr}(\bar{\mathbf{C}})$
  • Also $f(\bar{\mathbf{C}} \otimes \bar{\mathbf{R}}) = \bar{h}$
  • Since $(\bar{\mathbf{R}}, \bar{\mathbf{C}})$ is normalized, Step 4 gives $(\bar{\mathbf{R}}, \bar{\mathbf{C}}) = (\hat{\mathbf{R}}_t^\star, \hat{\mathbf{C}}_t^\star)$
  • It shows that adjoining the unique mean $m = \hat{m}_t$ from (7) gives a global solution of (3) restricted to this $\mathcal{S}$
  • Write $\mathbf{R} = \mathrm{diag}(\mathbf{r})$ and $\mathbf{C} = \mathrm{diag}(\mathbf{c})$, with positive entries, and assume the previous factors are likewise diagonal and positive
  • The column update and reciprocal trace balancing then give the remaining factor steps
  • Indeed, diagonal matrices remain diagonal along the geodesics used there, and the block minimizers above are positive and unique
  • Indeed, the relationship between the moments of the centered residuals $\mathbf{X}_t = \mathbf{G}_t - \mathbf{M}_t$ and $\mathbf{R}_t$ and $\mathbf{C}_t$ is given by the following lemma
  • We can use the identities (58) to build estimates of our factor matrices $\hat{\mathbf{R}}_t$ and $\hat{\mathbf{C}}_t$ as follows
  • To estimate the expectations in (58) we can use an exponential moving average given by
  • This is often the choice made by adaptive optimizers such as Shampoo (Gupta et al., 2018)
  • We equip it with its uniform measure, that is, the unique probability measure invariant under $\mathbf{D} \mapsto \text{UDV}$ for orthogonal $\mathbf{U} \in \mathbb{R}^{m \times m}$ and $\mathbf{V} \in \mathbb{R}^{n \times n}$
  • Let $\mathbf{F} = \mathbf{USV}^\top$ be a compact singular value decomposition, with $\mathbf{U} \in \mathbb{R}^{m \times p}$ and $\mathbf{V} \in \mathbb{R}^{n \times p}$ having orthonormal columns and $\mathbf{S} = \text{diag}(s_1, \ldots, s_p)$ with $s_1 \geq \cdots \geq s_p > 0$
  • Since each column of $\mathbf{Z}$ has norm at most one, this forces $\mathbf{Z} = \mathbf{I}_p$
  • From $\mathbf{U}^\top \mathbf{D}\mathbf{V} = \mathbf{I}_n$ we get $\mathbf{U}^\top \mathbf{D} = \mathbf{V}^\top$
  • If $m < n$, apply the same argument to $\mathbf{F}^\top$ and $\mathbf{D}^\top \in \mathrm{St}(n, m)$, using $\langle \mathbf{F}, \mathbf{D} \rangle = \langle \mathbf{F}^\top, \mathbf{D}^\top \rangle$
  • Since the polar factor is unique, this gives $\text{Polar}(a\mathbf{F}) = \text{Polar}(\mathbf{F})$
  • Multiplying by the kernel of (36) gives
  • This is exponential forgetting: it downweights all accumulated information by the same factor $\beta$
  • This definition does not require the kernel to be normalizable
  • With $\mathbf{\Sigma} = \mathbf{C} \otimes \mathbf{R}$, $\hat{\mathbf{\Sigma}}_{t-1} = \hat{\mathbf{C}}_{t-1} \otimes \hat{\mathbf{R}}_{t-1}$ and $g_t = \mathrm{vec}(\mathbf{G}_t)$, define
  • Since $K_t$ is the product of the likelihood and the two priors, these identities give
  • Using the mean parameterization $\mathbf{M} = \mathbf{R}^{1/2} \mathbf{D} \mathbf{C}^{1/2}$ in (43), we have $\mathbf{R}^{-1/2} (\mathbf{G}_t - \mathbf{M}) \mathbf{C}^{-1/2} = \mathbf{Z} - \mathbf{D}$
  • Thus the row block is equivalent to
  • The matrix $\mathbf{Q}$ is positive definite: its first term is positive definite because $\beta > 0$, $\hat{\mathbf{R}}_{t-1} \succ 0$, and $\text{tr}(\mathbf{C}^{-1}\hat{\mathbf{C}}_{t-1}) > 0$; its second term is positive semidefinite

Couldn't load all references. Reload the page to try again.