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

持续Transformer:用于在线推理的无冗余注意力

Continual Transformers: Redundancy-Free Attention for Online Inference

Aarhus University(奥胡斯大学)

Lukas Hedegaard, Arian Bakhtiarnia, Alexandros Iosifidis

AI总结:

针对Transformer在线时序推理中因序列重叠导致的计算冗余问题,提出计算顺序等价于原始Transformer Encoder的Continual Transformer Encoder,在保持预测性能的同时将单块和双块架构的浮点运算量分别降低达63倍和2.6倍。

摘要:

常规形式的Transformer本质上只能处理整个token序列,而无法一次仅处理一个token。因此,在时间序列数据的在线推理中,由于连续token序列的重叠,其使用会导致大量冗余。在本研究中,我们提出了Scaled Dot-Product Attention的新颖公式,使Transformer能够在持续输入流上执行高效的在线逐token推理。重要的是,我们的修改纯粹针对计算顺序,而输出和学习的权重与原始Transformer Encoder完全相同。我们在THUMOS14、TVSeries和GTZAN数据集上通过实验验证了我们的Continual Transformer Encoder,取得了显著成果:我们的Continual单块和双块架构在保持预测性能的同时,将每次预测的浮点运算量分别减少了高达63倍和2.6倍。

英文摘要:

Transformers in their common form are inherently limited to operate on whole token sequences rather than on one token at a time. Consequently, their use during online inference on time-series data entails considerable redundancy due to the overlap in successive token sequences. In this work, we propose novel formulations of the Scaled Dot-Product Attention, which enable Transformers to perform efficient online token-by-token inference on a continual input stream. Importantly, our modifications are purely to the order of computations, while the outputs and learned weights are identical to those of the original Transformer Encoder. We validate our Continual Transformer Encoder with experiments on the THUMOS14, TVSeries and GTZAN datasets with remarkable results: Our Continual one- and two-block architectures reduce the floating point operations per prediction by up to 63x and 2.6x, respectively, while retaining predictive performance.

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

↑