A Distributed Data-Parallel PyTorch Implementation of the Distributed Shampoo Optimizer for Training Neural Networks At-Scale
Not on the map. Why?
Abstract (arXiv)
Shampoo is an online and stochastic optimization algorithm belonging to the AdaGrad family of methods for training neural networks. It constructs a block-diagonal preconditioner where each block consists of a coarse Kronecker product approximation to full-matrix AdaGrad for each parameter of the neural network. In this work, we provide a complete description of the algorithm as well as the performance optimizations that our implementation leverages to train deep networks at-scale in PyTorch. Our implementation enables fast multi-GPU distributed data-parallel training by distributing the memory and computation associated with blocks of each parameter via PyTorch's DTensor data structure and performing an AllGather primitive on the computed search directions at each iteration. This major performance enhancement enables us to achieve at most a 10% performance reduction in per-step wall-clock time compared against standard diagonal-scaling-based adaptive gradient methods. We validate our implementation by performing an ablation study on training ImageNet ResNet50, demonstrating Shampoo's superiority over standard training recipes with minimal hyperparameter tuning.
Key facts. Cited by 77 papers in the map (data through 14 Oct 2026). Builds on 40 of its 85 references that are in the map. First posted on arXiv 12 Sep 2023.
Builds on
40 of 85 references.
References · 40
- 2015Deep Residual Learning for Image Recognitioncited by 52,096
- 2014Adam: A Method for Stochastic Optimizationcited by 37,240
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 30,186
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,305
- 2022OPT: Open Pre-trained Transformer Language Modelscited by 3,512
- 2018Averaging Weights Leads to Wider Optima and Better Generalizationcited by 1,209
- 2016Optimization Methods for Large-Scale Machine Learningcited by 1,150
- 2018Adafactor: Adaptive Learning Rates with Sublinear Memory Costcited by 905
- 2019On the Convergence of Adam and Beyondcited by 841
- 2015Optimizing Neural Networks with Kronecker-factored Approximate Curvaturecited by 796
- 2019Large Batch Optimization for Deep Learning: Training BERT in 76 minutescited by 674
- 2023PyTorch FSDP: Experiences on Scaling Fully Sharded Data Parallelcited by 660
28 more
- 2014New insights and perspectives on the natural gradient methodcited by 443
- 2018Bag of Tricks for Image Classification with Convolutional Neural Networkscited by 431
- 2018Shampoo: Preconditioned Stochastic Tensor Optimizationcited by 426
- 2019Deep Learning Recommendation Model for Personalization and Recommendation Systemscited by 327
- 2021ZeRO-Infinity: Breaking the GPU Memory Wall for Extreme Scale Deep Learningcited by 256
- 2019Limitations of the Empirical Fisher Approximation for Natural Gradient Descentcited by 217
- 2015Compressing Neural Networks with the Hashing Trickcited by 150
- 2018Fast Approximate Natural Gradient Descent in a Kronecker-factored Eigenbasiscited by 146
- 2016A Kronecker-factored approximate Fisher matrix for convolution layerscited by 141
- 2021Software-Hardware Co-design for Fast and Scalable Training of Deep Learning Recommendation Modelscited by 78
- 2019Fast Convergence of Natural Gradient Descent for Overparameterized Neural Networkscited by 76
- 2015Newton Sketch: A Linear-time Optimization Algorithm with Linear-Quadratic Convergencecited by 72
- 2019Compositional Embeddings Using Complementary Partitions for Memory-Efficient Recommendation Systemscited by 68
- 2020Practical Quasi-Newton Methods for Training Deep Neural Networkscited by 68
- 2022Understanding AdamW through Proximal Methods and Scale-Freenesscited by 46
- 2018A Progressive Batching L-BFGS Method for Machine Learningcited by 45
- 2017Newton-Type Methods for Non-Convex Optimization Under Inexact Hessian Informationcited by 41
- 2017Second-Order Optimization for Non-Convex Machine Learning: An Empirical Studycited by 35
- 2022On the Factory Floor: ML Engineering for Industrial-Scale Ads Recommendation Modelscited by 34
- 2016A Multi-Batch L-BFGS Method for Machine Learningcited by 31
- 2017Adaptive Sampling Strategies for Stochastic Optimizationcited by 30
- 2017AdaBatch: Adaptive Batch Sizes for Training Deep Neural Networkscited by 29
- 2021Tensor Normal Training for Deep Learning Modelscited by 24
- 2016Sub-sampled Newton Methods with Non-uniform Samplingcited by 21
- 2020Momentum via Primal Averaging: Theoretical Insights and Learning Rate Schedules for Non-Convex Optimizationcited by 21
- 2017An Investigation of Newton-Sketch and Subsampled Newton Methodscited by 18
- 2019Quasi-Newton Methods for Machine Learning: Forget the Past, Just Samplecited by 12
- 2022Low-Rank Updates of Matrix Square Rootscited by 3
Built on by
Citing papers per year: 2023: 2; 2024: 11; 2025: 30; 2026: 34.
77 papers.
Sort:
By area:
- 2024Old Optimizer, New Norm: An Anthologycited by 193
- 2024SOAP: Improving and Stabilizing Shampoo using Adamcited by 192
- 2025The Polar Express: Optimal Matrix Sign Methods and Their Application to the Muon Algorithmcited by 110
- 2025NorMuon: Making Muon more efficient and scalablecited by 84
- 2024Modular Duality in Deep Learningcited by 77
- 2025Dion: Distributed Orthonormalized Updatescited by 68
- 2024MARS: Unleashing the Power of Variance Reduction for Training Large Modelscited by 64
- 2024A New Perspective on Shampoo's Preconditionercited by 59
- 2025ASGO: Adaptive Structured Gradient Optimizationcited by 57
- 2025Implicit Bias of Spectral Descent and Muon on Multiclass Separable Datacited by 41
- 2025MuonBP: Faster Muon via Block-Periodic Orthogonalizationcited by 35
- 2024LoRA Done RITE: Robust Invariant Transformation Equilibration for LoRA Optimizationcited by 32
38 more
- 2025Accelerating Neural Network Training: An Analysis of the AlgoPerf Competitioncited by 32
- 2025COSMOS: A Hybrid Adaptive Optimizer for Memory-Efficient Training of LLMscited by 30
- 2024Can We Remove the Square-Root in Adaptive Gradient Methods? A Second-Order Perspectivecited by 25
- 2025Purifying Shampoo: Investigating Shampoo's Heuristics by Decomposing its Preconditionercited by 23
- 2025Hyperparameter Transfer Enables Consistent Gains of Matrix-Preconditioned Optimizers Across Scalescited by 21
- 2024SWAN: SGD with Normalization and Whitening Enables Stateless LLM Trainingcited by 20
- 2025How Muon's Spectral Design Benefits Generalization: A Study on Imbalanced Datacited by 19
- 2025A Stable Whitening Optimizer for Efficient Neural Network Trainingcited by 18
- 2026Mousse: Rectifying the Geometry of Muon with Curvature-Aware Preconditioningcited by 17
- 2025Understanding and Improving Shampoo and SOAP via Kullback-Leibler Minimizationcited by 16
- 2025What Really Matters in Matrix-Whitening Optimizers?cited by 16
- 2026RMNP: Row-Momentum Normalized Preconditioning for Scalable Matrix-Based Optimizationcited by 15
- 2026Symmetry-Compatible Principle for Optimizer Design: Embeddings, LM Heads, SwiGLU MLPs, and MoE Routerscited by 11
- 2025When, Where and Why to Average Weights?cited by 8
- 2025Structure-Preserving Digital Twins via Conditional Neural Whitney Formscited by 8
- 2025FedMuon: Federated Learning with Bias-corrected LMO-based Optimizationcited by 8
- 2025SNOO: Step-K Nesterov Outer Optimizer - The Surprising Effectiveness of Nesterov Momentum Applied to Pseudo-Gradientscited by 8
- 2026Clarifying Shampoo: Adapting Spectral Descent to Stochasticity and the Parameter Trajectorycited by 8
- 2026Accelerating LLM Pre-Training through Flat-Direction Dynamics Enhancementcited by 8
- 2025How Memory in Optimization Algorithms Implicitly Modifies the Losscited by 6
- 2024DEPT: Decoupled Embeddings for Pre-training Language Modelscited by 5
- 2025Beyond the Mean: Fisher-Orthogonal Projection for Natural Gradient Descent in Large Batch Trainingcited by 5
- 2025Smoothing DiLoCo with Primal Averaging for Faster Training of LLMscited by 5
- 2024Stochastic Hessian Fittings with Lie Groupscited by 4
- 2025WeatherMesh-3: Fast and accurate operational global weather forecastingcited by 4
- 2025DeMuon: A Decentralized Muon for Matrix Optimization over Graphscited by 4
- 2026PRISM: Distribution-free Adaptive Computation of Matrix Functions for Accelerating Neural Network Trainingcited by 4
- 2026Canzona: A Unified, Asynchronous, and Load-Balanced Framework for Distributed Matrix-based Optimizerscited by 4
- 2026Spectral Scaling Laws of Muoncited by 4
- 2025Noise-Adaptive Layerwise Learning Rates: Accelerating Geometry-Aware Optimization for Deep Neural Network Trainingcited by 3
- 2026Phases of Muon: When Muon Eclipses SignSGDcited by 3
- 2026DynMuon: A Dynamic Spectral Shaping View of Muoncited by 3
- 2026SOAP-Bubbles: Structured Weight Uncertainty for Neural Networkscited by 3
- 2026DMuon: Efficient Distributed Muon Training with Near-Adam Overheadcited by 3
- 2024Memory-Efficient 4-bit Preconditioned Stochastic Optimizationcited by 2
- 2025Matryoshka Model Learning for Improved Elastic Student Modelscited by 2
- 2025Understanding SOAP from the Perspective of Gradient Whiteningcited by 2
- 2026DASH: Faster Shampoo via Batched Block Preconditioning and Efficient Inverse-Root Solverscited by 2
50 most cited of 77 All 77 (JSON)
- 2026A Refresh Interval Does Not Fully Specify a Refresh Schedule: Learning-Rate-Dependent Placement in Kronecker-Preconditioned Language Model Training13 Oct 2026
- 2026Minimax Optimality of Shampoo for Nonstationary Stochastic Optimization12 Oct 2026
- 2026Towards Easier-to-Tune Training Algorithms: New Results from AlgoPerf9 Oct 2026
- 2026How Bregman Divergences Shape Shampoo6 Oct 2026
- 2026Near-Optimal Convex Optimization with Lazy Second-Order Oracles2 Oct 2026
- 2026Normalize-Then-Precondition: A Hierarchical Approach to Marginal Scale and Interaction Geometry for LLM Training29 Sep 2026
- 2026Optimizer Memory Schedules for Outscaling the Overtraining Axis4 Sep 2026
- 2026Second-Order Muon Done Right: A Principled Marriage of Spectral Geometry and Curvature10 Aug 2026
- 2026Muon Meets Mamba: Spectral Optimization for State Space Models4 Aug 2026
- 2026PoLoRA: A Preconditioned Orthogonalized LoRA Optimizer20 Jul 2026
- 2026Muse: Representation Geometry of Muon Beyond Normalized Momentum16 Jul 2026
- 2026DMuon: Efficient Distributed Muon Training with Near-Adam Overhead25 Jun 2026
38 more
- 2026SOAP-Bubbles: Structured Weight Uncertainty for Neural Networks22 Jun 2026
- 2026Double Preconditioning (DoPr): Optimization for Test-Time Performance, not Validation Loss4 Jun 2026
- 2026Spectral Scaling Laws of Muon2 Jun 2026
- 2026FOAM: Frequency and Operator Error-Based Adaptive Damping Method for Reducing Staleness-Oriented Error for Shampoo1 Jun 2026
- 2026Exploiting weight-space symmetries for approximating curvature30 May 2026
- 2026Reparametrizing Shampoo and SOAP for Subspace Basis Updates and BFloat16 Storage25 May 2026
- 2026Symmetry-Compatible Principle for Optimizer Design: Embeddings, LM Heads, SwiGLU MLPs, and MoE Routers18 May 2026
- 2026DynMuon: A Dynamic Spectral Shaping View of Muon16 May 2026
- 2026Runtime-Orchestrated Second-Order Optimization for Scalable LLM Training15 May 2026
- 2026Second-Order Multi-Level Variance Correction for Modality Competition in Multimodal Models15 May 2026
- 2026Phases of Muon: When Muon Eclipses SignSGD10 May 2026
- 2026Pro-KLShampoo: Projected KL-Shampoo with Whitening Recovered by Orthogonalization7 May 2026
- 2026Demystifying Manifold Constraints in LLM Pre-training6 May 2026
- 2026RMNP: Row-Momentum Normalized Preconditioning for Scalable Matrix-Based Optimization20 Mar 2026
- 2026Mousse: Rectifying the Geometry of Muon with Curvature-Aware Preconditioning10 Mar 2026
- 2026Accelerating LLM Pre-Training through Flat-Direction Dynamics Enhancement26 Feb 2026
- 2026Beyond SGD, Without SVD: Proximal Subspace Iteration LoRA with Diagonal Fractional K-FAC18 Feb 2026
- 2026Clarifying Shampoo: Adapting Spectral Descent to Stochasticity and the Parameter Trajectory10 Feb 2026
- 2026Canzona: A Unified, Asynchronous, and Load-Balanced Framework for Distributed Matrix-based Optimizers4 Feb 2026
- 2026DASH: Faster Shampoo via Batched Block Preconditioning and Efficient Inverse-Root Solvers2 Feb 2026
- 2026PRISM: Distribution-free Adaptive Computation of Matrix Functions for Accelerating Neural Network Training29 Jan 2026
- 2026Convergence Rate Analysis of the AdamW-style Shampoo: Unifying One-Sided and Two-Sided Preconditioning12 Jan 2026
- 2025Smoothing DiLoCo with Primal Averaging for Faster Training of LLMs18 Dec 2025
- 2025Hyperparameter Transfer Enables Consistent Gains of Matrix-Preconditioned Optimizers Across Scales5 Dec 2025
- 2025DyKAF: Dynamical Kronecker Approximation of the Fisher Information Matrix for Gradient Preconditioning9 Nov 2025
- 2025What Really Matters in Matrix-Whitening Optimizers?28 Oct 2025
- 2025How Muon's Spectral Design Benefits Generalization: A Study on Imbalanced Data27 Oct 2025
- 2025MuonBP: Faster Muon via Block-Periodic Orthogonalization19 Oct 2025
- 2025SNOO: Step-K Nesterov Outer Optimizer - The Surprising Effectiveness of Nesterov Momentum Applied to Pseudo-Gradients17 Oct 2025
- 2025Noise-Adaptive Layerwise Learning Rates: Accelerating Geometry-Aware Optimization for Deep Neural Network Training15 Oct 2025
- 2025NorMuon: Making Muon more efficient and scalable7 Oct 2025
- 2025DeMuon: A Decentralized Muon for Matrix Optimization over Graphs1 Oct 2025
- 2025FedMuon: Federated Learning with Bias-corrected LMO-based Optimization30 Sep 2025
- 2025Understanding SOAP from the Perspective of Gradient Whitening26 Sep 2025
- 2025Understanding and Improving Shampoo and SOAP via Kullback-Leibler Minimization3 Sep 2025
- 2025Beyond the Mean: Fisher-Orthogonal Projection for Natural Gradient Descent in Large Batch Training19 Aug 2025
- 2025Structure-Preserving Digital Twins via Conditional Neural Whitney Forms9 Aug 2025
- 2025A Stable Whitening Optimizer for Efficient Neural Network Training8 Jun 2025
50 newest of 77 All 77 (JSON)
- 2024Old Optimizer, New Norm: An Anthologycited by 193
- 2024SOAP: Improving and Stabilizing Shampoo using Adamcited by 192
- 2025The Polar Express: Optimal Matrix Sign Methods and Their Application to the Muon Algorithmcited by 110
- 2025NorMuon: Making Muon more efficient and scalablecited by 84
- 2024Modular Duality in Deep Learningcited by 77
- 2025Dion: Distributed Orthonormalized Updatescited by 68
- 2024MARS: Unleashing the Power of Variance Reduction for Training Large Modelscited by 64
- 2024A New Perspective on Shampoo's Preconditionercited by 59
- 2025ASGO: Adaptive Structured Gradient Optimizationcited by 57
- 2025Implicit Bias of Spectral Descent and Muon on Multiclass Separable Datacited by 41
- 2025MuonBP: Faster Muon via Block-Periodic Orthogonalizationcited by 35
- 2024LoRA Done RITE: Robust Invariant Transformation Equilibration for LoRA Optimizationcited by 32
12 most cited of 75 All 75 (JSON)
- 2026A Refresh Interval Does Not Fully Specify a Refresh Schedule: Learning-Rate-Dependent Placement in Kronecker-Preconditioned Language Model Training13 Oct 2026
- 2026Minimax Optimality of Shampoo for Nonstationary Stochastic Optimization12 Oct 2026
- 2026Towards Easier-to-Tune Training Algorithms: New Results from AlgoPerf9 Oct 2026
- 2026How Bregman Divergences Shape Shampoo6 Oct 2026
- 2026Near-Optimal Convex Optimization with Lazy Second-Order Oracles2 Oct 2026
- 2026Normalize-Then-Precondition: A Hierarchical Approach to Marginal Scale and Interaction Geometry for LLM Training29 Sep 2026
- 2026Optimizer Memory Schedules for Outscaling the Overtraining Axis4 Sep 2026
- 2026Second-Order Muon Done Right: A Principled Marriage of Spectral Geometry and Curvature10 Aug 2026
- 2026PoLoRA: A Preconditioned Orthogonalized LoRA Optimizer20 Jul 2026
- 2026Muse: Representation Geometry of Muon Beyond Normalized Momentum16 Jul 2026
- 2026DMuon: Efficient Distributed Muon Training with Near-Adam Overhead25 Jun 2026
- 2026SOAP-Bubbles: Structured Weight Uncertainty for Neural Networks22 Jun 2026
12 newest of 75 All 75 (JSON)