Adam-mini: Use Fewer Learning Rates To Gain More

Yushun Zhang, Congliang Chen, Ziniu Li, Tian Ding, Chenwei Wu, Yinyu Ye, Zhimin Luo, Ruoyu Sun

arXiv:2406.16793 · 2026-07-27 공개 · arXiv · PDF

language-models memory-efficiency learning-rate-optimization throughput-improvement gpu-communication adam-mini hessian-structure neural-network-optimization

Abstract

We propose Adam-mini, an optimizer that achieves on par or better performance than AdamW with 50% less memory footprint. Adam-mini reduces memory by cutting down the learning rate resources in Adam (i.e., $1/\sqrt{v}$). By investigating the Hessian structure of neural nets, we find Adam's $v$ might not function at its full potential as effectively as we expected. We find that $\geq$ 99.9% of these learning rates in $v$ could be harmlessly removed if we (1) carefully partition the parameters into blocks following our new principle on Hessian structure; (2) assign a single but good learning rate to each parameter block. We then provide one simple way to find good learning rates and propose Adam-mini. Empirically, we verify that Adam-mini performs on par or better than AdamW on various language models sized from 39M to 13B for pre-training, supervised fine-tuning, and RLHF. The reduced memory footprint of Adam-mini also alleviates communication overheads among GPUs, thereby increasing throughput. For instance, Adam-mini achieves 49.6% higher throughput than AdamW when pre-training Llama 2-7B on $2\times$ A800-80GB GPUs, which saves 33% wall-clock time for pre-training.

한국어 요약

한 줄 요약

Adam-mini는 AdamW 대비 50% 적은 메모리 사용으로 동일 또는 우수한 성능을 달성하는 경량 최적화 알고리즘이다.

핵심 기여도

핵심 아이디어

Adam의 $v$ 성분은 각 파라미터에 개별적인 학습률을 할당하지만, 이 연구는 신경망의 Hessian 행렬이 블록 대각선 구조를 띈다는 사실을 활용해, 블록 단위로 단일 학습률을 할당할 수 있음을 제시한다. 이는 $v$의 대부분을 제거하면서도 성능을 유지할 수 있다는 통찰을 제공한다. 구체적으로, $v$의 블록 평균을 기반으로 $\eta/\sqrt{v_b}$를 블록별 학습률로 사용하는 방식을 제안하며, 이는 Adam의 메모리 사용량을 50% 감소시키는 핵심 아이디어이다.

기술적 접근법

주요 결과

의의 및 한계

Adam-mini는 대규모 언어 모델 학습에서 메모리 효율성을 극대화하면서도 성능을 유지하는 데 기여한다. 특히, GPU 메모리 제약을 받는 연구자나 산업 현장에서 유용하다. 또한, CPU 오프로드와 GPU 간 통신 오버헤드를 줄여 학습 속도를 향상시킨다. 그러나 Hessian 구조 기반 블록 분할은 모델 종류에 따라 효과가 달라질 수 있으며, 블록 분할 방법의 최적화가 여전히 필요하다는 한계가 있다.

실용적 활용

Adam-mini는 GPU 메모리가 제한된 환경에서 대규모 언어 모델 학습, 이미지/그래프 모델 학습, 디퓨전 모델 학습 등에 적용 가능하다. 특히, 연구자들이 저비용으로 대형 모델을 학습할 수 있도록 지원하며, 클라우드 기반 학습 환경에서도 유용하다.