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

改革者:高效的Transformer

Reformer: The Efficient Transformer

U.C. Berkeley(加州大学伯克利分校);Google Research(谷歌研究院)

Nikita Kitaev, Łukasz Kaiser, Anselm Levskaya

摘要:

大型Transformer模型通常在许多任务上实现最先进的结果,但训练这些模型的成本可能过高,特别是在长序列上。我们介绍两种技术来提高Transformers的效率。首先,我们将点积注意力替换为使用局部敏感哈希的注意力,将其复杂度从O($L^2$)改为O($L\log L$),其中$L$是序列的长度。此外,我们使用可逆残差层代替标准残差,这允许在训练过程中仅存储激活一次而不是$N$次,其中$N$是层数。生成的模型Reformer的性能与Transformer模型相当,同时在长序列上的内存效率更高,速度更快。

英文摘要:

Large Transformer models routinely achieve state-of-the-art results on a number of tasks but training these models can be prohibitively costly, especially on long sequences. We introduce two techniques to improve the efficiency of Transformers. For one, we replace dot-product attention by one that uses locality-sensitive hashing, changing its complexity from O($L^2$) to O($L\log L$), where $L$ is the length of the sequence. Furthermore, we use reversible residual layers instead of the standard residuals, which allows storing activations only once in the training process instead of $N$ times, where $N$ is the number of layers. The resulting model, the Reformer, performs on par with Transformer models while being much more memory-efficient and much faster on long sequences.

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

↑