arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2404.00798cs.LG
收藏

关于通过共享记忆进行注意力分解的困难

On Difficulties of Attention Factorization through Shared Memory

Charles University in Prague(布拉格查理大学);Czech Technical University in Prague(布拉格捷克技术大学)

Uladzislau Yorsh, Martin Holeňa, Ondřej Bojar, David Herel

AI总结:

本文研究基于共享记忆的注意力分解方法,发现直接通过注意力操作与外部记忆交互是次优的,并提出在与记忆通信前先对输入信号进行过滤,从而显著提升模型性能。

摘要:

Transformer 已在众多领域彻底改变了深度学习,包括自然语言处理、计算机视觉和音频处理。其优势在于注意力机制,该机制能够发现复杂的输入关系。然而,该机制的二次方时间和记忆复杂度对更大输入构成了挑战。研究人员目前正在研究诸如 Linear Unified Nested Attention (Luna) 或 Memory Augmented Transformer 等模型,这些模型利用外部可学习记忆,要么将注意力计算复杂度降低到线性,要么在分块处理中在块之间传播信息。我们的发现挑战了对这些模型的传统看法,揭示了通过注意力操作直接与记忆交互是次优的,并且在与记忆通信之前对输入信号进行过滤可能会显著提高性能。

英文摘要:

Transformers have revolutionized deep learning in numerous fields, including natural language processing, computer vision, and audio processing. Their strength lies in their attention mechanism, which allows for the discovering of complex input relationships. However, this mechanism's quadratic time and memory complexity pose challenges for larger inputs. Researchers are now investigating models like Linear Unified Nested Attention (Luna) or Memory Augmented Transformer, which leverage external learnable memory to either reduce the attention computation complexity down to linear, or to propagate information between chunks in chunk-wise processing. Our findings challenge the conventional thinking on these models, revealing that interfacing with the memory directly through an attention operation is suboptimal, and that the performance may be considerably improved by filtering the input signal before communicating with memory.

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

↑