HyperAIHyperAI

Command Palette

Search for a command to run...

4 months ago

Pay Less Attention with Lightweight and Dynamic Convolutions

Felix Wu; Angela Fan; Alexei Baevski; Yann N. Dauphin; Michael Auli

Pay Less Attention with Lightweight and Dynamic Convolutions

Abstract

Self-attention is a useful mechanism to build generative models for language and images. It determines the importance of context elements by comparing each element to the current time step. In this paper, we show that a very lightweight convolution can perform competitively to the best reported self-attention results. Next, we introduce dynamic convolutions which are simpler and more efficient than self-attention. We predict separate convolution kernels based solely on the current time-step in order to determine the importance of context elements. The number of operations required by this approach scales linearly in the input length, whereas self-attention is quadratic. Experiments on large-scale machine translation, language modeling and abstractive summarization show that dynamic convolutions improve over strong self-attention models. On the WMT'14 English-German test set dynamic convolutions achieve a new state of the art of 29.7 BLEU.

Code Repositories

pytorch/fairseq
Official
pytorch
bytedance/neurst
tf
Mentioned in GitHub
dqqcasia/st
tf
Mentioned in GitHub

Benchmarks

BenchmarkMethodologyMetrics
abstractive-text-summarization-on-cnn-dailyDynamic Conv
ROUGE-1: 39.84
ROUGE-2: 16.25
ROUGE-L: 36.73
document-summarization-on-cnn-daily-mailDynamicConv
ROUGE-1: 39.84
ROUGE-2: 16.25
ROUGE-L: 36.73
document-summarization-on-cnn-daily-mailLightConv
ROUGE-1: 39.52
ROUGE-2: 15.97
ROUGE-L: 36.51
language-modelling-on-one-billion-wordDynamicConv
Number of params: 0.34B
PPL: 26.67
machine-translation-on-iwslt2014-germanLightConv
BLEU score: 34.8
machine-translation-on-iwslt2014-germanDynamicConv
BLEU score: 35.2
machine-translation-on-wmt-2017-english-1DynamicConv
BLEU score: 24.4
machine-translation-on-wmt-2017-english-1LightConv
BLEU score: 24.3
machine-translation-on-wmt2014-english-frenchLightConv
BLEU score: 43.1
machine-translation-on-wmt2014-english-frenchDynamicConv
BLEU score: 43.2
machine-translation-on-wmt2014-english-germanLightConv
BLEU score: 28.9
Number of Params: 202M
machine-translation-on-wmt2014-english-germanDynamicConv
BLEU score: 29.7
Number of Params: 213M

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp
Pay Less Attention with Lightweight and Dynamic Convolutions | Papers | HyperAI