arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2502.02407cs.LGcs.CLstat.ML

避免虚假锐度最小化拓宽SAM的适用性

Avoiding spurious sharpness minimization broadens applicability of SAM

Google DeepMind(谷歌DeepMind);ETH Zürich(苏黎世联邦理工学院)

Sidak Pal Singh, Hossein Mobahi, Atish Agarwala, Yann Dauphin

AI总结:

本文发现SAM在NLP中因logit统计量正则化导致性能下降,提出Functional-SAM及预条件扰动方法避免虚假锐度最小化,在多种训练设置和模型规模上优于AdamW和SAM基线。

摘要:

诸如锐度感知最小化(SAM)等曲率正则化技术在视觉任务中已展现出提升泛化能力的巨大潜力。然而,我们发现SAM在自然语言处理(NLP)等领域表现不佳,即使使用两倍的计算预算,也常常导致性能下降。我们研究了跨领域的差异,发现在NLP环境中,SAM主要被对logit统计量的正则化所主导,而不是改善函数本身的几何性质。我们利用这一观察结果开发了一种替代算法,称为Functional-SAM,该算法仅通过修改神经网络所实现的整体函数的统计量来正则化曲率,并避免通过logit操作进行虚假最小化。此外,我们认为对SAM扰动进行预条件处理也能防止虚假最小化,并且当与Functional-SAM结合时,能带来进一步的改进。我们提出的算法在固定长度和Chinchilla式训练设置下,以相同步数训练时,在多种模型规模(包括十亿参数规模)上均表现出优于AdamW和SAM基线的性能。总体而言,我们的工作强调了更精确地刻画锐度对于将曲率正则化扩展到大型语言模型(LLMs)的重要性。

英文摘要:

Curvature regularization techniques like Sharpness Aware Minimization (SAM) have shown great promise in improving generalization on vision tasks. However, we find that SAM performs poorly in domains like natural language processing (NLP), often degrading performance -- even with twice the compute budget. We investigate the discrepancy across domains and find that in the NLP setting, SAM is dominated by regularization of the logit statistics -- instead of improving the geometry of the function itself. We use this observation to develop an alternative algorithm we call Functional-SAM, which regularizes curvature only through modification of the statistics of the overall function implemented by the neural network, and avoids spurious minimization through logit manipulation. Furthermore, we argue that preconditioning the SAM perturbation also prevents spurious minimization, and when combined with Functional-SAM, it gives further improvements. Our proposed algorithms show improved performance over AdamW and SAM baselines when trained for an equal number of steps, in both fixed-length and Chinchilla-style training settings, at various model scales (including billion-parameter scale). On the whole, our work highlights the importance of more precise characterizations of sharpness in broadening the applicability of curvature regularization to large language models (LLMs).

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑