Vision Xformers: Efficient Attention for Image Classification
Not on the map. Why?
Abstract (arXiv)
Although transformers have become the neural architectures of choice for natural language processing, they require orders of magnitude more training data, GPU memory, and computations in order to compete with convolutional neural networks for computer vision. The attention mechanism of transformers scales quadratically with the length of the input sequence, and unrolled images have long sequence lengths. Plus, transformers lack an inductive bias that is appropriate for images. We tested three modifications to vision transformer (ViT) architectures that address these shortcomings. Firstly, we alleviate the quadratic bottleneck by using linear attention mechanisms, called X-formers (such that, X in Performer, Linformer, Nystr"omformer), thereby creating Vision X-formers (ViXs). This resulted in up to a seven times reduction in the GPU memory requirement. We also compared their performance with FNet and multi-layer perceptron mixers, which further reduced the GPU memory requirement. Secondly, we introduced an inductive bias for images by replacing the initial linear embedding layer by convolutional layers in ViX, which significantly increased classification accuracy without increasing the model size. Thirdly, we replaced the learnable 1D position embeddings in ViT with Rotary Position Embedding (RoPE), which increases the classification accuracy for the same model size. We believe that incorporating such changes can democratize transformers by making them accessible to those with limited data and computing resources.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Builds on 26 of its 30 references that are in the map. First posted on arXiv 5 Jul 2021.
Builds on
26 of 30 references.
References · 26
- 2017Attention Is All You Needcited by 59,932
- 2015Deep Residual Learning for Image Recognitioncited by 51,809
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2017Squeeze-and-Excitation Networkscited by 4,763
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 4,581
- 2014Going Deeper with Convolutionscited by 4,231
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 1,979
- 2021Pyramid Vision Transformer: A Versatile Backbone for Dense Prediction without Convolutionscited by 1,960
- 2020Rethinking Attention with Performerscited by 1,584
- 2019Generating Long Sequences with Sparse Transformerscited by 1,523
- 2020Linformer: Self-Attention with Linear Complexitycited by 1,462
- 2021MLP-Mixer: An all-MLP Architecture for Visioncited by 1,441
14 more
- 2021Tokens-to-Token ViT: Training Vision Transformers from Scratch on ImageNetcited by 1,096
- 2016SqueezeNet: AlexNet-level accuracy with 50x fewer parameters and <0.5MB model sizecited by 1,054
- 2021Transformers in Vision: A Surveycited by 1,009
- 2021CvT: Introducing Convolutions to Vision Transformerscited by 946
- 2020Efficient Transformers: A Surveycited by 784
- 2018Image Transformercited by 770
- 2020Long Range Arena: A Benchmark for Efficient Transformerscited by 696
- 2021LeViT: a Vision Transformer in ConvNet's Clothing for Faster Inferencecited by 475
- 2021Nystr"omformer: A Nystr"om-Based Algorithm for Approximating Self-Attentioncited by 468
- 2021Early Convolutions Help Transformers See Bettercited by 395
- 2021Rethinking Spatial Dimensions of Vision Transformerscited by 361
- 2021FNet: Mixing Tokens with Fourier Transformscited by 343
- 2021Escaping the Big Data Paradigm with Compact Transformerscited by 261
- 2020Train Large, Then Compress: Rethinking Model Size for Efficient Training and Inference of Transformerscited by 67
Built on by
Citing papers per year: 2022: 1; 2023: 2; 2024: 1.
4 papers.
- 2023SEAL: Simultaneous Label Hierarchy Exploration And Learningcited by 6
- 2022Convolutional Xformers for Visioncited by 5
- 2023Image Reconstruction using Enhanced Vision Transformercited by 2
- 2024Continual Low-Rank Scaled Dot-product Attentioncited by 2
- 2024Continual Low-Rank Scaled Dot-product Attention4 Dec 2024
- 2023Image Reconstruction using Enhanced Vision Transformer11 Jul 2023
- 2023SEAL: Simultaneous Label Hierarchy Exploration And Learning26 Apr 2023
- 2022Convolutional Xformers for Vision25 Jan 2022