Optimizer Evolution in Large Model Training: How Muon Works
This article traces the evolution of training optimizers from stochastic gradient descent and momentum to adaptive per-parameter methods and the newer matrix-based Muon family. It explains why optimizers become a first-order engineering concern at scale, how each generation addresses the limitations of the previous one, and what Muon's orthogonalized matrix update actually changes. Readers will also find a practical checklist for hybrid deployment, guidance on choosing between method families, and three common misconceptions to avoid.
1. Why the Optimizer Is a First-Order Engineering Problem in Large Model Training
In pretraining practice, model architecture, data mixtures, and parallelism strategies get discussed endlessly, while the optimizer is often treated as a one-line configuration item that can be swapped at will. That view gets corrected quickly once parameter counts cross into the hundreds of billions and training tokens reach the trillions: under the same data and compute budget, differences between optimizers and learning rate schedules can directly determine whether the loss curve develops spikes, whether training diverges partway through, and what loss plateau the run finally converges to.
Think of training as searching for the lowest point in a mountain range while blindfolded and surrounded by thick fog. Only two kinds of information are available: the “current altitude” reported by the loss function, and the gradient computed by backpropagation, which works like probing the slope underfoot with your feet and tells you which side goes downhill. The optimizer is the navigation strategy in your head: it decides the direction of each step, the step size, and whether to use momentum. It generally has to answer three questions:
- How the step size should adapt as training progresses, which is learning rate control;
- How to avoid getting stuck in small pits halfway up the slope, which is escaping local minima and saddle points;
- How to keep the update direction effective when parameter dimensions differ wildly in scale, which is gradient preprocessing and normalization.
Too large a step size overshoots the valley floor and oscillates back and forth on the opposite slope, showing up as loss spikes or even NaN. Too small a step size stretches the training cycle indefinitely and sends compute costs out of control. The ideal strategy is “fast on flat ground, slow on steep slopes and near the valley floor,” and that is exactly the core tension adaptive optimizers are meant to resolve.
2. From SGD to Momentum: Establishing the Idea of Inertia
The most basic stochastic gradient descent traces its mathematical roots to early work on optimization methods in the mid-nineteenth century. Formally, it simulates a “massless particle” sliding on a surface: it can reach maximum speed instantly and stop completely instantly, which clearly violates physical intuition and causes parameters in long, narrow canyon-like terrain to repeatedly slam into the steep walls on both sides, making the effective descent speed extremely low.
The idea that broke this setup was a key result in optimization theory in the 1960s: artificially giving the particle “mass” and “inertia.” This is the idea behind the Heavy Ball Method, whose update rule can be abstracted as:
# Core of momentum: accumulate a "velocity" from historical gradients instead of only looking at the current slopev = beta * v + grad # inertia term: preserve the previous direction of motionparam -= lr * v # step along the velocity direction
Its rigor lies in the fact that under conditions such as convex quadratics, the convergence rate improvement over plain gradient descent can be proven. Its engineering value lies in the fact that the back-and-forth oscillation along the transverse direction decays as positive and negative gradients cancel each other, while the effective descent component along the longitudinal direction keeps accumulating, so the trajectory is naturally “ironed flat” into fast progress along the canyon. This paradigm of “gradient accumulation plus scale scaling” is the shared foundation of nearly every modern optimizer that followed.
3. Adaptive Learning Rates: From a Single Step Size to Per-Dimension Step Sizes
Momentum solved the temporal correlation of direction but not the inconsistent scale of dimensions in parameter space. The gradient magnitudes of embedding layers, attention projections, feed-forward layers, and normalization parameters can differ by several orders of magnitude, so a single learning rate inevitably makes some dimensions oscillate while others nearly stall.
Adaptive methods answer this by maintaining a second-order statistic of the gradient for each dimension (a moving average of squared gradients) and scaling the step size per dimension accordingly:
# Per-dimension adaptation: the larger the second moment, the smaller the effective step sizem = beta1 * m + (1 - beta1) * gradv = beta2 * v + (1 - beta2) * grad * gradm_hat = m / (1 - beta1 ** t) # bias correctionv_hat = v / (1 - beta2 ** t)param -= lr * m_hat / (v_hat.sqrt() + eps)
Three engineering details matter here: the value and placement of eps affect stability for dimensions with small gradients; beta2 determines the memory length of the second-order statistics, where too long fails to track distribution drift and too short amplifies noise; and bias correction is especially important early in training, since otherwise the effective step size over the first few hundred steps is severely underestimated. These methods are notably robust in sparse or heterogeneous gradient settings, which is why they have long been the default choice for large model training.
4. The Technical Motivation Behind the New Generation of Matrix Optimizers
In the training details disclosed in the preview release of a recent open-source model series, the most discussed item was a class of matrix optimizers (commonly named in the industry after a Greek letter, referred to collectively here as Muon-style methods). Understanding the breakthrough requires first seeing the structural limitation of adaptive per-dimension methods: they treat the gradient as a vector of length n whose elements are processed independently, completely ignoring the coupling between rows and columns inside a weight matrix.
Weights in a neural network are fundamentally matrices, and their gradient matrices often show clear low-rank and strongly correlated structure: many singular values concentrate in a few directions, so updates get dominated by a handful of principal directions, producing an insufficient number of effective update dimensions. The central claim of Muon-style methods is to stop scaling element by element and instead orthogonalize (spectrally normalize) the whole gradient matrix, flattening all singular values of the update matrix to the same magnitude so that parameter updates are more balanced across singular directions.
The abstract flow looks like this:
# Schematic of a matrix-based update (not a specific implementation)g = grad_matrix # shape (m, n)g = g / (g.norm() + eps) # normalize globally first to control the overall step sizeq = orthogonalize(g) # iterative approximation of orthogonalization, equivalent to flattening singular valuesparam -= lr * q # use the matrix update for 2D parameters
Here orthogonalize is usually computed approximately with a few iterations (for example, a polynomial iteration in the Newton-Schulz form), because computing the orthogonal polar factor exactly is too expensive for large models. Several implementation details cannot be ignored: the number of iterations and the coefficients need to be tuned as a set, since too few leaves the orthogonalization incomplete while too many adds overhead that eats the gains; for numerical precision, double-precision accumulation is recommended for small matrix operations to avoid divergence of the iteration under half precision; and orthogonalization only applies to 2D weights, so embeddings, biases, normalization parameters, and gating scalars still need to fall back to the adaptive per-dimension method.
5. Hybrid Usage and a Deployment Checklist
A matrix optimizer is not a “global replacement.” The mainstream approach is grouped hybrid use: 2D hidden-layer weights go through the matrix path, everything else goes through the adaptive path, and each group maintains its own state and hyperparameters. When deploying, pay attention to the following:
- Declare the grouping rules explicitly, so that gaps in parameter name matching do not cause some layers to be handled incorrectly;
- Reset the learning rate and weight decay per group; reusing the old configuration directly will almost certainly destabilize training;
- Optimizer state memory overhead varies with the grouping scheme, so leave headroom in the parallelism partitioning plan;
- Use it together with gradient clipping, clipping first and then orthogonalizing, which significantly reduces the probability of early spikes;
- Beyond loss, monitoring should also include gradient norms, the singular value distribution of update matrices, and measured per-group learning rates;
- Build training observability on the container platform, logging service, and monitoring and alerting system, so that when a spike occurs you can quickly trace it back to a specific step and parameter group.
6. Selection Guidance and Common Misconceptions
Selection should not chase whatever is newest; it should match the characteristics of the task. For scenarios with sparse gradients and high parameter heterogeneity, adaptive per-dimension methods are more stable. For large-scale pretraining with dense gradients and regular matrix structure, matrix methods are usually more attractive in convergence efficiency at the same compute budget, but they require additional tuning effort and investment in numerical stability.
Three common misconceptions are worth watching for. First, treating orthogonalization as “a smaller learning rate,” when what it actually changes is how the update is distributed across directions. Second, ignoring the coupling between the optimizer and the parallelism strategy, since a change in partitioning alters the computation and communication pattern of orthogonalization. Third, running only end-to-end loss comparisons without grouped ablation, which leaves the source of the gains unattributable. The recommendation is to complete hyperparameter search and stability validation with small-scale proxy experiments before any full-scale run, then scale up gradually, achieving a controllable balance between compute budget and convergence quality.
