LayerNorm and attention Softmax are critical operations in Transformers. However, they cannot be efficiently mapped to General Matrix Multiplication (GEMM) computations on hardware. Therefore, modern hardware accelerator designs, such as NPUs on ASIC/FPGA, consume a large amount of hardware resources or chip area to implement their specific arithmetic units. Building on previous work about LayerNorm, Softmax, and their alternatives, we introduce Learnable Normalization States (LENS), a framework that reformulates LayerNorm as tiny MLPs by abstracting a common structure from related methods and extends this method to Softmax, which moves more of the computation in Transformers to GEMM as a hardware-friendly architecture. We evaluate LENS on image classification with Vision Transformers (ViT) and autoregressive language modeling with Pythia models, including generalization tests on WikiText and LAMBADA. Across these tasks, LENS matches or exceeds baseline performance in several vision settings and retains most of the baseline performance in the remaining vision and language experiments. These findings may suggest that hand-designed normalization and attention functions are not the only choice as alternatives to LayerNorm and Softmax. LENS also provides a basis for exploring Transformer architectures for resource-limited accelerators.
Easy attention: A simple attention mechanism for temporal predictions with transformers
KTH Royal Institute of Technology(皇家理工学院);Instituto Universitario de Matemática Pura y Aplicada, Universitat Politècnica de València(瓦伦西亚理工大学数学与应用数学研究院);Technical University Munich(慕尼黑技术大学);University of Michigan(密歇根大学)
STILL: Selecting Tokens for Intra-Layer Hybrid Attention to Linearize LLMs
SMULL Group, Harbin Institute of Technology, Shenzhen(SMULL小组,哈尔滨工业大学,深圳);Pengcheng Laboratory(Pengcheng实验室);UQMM Lab, University of Queensland(UQMM实验室,昆士兰大学);Huawei Technologies Co., Ltd.(华为技术有限公司)
LUNA: Linear Universal Neural Attention with Generalization Guarantees
Department of Computer Science, Vanderbilt University(维斯尼尔大学计算机科学系);Department of Electrical & Computer Engineering, Vanderbilt University(维斯尼尔大学电气与计算机工程系);Department of Computer Science, Duke University(杜克大学计算机科学系);Department of Biostatistics & Bioinformatics, Duke University(杜克大学生物统计与生物信息学系)
PolicyAttention: Softmax Attention Implements Policy Mirror Descent for Closed-Loop Control
Quantitative Research Society(量化研究学会);Nanyang Technological University(南洋理工大学);The Chinese University of Hong Kong, Shenzhen(香港中文大学(深圳));The University of Hong Kong(香港大学)
From Attention Sensitivity to Layer Role: Revisiting Mixed-Precision Quantization of Transformers
Sharif University of Technology(谢里夫理工大学);GISMA University of Applied Sciences(GISMA应用科学大学);BRAINS, Brandenburg Research Center for Applied Intelligent Systems(勃兰登堡应用智能系统研究中心);Max Planck Institute for Security and Privacy(马克斯·普朗克安全与隐私研究所);Computer Vision Center (CVC)(计算机视觉中心);University of Cambridge(剑桥大学)
ARM: Attention with Routed-Memory for Learnable Sparse Control
University of Toronto(多伦多大学);Vector Institute(向量研究所);Université de Montréal(蒙特利尔大学);Mila - Quebec AI Institute(Mila-魁北克人工智能研究所);RIKEN AIP(日本理化学研究所革新智能统合研究中心);Western University(韦仕敦大学)
RepQ-ViT: Scale Reparameterization for Post-Training Quantization of Vision Transformers
Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);School of Artificial Intelligence, University of Chinese Academy of Sciences(中国科学院大学人工智能学院)