arXiv:2608.08961cs.LG2026-08

对比五种优化器与三种梯度策略,找出高效训练的最优组合。

Gradient Under Microscope: Benchmarking Resource Utilization of Memory-Efficient Gradient Computation Methods

论文配图:Gradient Under Microscope: Benchmarking Resource Utilization of Memory-Efficient Gradient Computation Methods
图 1 · 摘自论文原文
  • 测试五种优化器+三种梯度策略在四种模型上的表现。
  • 梯度累积显著降损,语言模型降四倍,视觉语言模型降十倍。
  • 不同模型适配不同策略,需按架构选方法。

AI训练资源消耗加剧,推动在受限硬件上对内存高效训练的系统研究。我们评测了五种梯度优化器(SGD、Adam、Adagrad、Adadelta、共轭梯度下降)在三种内存策略(标准训练、梯度检查点、梯度累积)下的表现,覆盖四种Transformer架构(ViT、ModernBERT、Llama 3.1 1B、NanoVLM),测量训练损失、GPU利用率、训练时间和内存使用。梯度累积是最可靠的策略,在视觉语言模型上使训练损失降低约一个数量级,在语言模型上降低约四倍,且无需额外显存。与常见做法相反,Adam并非普遍更优:Adadelta和SGD在编码器和自回归架构上表现更好。梯度检查点的效果高度依赖架构:提升视觉变换器损失,但严重恶化编码器模型性能,且使内存受限模型训练时间增加高达60%。GPU利用率主要由架构决定,从内存受限语言模型的8–15%到计算受限视觉模型的96–99%不等。这些发现为资源高效模型训练与部署提供实用指导。

原文摘要 · Abstract (English)

AI training's rising resource intensity is straining electricity supplies and carbon budgets, motivating systematic study of memory-efficient training on constrained hardware. We benchmark five gradient optimizers (SGD, Adam, Adagrad, Adadelta, and Conjugate Gradient Descent) under three memory strategies (standard training, gradient checkpointing, and gradient accumulation) across four transformer architectures (ViT, ModernBERT, Llama 3.1 1B, and NanoVLM), measuring training loss, GPU utilization, training time, and memory usage. Gradient accumulation emerges as the most reliable strategy, cutting training loss by roughly an order of magnitude on the vision-language model and about four-fold on the language model without additional GPU memory. Contrary to common practice, Adam is not universally superior: Adadelta and SGD outperform it on the encoder and autoregressive architectures. Gradient checkpointing's effect is strongly architecture-dependent, improving vision transformer loss while severely degrading the encoder model, and it increases training time by up to 60% on memory-bound models. GPU utilization is governed primarily by architecture, ranging from 8-15% for the memory-bound language model to 96-99% for compute-bound vision models. These findings provide practical guidelines for optimizer and gradient-strategy selection in resource-efficient model training and deployment.

梯度优化内存效率训练策略

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。