Skip to main content

Emerging Optimizers

codecov CICD NeMo Python 3.12+ GitHub Repo stars Documentation

Overview

Emerging Optimizers is a research project focused on understanding and optimizing the algorithmic behavior of emerging optimizers (including Shampoo, SOAP, Muon, and others) and their implications to performance of GPU systems in LLM training.

⚠️ Note: Emerging-Optimizers is under active development. All APIs are experimental and subject to change. New features, improvements, and documentation updates are released regularly. Your feedback and contributions are welcome, and we encourage you to follow along as new updates roll out.

Background

What are Emerging Optimizers?

Emerging optimizers represent a class of novel optimization algorithms that go beyond traditional first-order methods like Adam or SGD. These include optimizers that use matrix-based (non-diagonal) preconditioning, orthogonalization techniques, and other innovative approaches to achieve faster convergence and improved training efficiency.

Examples include Shampoo, which uses Kronecker-factored preconditioning (arXiv:1802.09568), and Muon, which uses Newton-Schulz orthogonalization (arXiv:2502.16982).

Why They Matter

Emerging optimizers have demonstrated significant practical impact in large-scale language model training. Most notably, Muon was used to train the Kimi K2 model (arXiv:2507.20534), showcasing the effectiveness of these novel approaches at scale. These optimizers can:

  • Achieve faster convergence, reducing the number of training steps required
  • Improve final model quality through better conditioning of the optimization landscape
  • Enable more efficient hyperparameter tuning due to reduced sensitivity to learning rates

Installation

Prerequisites

  • Python 3.12 (Release v0.1.0 is the last version supports Python 3.10)
  • PyTorch 2.0 or higher

Install from Source

git clone https://github.com/NVIDIA-NeMo/Emerging-Optimizers.git
cd Emerging-Optimizers
pip install .

Usage

Example

Refer to tests for usage of different optimizers, e.g. tests/test_orthogonalized_optimizer.py::MuonTest.

Integration with Megatron Core

Integration with Megatron Core is available in dev branch, e.g. emerging_optimizers.py

Benchmarks

Coming soon.

License

This project is licensed under the Apache License 2.0 - see the LICENSE file for details.

Release files for emerging-optimizers 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for emerging-optimizers 0.3.0
File Size Uploaded
emerging_optimizers-0.3.0.tar.gz 101.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for emerging-optimizers 0.3.0
File Interpreter ABI Platform
emerging_optimizers-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 204.6 kB

Release files / emerging_optimizers-0.3.0.tar.gz

Download URL emerging_optimizers-0.3.0.tar.gz
Size 101.7 kB
Tags Source
SHA-256 checksum
How to use checksums
4eb96f38280dab17d1fa5bf46bdd7a110b1ab399e98891d0f90c467fb134e0ce
BLAKE2b-256 checksum
How to use checksums
c5bb3fb2bfacc364b82356f886ce1babbc9b9041bda32bc46ae4a12f77a24d9c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.3

Release files / emerging_optimizers-0.3.0-py3-none-any.whl

Download URL emerging_optimizers-0.3.0-py3-none-any.whl
Size 102.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e993682a8b93b6953b3056b0d4e2714e3a3182b0c85f456bcc78d76cd7b47429
BLAKE2b-256 checksum
How to use checksums
3afdb8aa6cad45beae4d6b585ad55dad32ed95ac74097dd7bfb8952a72421fee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.3

Release history Release notifications | RSS feed

999.9.9

1 release file

This release

0.3.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page