mlsanityData to 26 Nov 2026

Transformers as Generic Deep Neural Networks: Exact Compilation, the Cost of Removing Activation-Activation Products, and Multi-Agent Attention Clustering

arXiv 2610.28958 ↗Submitted 20 Oct 2026cs.LG cs.MAcited by 0

Not on the map. Why?

Abstract (arXiv)

Transformers are deployed as a special model class. Neural processing units (NPU) add dedicated operators for attention and normalization, and quantization relies on Transformer-specific algorithms. We show the computation does not force this. Every Transformer block, with attention, LayerNorm and a GELU MLP, compiles exactly into a generic deep neural network built from fixed affine maps, routing and the square, sigmoid and inverse square root, plus GELU or its sigmoid approximation. Without activation-activation products, every transform-wise compilation adds at least N2 scalar nonlinear evaluations per head for dense scores. Keeping that one operation type removes this cost; its elementwise form, present on every surveyed NPU, suffices with the sigmoid and inverse square root. For top-k attention with exchangeable tail scores, we prove that exact or conditional-mean tail mass gives an unbiased, minimum-mean-square-error estimate of the attention distribution, while tail drop is conditionally biased. When queries or agents cluster, centroids choose the keys first, reducing the number of computed scores from N2 to Nk per head. On DeiT-Tiny, MambaIRv2-Light and Pythia-70M the compiled models match their references with all keys, standard post-training quantization applies, and the exact tail-mass estimate beats tail dropping with half as many keys on DeiT-Tiny and, for k≤8, on Pythia-70M.

Key facts. No citing papers in the map yet (data through 26 Nov 2026). Builds on 41 of its 74 references that are in the map. Submitted 20 Oct 2026.

Builds on

41 of 74 references.

References · 41

  1. 2017Attention Is All You Needcited by 62,125
  2. 2015Distilling the Knowledge in a Neural Networkcited by 10,968
  3. 2017Squeeze-and-Excitation Networkscited by 4,948
  4. 2020Training data-efficient image transformers & distillation through attentioncited by 4,688
  5. 2016Gaussian Error Linear Units (GELUs)cited by 3,745
  6. 2016Pointer Sentinel Mixture Modelscited by 3,345
  7. 2019Searching for MobileNetV3cited by 2,045
  8. 2020GLU Variants Improve Transformercited by 2,000
  9. 2023Pythia: A Suite for Analyzing Large Language Models Across Training and Scalingcited by 1,891
  10. 2017Quantization and Training of Neural Networks for Efficient Integer-Arithmetic-Only Inferencecited by 1,680
  11. 2019Root Mean Square Layer Normalizationcited by 1,624
  12. 2022SmoothQuant: Accurate and Efficient Post-Training Quantization for Large Language Modelscited by 1,487
29 more
  1. 2016Error bounds for approximations with deep ReLU networkscited by 590
  2. 2021A White Paper on Neural Network Quantizationcited by 519
  3. 2020ReZero is All You Need: Fast Convergence at Large Depthcited by 287
  4. 2021Post-Training Quantization for Vision Transformercited by 287
  5. 2021I-BERT: Integer-only BERT Quantizationcited by 264
  6. 2020SpAtten: Efficient Sparse Attention Architecture with Cascade Token and Head Pruningcited by 241
  7. 2021PTQ4ViT: Post-training quantization for vision transformers with twin uniform quantizationcited by 188
  8. 2020The Lipschitz Constant of Self-Attentioncited by 187
  9. 2023A mathematical perspective on Transformerscited by 186
  10. 2021FQ-ViT: Post-Training Quantization for Fully Quantized Vision Transformercited by 162
  11. 2022RepQ-ViT: Scale Reparameterization for Post-Training Quantization of Vision Transformerscited by 146
  12. 2021Scatterbrain: Unifying Sparse and Low-rank Attention Approximationcited by 135
  13. 2024MagicPIG: LSH Sampling for Efficient LLM Generationcited by 133
  14. 2020Fast Transformers with Clustered Attentioncited by 127
  15. 2023ReLU Strikes Back: Exploiting Activation Sparsity in Large Language Modelscited by 106
  16. 2024MambaIRv2: Attentive State Space Restorationcited by 105
  17. 2018Glow: Graph Lowering Compiler Techniques for Neural Networkscited by 80
  18. 2025Transformers without Normalizationcited by 78
  19. 2024Fast On-device LLM Inference with NPUscited by 70
  20. 2021Memory-efficient Transformers via Top-k Attentioncited by 66
  21. 2022THE-X: Privacy-Preserving Transformer Inference with Homomorphic Encryptioncited by 66
  22. 2021Combiner: Full Attention Transformer with Sparse Computation Costcited by 65
  23. 2024Instance-Aware Group Quantization for Vision Transformerscited by 29
  24. 2024More Asymmetry Yields Faster Matrix Multiplicationcited by 28
  25. 2021NN-LUT: Neural Approximation of Non-Linear Operations for Efficient Transformer Inferencecited by 26
  26. 2024IANUS: Integrated Accelerator based on NPU-PIM Unified Memory Systemcited by 14
  27. 2025HATA: Trainable and Hardware-Efficient Hash-Aware Top-k Attention for Scalable Large Model Inferencecited by 8
  28. 2023Multiplication-Free Transformer Training via Piecewise Affine Operationscited by 6
  29. 2024NOVA: NoC-based Vector Unit for Mapping Attention Layers on a CNN Acceleratorcited by 1

Built on by

Not cited yet.