arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2310.08661cs.LG
收藏

Transformer 的计数与算法泛化

Counting and Algorithmic Generalization with Transformers

Lab42 AI Research Institute(Lab42 人工智能研究院)

Simon Ouellette, Rolf Pfister, Hansueli Jud

AI总结:

本文分析标准 Transformer 中阻碍计数任务分布外泛化的架构因素,并通过消融层归一化和 softmax 注意力归一化,提出一种轻量修改版 Transformer 以提升计数算法泛化能力。

摘要:

机器学习中的算法泛化指学习生成数据的底层算法,并使其能以分布外泛化的方式进行推广。这通常被认为对大多数机器学习算法而言是一项困难任务。本文分析了在需要隐式或显式计数时算法泛化的表现。我们表明,标准 Transformer 所基于的架构决策会阻碍此类任务的分布外性能。特别是,我们讨论了使用层归一化以及通过 softmax 对注意力权重进行归一化所带来的后果。通过消融这些存在问题的操作,我们证明了一种经过修改的 Transformer 在使用非常轻量架构的同时,能够在计数任务上展现出良好的算法泛化性能。

英文摘要:

Algorithmic generalization in machine learning refers to the ability to learn the underlying algorithm that generates data in a way that generalizes out-of-distribution. This is generally considered a difficult task for most machine learning algorithms. Here, we analyze algorithmic generalization when counting is required, either implicitly or explicitly. We show that standard Transformers are based on architectural decisions that hinder out-of-distribution performance for such tasks. In particular, we discuss the consequences of using layer normalization and of normalizing the attention weights via softmax. With ablation of the problematic operations, we demonstrate that a modified transformer can exhibit a good algorithmic generalization performance on counting while using a very lightweight architecture.

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

↑