mlsanityData to 14 Oct 2026

Towards Better Multi-head Attention via Channel-wise Sample Permutation

arXiv 2410.10914 ↗First posted 14 Oct 2024cs.LG cs.CL cs.CVcited by 2

Not on the map. Why?

Abstract (arXiv)

Transformer plays a central role in many fundamental deep learning models, e.g., the ViT in computer vision and the BERT and GPT in natural language processing, whose effectiveness is mainly attributed to its multi-head attention (MHA) mechanism. In this study, we propose a simple and novel channel-wise sample permutation (CSP) operator, achieving a new structured MHA with fewer parameters and lower complexity. Given an input matrix, CSP circularly shifts the samples of different channels with various steps and then sorts grouped samples of each channel. This operator is equivalent to implicitly implementing cross-channel attention maps as permutation matrices, which achieves linear complexity and suppresses the risk of rank collapse when representing data. We replace the MHA of some representative models with CSP and test the CSP-based models in several discriminative tasks, including image classification and long sequence analysis. Experiments show that the CSP-based models achieve comparable or better performance with fewer parameters and lower computational costs than the classic Transformer and its state-of-the-art variants. The code is available at https://github.com/DaShenZi721/CSP.

Key facts. Cited by 2 papers in the map (data through 14 Oct 2026). Builds on 46 of its 57 references that are in the map. First posted on arXiv 14 Oct 2024.

Builds on

46 of 57 references.

References · 46

  1. 2017Attention Is All You Needcited by 60,361
  2. 2020Language Models are Few-Shot Learnerscited by 32,419
  3. 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 30,186
  4. 2023LLaMA: Open and Efficient Foundation Language Modelscited by 14,132
  5. 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
  6. 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 4,718
  7. 2022FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awarenesscited by 3,673
  8. 2020Longformer: The Long-Document Transformercited by 3,413
  9. 2023FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioningcited by 2,598
  10. 2021Efficiently Modeling Long Sequences with Structured State Spacescited by 2,465
  11. 2013Sinkhorn Distances: Lightspeed Computation of Optimal Transportation Distancescited by 2,316
  12. 2020Informer: Beyond Efficient Transformer for Long Sequence Time-Series Forecastingcited by 2,169
34 more
  1. 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 2,022
  2. 2020Big Bird: Transformers for Longer Sequencescited by 1,684
  3. 2020Reformer: The Efficient Transformercited by 1,668
  4. 2020Rethinking Attention with Performerscited by 1,601
  5. 2019Generating Long Sequences with Sparse Transformerscited by 1,546
  6. 2020Linformer: Self-Attention with Linear Complexitycited by 1,474
  7. 2020Point Transformercited by 1,470
  8. 2017ShuffleNet: An Extremely Efficient Convolutional Neural Network for Mobile Devicescited by 1,200
  9. 2018ShuffleNet V2: Practical Guidelines for Efficient CNN Architecture Designcited by 1,136
  10. 2023RWKV: Reinventing RNNs for the Transformer Eracited by 827
  11. 2022Simplified State Space Layers for Sequence Modelingcited by 788
  12. 2020Long Range Arena: A Benchmark for Efficient Transformerscited by 700
  13. 2021Attention is Not All You Need: Pure Attention Loses Rank Doubly Exponentially with Depthcited by 419
  14. 2021Mesh Graphormercited by 265
  15. 2020Sparse Sinkhorn Attentioncited by 251
  16. 2020Transformer Hawkes Processcited by 235
  17. 2018Sorting out Lipschitz function approximationcited by 213
  18. 2019Transformer Dissection: A Unified Understanding of Transformer's Attention via the Lens of Kernelcited by 213
  19. 2022cosFormer: Rethinking Softmax in Attentioncited by 213
  20. 2020Synthesizer: Rethinking Self-Attention in Transformer Modelscited by 205
  21. 2022Mega: Moving Average Equipped Gated Attentioncited by 179
  22. 2023EfficientViT: Memory Efficient Vision Transformer with Cascaded Group Attentioncited by 172
  23. 2021Sinkformers: Transformers with Doubly Stochastic Attentioncited by 138
  24. 2018ListOps: A Diagnostic Dataset for Latent Tree Learningcited by 129
  25. 2021AS-MLP: An Axial Shifted MLP Architecture for Visioncited by 101
  26. 2018Learning long-range spatial dependencies with horizontal gated-recurrent unitscited by 98
  27. 2021Luna: Linear Unified Nested Attentioncited by 96
  28. 2021S2-MLP: Spatial-Shift MLP Architecture for Visioncited by 83
  29. 2021Hire-MLP: Vision MLP via Hierarchical Rearrangementcited by 66
  30. 2024SHViT: Single-Head Vision Transformer with Memory Efficient Macro Designcited by 56
  31. 2020Approximating Lipschitz continuous functions with GroupSort neural networkscited by 27
  32. 2022Towards a General Purpose CNN for Long Range Dependencies in NDcited by 16
  33. 2024Incorporating Exponential Smoothing into MLP: A Simple but Effective Sequence Modelcited by 2
  34. 2024S3Attention: Improving Long Sequence Attention with Smoothed Skeleton Sketchingcited by 2

Built on by

Cited by year

Citing papers per year: 2025: 2.

2 papers.