Self-Attention And Beyond the Infinite: Towards Linear Transformers with Infinite Self-Attention
Equixly API Security, Italy(Equixly API安全公司,意大利);Toyota Motor Europe, Belgium(丰田汽车欧洲公司,比利时);MindVisionLabs, UK(MindVisionLabs,英国);Institute of Cognitive Neuroscience, University College London, UK(伦敦大学学院认知神经科学研究所,英国);GlimpseML, UK(GlimpseML,英国)
Giorgio Roffo, Hazem Abdelkawy, Nilli Lavie, Luke Palmer
备注:
This work was initiated and primarily carried out while working at MindVisionLabs. We gratefully acknowledge the support of Toyota Motor Europe (TME) and Equixly API Security for this work
softmax注意力的二次成本限制了Transformer在高分辨率视觉中的可扩展性。我们引入无限自注意力(InfSA),一种谱重构方法,将每个注意力层视为内容自适应标记图上的扩散步骤,通过折扣的Neumann级数累积多跳交互。这将自注意力与经典图中心性(Katz、PageRank、特征向量中心性)联系起来,用于可解释的标记加权。我们还展示了Neumann核等于吸收马尔可夫链的基本矩阵,因此一个标记的中心性是其在吸收前的随机游走访问次数的期望。我们随后提出了线性-InfSA,一种线性时间变体,通过近似隐式注意力操作符的主特征向量而不形成完整的注意力矩阵。它保持一个固定大小的辅助状态,比例于每个头的维度dh(与序列长度N无关),与Vision Transformers兼容,并在4096x4096上稳定训练,在9216x9216上推理(约332k标记)。在4层ViT(53.5M参数,224x224上59 GFLOPs)中,Linear-InfSA在ImageNet-1K上达到84.7%的top-1准确率,比同等深度的softmax ViT提升3.2个百分点。在ImageNet-V2上,InfViT变体优于所有比较基线(最高79.8% vs 76.8%),表明在分布偏移下的鲁棒性。在A100 40GB GPU上,Linear-InfViT运行速度为231张/秒,能耗为0.87 J/张(比同等深度ViT快13倍),是唯一完成9216x9216推理而不出内存的模型。线性近似与二次操作符的主导特征向量高度匹配(余弦0.985)。
英文摘要:
The quadratic cost of softmax attention limits Transformer scalability in high-resolution vision. We introduce Infinite Self-Attention (InfSA), a spectral reformulation that treats each attention layer as a diffusion step on a content-adaptive token graph, accumulating multi-hop interactions through a discounted Neumann series over attention matrices. This links self-attention to classical graph centrality (Katz, PageRank, eigenvector centrality) for interpretable token weighting. We also show the Neumann kernel equals the fundamental matrix of an absorbing Markov chain, so a token's centrality is its expected number of random-walk visits before absorption. We then propose Linear-InfSA, a linear-time variant that approximates the principal eigenvector of the implicit attention operator without forming the full attention matrix. It keeps an auxiliary state of fixed size proportional to per-head dimension dh (independent of sequence length N), is drop-in compatible with Vision Transformers, and supports stable training at 4096 by 4096 and inference at 9216 by 9216 (about 332k tokens). In a 4-layer ViT (53.5M parameters, 59 GFLOPs at 224 by 224), Linear-InfSA reaches 84.7% top-1 on ImageNet-1K, a +3.2 point architectural gain over an equal-depth softmax ViT trained with the same recipe. On ImageNet-V2, InfViT variants outperform all compared baselines (up to 79.8% vs 76.8%), indicating robustness under distribution shift. On an A100 40GB GPU, Linear-InfViT runs at 231 images/s and 0.87 J/image (13x better throughput and energy than equal-depth ViT) and is the only tested model to complete 9216 by 9216 inference without out-of-memory. The linear approximation closely matches the dominant eigenvector of the quadratic operator (cosine 0.985).
Beyond Grids: Exploring Elastic Input Sampling for Vision Transformers
IDEAS NCBR;Jagiellonian University, Faculty of Mathematics and Computer Science(雅盖隆大学数学与计算机科学学院);Jagiellonian University, Doctoral School of Exact and Natural Sciences(雅盖隆大学精确与自然科学博士学院);University of Warsaw(华沙大学);Warsaw University of Technology(华沙技术大学);Tooploox
Beyond Masking: Demystifying Token-Based Pre-Training for Vision Transformers
University of Chinese Academy of Sciences(中国科学院大学);Huawei Inc.(华为公司);Huazhong University of Science and Technology(华中科技大学);Chinese Academy of Sciences(中国科学院)
MicroViTv2: Beyond the FLOPS for Edge Energy-Friendly Vision Transformers
Department of Electro-Optics, National Formosa University(国立.formosa大学电光学系);Department of Electrical Engineering, National Taipei University(台北国立大学电气工程系);College of Artificial Intelligence and Green Energy, National Yang Ming Chiao Tung University(阳明交通大学人工智能与再生能源学院)
School of Computer Science and Software Engineering, Southwest Petroleum University(计算机科学与软件工程学院,西南石油大学);School of Computing and Artificial Intelligence, Southwest Jiaotong University(计算与人工智能学院,西南交通大学);School of Computing and Artificial Intelligence, Southwestern University of Finance and Economics(计算与人工智能学院,西南财经大学)
Looking Beyond Two Frames: End-to-End Multi-Object Tracking Using Spatial and Temporal Transformers
Monash University(莫纳什大学);The University of Melbourne(墨尔本大学);The University of Adelaide(阿德莱德大学);Australian Institute for Machine Learning(澳大利亚机器学习研究所);Australian Centre for Robotic Vision(澳大利亚机器人视觉中心)
Visual-Word Tokenizer: Beyond Fixed Sets of Tokens in Vision Transformers
Predictive Analytics Lab, University of Sussex, UK(苏塞克斯大学预测分析实验室);University of Surrey, UK(塞夫尔大学);Basque Center for Applied Mathematics, Spain(巴斯克应用数学中心);Monash University, Indonesia(墨尔本大学)
Beyond Augmentation: Cross-Modal Transformer Fusion with Bi-directional Attention for Low-Data Aneurysm Screening
Carnegie Mellon University(卡内基梅隆大学);Artificial Intelligence in Medicine (AIM) Program(医学人工智能(AIM)项目);Mass General Brigham(马萨诸塞总医院);Harvard Medical School(哈佛医学院);Department of Radiation Oncology(放射肿瘤科);Dana-Farber Cancer Institute(达纳-法伯癌症研究所);Brigham and Women’s Hospital(布里洛妇产科医院)
More ConvNets in the 2020s: Scaling up Kernels Beyond 51x51 using Sparsity
University of Texas at Austin(德克萨斯大学奥斯汀分校);Eindhoven University of Technology(埃因霍温理工大学);University of Jyväskylä(于韦斯屈莱大学);University of Twente(特文特大学);University of Luxembourg(卢森堡大学)
Northwest University(西北大学);University of Technology Sydney(悉尼科技大学);University of Oxford(牛津大学);South China University of Technology(华南理工大学);Sun Yat-sen University(中山大学);PengCheng Laboratory(鹏城实验室);RMIT University(皇家墨尔本理工大学)
Going Beyond U-Net: Assessing Vision Transformers for Semantic Segmentation in Microscopy Image Analysis
Institute of Computer Science, University of Tartu(塔尔图大学计算机科学研究所);Center for Artificial Intelligence, Technical University of Applied Sciences Würzburg-Schweinfurt(维尔茨堡-施韦因富特应用技术大学人工智能中心);STACC
Pedestrian Detection: Domain Generalization, CNNs, Transformers and Beyond
Group 42(G42集团);Inception Institute of Artificial Intelligence(起源人工智能研究院);The Chinese University of Hong Kong(香港中文大学);National Center for Artificial Intelligence(国家人工智能中心)
Beyond Image-Text Matching: Verb Understanding in Multimodal Transformers Using Guided Masking
Faculty of Information Technology, Brno University of Technology(布尔诺理工大学信息技术学院);Kempelen Institute of Intelligent Technologies(肯佩伦智能技术研究所);George Mason University(乔治梅森大学)
Beyond Gaussian Bottlenecks: Topologically Aligned Encoding of Vision-Transformer Feature Spaces
Department of Computer Engineering, Koç University, Istanbul, Turkey(科克大学计算机工程系,伊斯坦布尔,土耳其);Department of Computer Engineering, Hacettepe University, Ankara, Turkey(哈恰塔佩大学计算机工程系,安卡拉,土耳其);KUIS AI Research Center, Istanbul, Turkey(KUIS人工智能研究中心,伊斯坦布尔,土耳其);Department of Electrical and Electronics Engineering, Koç University, Istanbul, Turkey(科克大学电气与电子工程系,伊斯坦布尔,土耳其)
Beyond Scalars: Concept-Based Alignment Analysis in Vision Transformers
Fraunhofer Heinrich-Hertz-Institute(弗劳恩霍夫海因茨·赫兹研究所);Technische Universität Berlin(柏林工业大学);BIFOLD – Berlin Institute for the Foundations of Learning and Data(柏林学习与数据基础研究所(BIFOLD));Carl von Ossietzky Universität Oldenburg(卡尔·冯·奥西茨基奥尔登堡大学)