arXiv:2503.12295cs.LGcs.NA2025-03ICLR被引 2

用序列模型学高精度最小二乘算法,首次实现接近机器精度的求解。

Towards Learning High-Precision Least Squares Algorithms with Sequence Models

论文配图:Towards Learning High-Precision Least Squares Algorithms with Sequence Models
图 1 · 摘自论文原文
  • 采用多项式架构替代Transformer,解决高精度乘法难题。
  • 训练后模型误差比传统Transformer低10万倍,泛化差距缩小1万倍。
  • 适合研究可学习数值算法、高精度深度学习的学者参考。

本文探究序列模型能否学习数值算法(如梯度下降)求解最小二乘问题。目标是继承数值分析中两个关键特性:(1)机器精度,即解接近浮点误差极限;(2)数值通用性,即在多种问题实例上有效。发现现有Transformer方法无法满足这些要求,且其架构与训练流程存在局限。首先,软最大Transformer难以实现高精度乘法,阻碍了数值算法的精确学习。其次,提出完全由多项式构成的新架构,能高效表示梯度下降迭代过程。最后,识别训练中的精度瓶颈,通过高精度训练方案降低随机梯度噪声。该方案使两种多项式架构——门控卷积和线性注意力——成功完成最小二乘问题的梯度下降迭代。首次实现接近机器精度的端到端学习。迭代应用下,模型均方误差比端到端训练的Transformer低10万倍,分布外问题的泛化差距缩小1万倍。为最小二乘问题的可学习数值算法迈进一步。

原文摘要 · Abstract (English)

This paper investigates whether sequence models can learn to perform numerical algorithms, e.g. gradient descent, on the fundamental problem of least squares. Our goal is to inherit two properties of standard algorithms from numerical analysis: (1) machine precision, i.e. we want to obtain solutions that are accurate to near floating point error, and (2) numerical generality, i.e. we want them to apply broadly across problem instances. We find that prior approaches using Transformers fail to meet these criteria, and identify limitations present in existing architectures and training procedures. First, we show that softmax Transformers struggle to perform high-precision multiplications, which prevents them from precisely learning numerical algorithms. Second, we identify an alternate class of architectures, comprised entirely of polynomials, that can efficiently represent high-precision gradient descent iterates. Finally, we investigate precision bottlenecks during training and address them via a high-precision training recipe that reduces stochastic gradient noise. Our recipe enables us to train two polynomial architectures, gated convolutions and linear attention, to perform gradient descent iterates on least squares problems. For the first time, we demonstrate the ability to train to near machine precision. Applied iteratively, our models obtain 100,000x lower MSE than standard Transformers trained end-to-end and they incur a 10,000x smaller generalization gap on out-of-distribution problems. We make progress towards end-to-end learning of numerical algorithms for least squares.

数值算法序列模型高精度计算

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