A Primal-Dual Framework for Transformers and Neural Networks
Not on the map. Why?
Abstract (arXiv)
Self-attention is key to the remarkable success of transformers in sequence modeling tasks including many applications in natural language processing and computer vision. Like neural network layers, these attention mechanisms are often developed by heuristics and experience. To provide a principled framework for constructing attention layers in transformers, we show that the self-attention corresponds to the support vector expansion derived from a support vector regression problem, whose primal formulation has the form of a neural network layer. Using our framework, we derive popular attention layers used in practice and propose two new attentions: 1) the Batch Normalized Attention (Attention-BN) derived from the batch normalization layer and 2) the Attention with Scaled Head (Attention-SH) derived from using less training data to fit the SVR model. We empirically demonstrate the advantages of the Attention-BN and Attention-SH in reducing head redundancy, increasing the model's accuracy, and improving the model's efficiency in a variety of practical applications including image and time-series classification.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Builds on 74 of its 98 references that are in the map. First posted on arXiv 19 Jun 2024.
Builds on
74 of 98 references.
References · 74
- 2017Attention Is All You Needcited by 59,932
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,456
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 29,915
- 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,266
- 2021Swin Transformer: Hierarchical Vision Transformer using Shifted Windowscited by 12,082
- 2014ImageNet Large Scale Visual Recognition Challengecited by 8,441
- 2015Batch Normalization: Accelerating Deep Network Training by Reducing Internal Covariate Shiftcited by 6,979
- 2020Training data-efficient image transformers & distillation through attentioncited by 4,560
- 2014Neural Machine Translation by Jointly Learning to Align and Translatecited by 4,530
38 more
- 2021Zero-Shot Text-to-Image Generationcited by 4,276
- 2019DistilBERT, a distilled version of BERT: smaller, faster, cheaper and lightercited by 4,243
- 2014Learning Phrase Representations using RNN Encoder-Decoder for Statistical Machine Translationcited by 4,016
- 2017MobileNets: Efficient Convolutional Neural Networks for Mobile Vision Applicationscited by 3,827
- 2020Longformer: The Long-Document Transformercited by 3,362
- 2019XLNet: Generalized Autoregressive Pretraining for Language Understandingcited by 2,801
- 2018CBAM: Convolutional Block Attention Modulecited by 2,463
- 2017Non-local Neural Networkscited by 2,290
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 1,979
- 2020Conformer: Convolution-augmented Transformer for Speech Recognitioncited by 1,838
- 2019Transformer-XL: Attentive Language Models Beyond a Fixed-Length Contextcited by 1,830
- 2020Reformer: The Efficient Transformercited by 1,658
- 2021ViViT: A Video Vision Transformercited by 1,610
- 2020Rethinking Attention with Performerscited by 1,584
- 2021Decision Transformer: Reinforcement Learning via Sequence Modelingcited by 1,528
- 2019Generating Long Sequences with Sparse Transformerscited by 1,523
- 2020Linformer: Self-Attention with Linear Complexitycited by 1,462
- 2020Point Transformercited by 1,462
- 2018Self-Attention with Relative Position Representationscited by 1,112
- 2021Video Swin Transformercited by 1,090
- 2019BERT Rediscovers the Classical NLP Pipelinecited by 1,046
- 2019What Does BERT Look At? An Analysis of BERT's Attentioncited by 994
- 2021CvT: Introducing Convolutions to Vision Transformerscited by 946
- 2019Analyzing Multi-Head Self-Attention: Specialized Heads Do the Heavy Lifting, the Rest Can Be Prunedcited by 844
- 2018Image Transformercited by 770
- 2020PCT: Point cloud transformercited by 730
- 2020Long Range Arena: A Benchmark for Efficient Transformerscited by 696
- 2021Offline Reinforcement Learning as One Big Sequence Modeling Problemcited by 636
- 2019Designing and Interpreting Probes with Control Taskscited by 608
- 2019Patient Knowledge Distillation for BERT Model Compressioncited by 502
- 2020Efficient Content-Based Sparse Attention with Routing Transformerscited by 469
- 2021Rethinking Graph Transformers with Spectral Attentioncited by 468
- 2020A Transformer-based Framework for Multivariate Time Series Representation Learningcited by 449
- 2018Efficient Attention: Attention with Linear Complexitiescited by 366
- 2019Axial Attention in Multidimensional Transformerscited by 350
- 2021Random Feature Attentioncited by 350
- 2018Generating Wikipedia by Summarizing Long Sequencescited by 333
- 2021Choose a Transformer: Fourier or Galerkincited by 333
50 most cited of 74 All 74 (JSON)
Built on by
Citing papers per year: 2025: 3; 2026: 1.
4 papers.
- 2025Tight Clusters Make Specialized Expertscited by 8
- 2025Transformer Meets Twicing: Harnessing Unattended Residual Informationcited by 3
- 2025Compact Vision Transformer by Reduction of Kernel Complexitycited by 0
- 2026VideoSEMA: a scalable and efficient Mamba-like attention for video understandingcited by 0
- 2026VideoSEMA: a scalable and efficient Mamba-like attention for video understanding16 Jul 2026
- 2025Compact Vision Transformer by Reduction of Kernel Complexity17 Jul 2025
- 2025Transformer Meets Twicing: Harnessing Unattended Residual Information2 Mar 2025
- 2025Tight Clusters Make Specialized Experts21 Feb 2025