English
Related papers

Related papers: FlashNorm: Fast Normalization for Transformers

200 papers

The computational and memory demands of vanilla attention scale quadratically with the sequence length $N$, posing significant challenges for processing long sequences in Transformer models. FlashAttention alleviates these challenges by…

Machine Learning · Computer Science 2025-03-04 Guoxia Wang , Jinle Zeng , Xiyuan Xiao , Siming Wu , Jiabin Yang , Lujing Zheng , Zeyu Chen , Jiang Bian , Dianhai Yu , Haifeng Wang

Distributed inference of large language models (LLMs) using tensor parallelism can introduce communication overheads of $20$% even over GPUs connected via NVLink, a high-speed GPU interconnect. Several techniques have been proposed to…

Distributed, Parallel, and Cluster Computing · Computer Science 2026-05-04 Raja Gond , Nipun Kwatra , Ramachandran Ramjee

The standard normalization method for neural network (NN) models used in Natural Language Processing (NLP) is layer normalization (LN). This is different than batch normalization (BN), which is widely-adopted in Computer Vision. The…

Computation and Language · Computer Science 2021-04-21 Sheng Shen , Zhewei Yao , Amir Gholami , Michael W. Mahoney , Kurt Keutzer

During pretraining, the Pre-LayerNorm transformer suffers from a gradient magnitude mismatch: gradients at early layers are much larger than at later layers. These issues can be alleviated by our proposed NormFormer architecture, which adds…

Computation and Language · Computer Science 2021-11-02 Sam Shleifer , Jason Weston , Myle Ott

The size and compute characteristics of modern large language models have led to an increased interest in developing specialized kernels tailored for particular training and inference workloads. Existing kernels primarily optimize for…

Machine Learning · Computer Science 2025-12-05 Aniruddha Nrusimha , William Brandon , Mayank Mishra , Yikang Shen , Rameswar Panda , Jonathan Ragan-Kelley , Yoon Kim

R is one of the most popular programming languages for statistics and machine learning, but the R framework is relatively slow and unable to scale to large datasets. The general approach for speeding up an implementation in R is to…

Distributed, Parallel, and Cluster Computing · Computer Science 2017-05-22 Da Zheng , Disa Mhembere , Joshua T. Vogelstein , Carey E. Priebe , Randal Burns

Powerful generative artificial intelligence from large language models (LLMs) harnesses extensive computational resources for inference. In this work, we investigate the transformer architecture, a key component of these models, under the…

LayerNorm is pivotal in Vision Transformers (ViTs), yet its fine-tuning dynamics under data scarcity and domain shifts remain underexplored. This paper shows that shifts in LayerNorm parameters after fine-tuning (LayerNorm shifts) are…

Computer Vision and Pattern Recognition · Computer Science 2025-08-12 Zhaorui Tan , Tan Pan , Kaizhu Huang , Weimiao Yu , Kai Yao , Chen Jiang , Qiufeng Wang , Anh Nguyen , Xin Guo , Yuan Cheng , Xi Yang

Per-example gradient norms are a vital ingredient for estimating gradient noise scale (GNS) with minimal variance. Observing the tensor contractions required to compute them, we propose a method with minimal FLOPs in 3D or greater tensor…

Machine Learning · Computer Science 2024-11-05 Gavia Gray , Aman Tiwari , Shane Bergsma , Joel Hestness

Normalization layers are standard in transformers, but it is not clear whether their sample-dependent computations are necessary throughout both training and inference. This work develops a gated normalization-removal approach for pre-norm…

Machine Learning · Computer Science 2026-05-21 Andrei Kanavalau , Carmen Amo Alonso , Sanjay Lall

This work is motivated by recent developments in Deep Neural Networks, particularly the Transformer architectures underlying applications such as ChatGPT, and the need for performing inference on mobile devices. Focusing on emerging…

Machine Learning · Computer Science 2024-04-23 Wei Niu , Md Musfiqur Rahman Sanim , Zhihao Shu , Jiexiong Guan , Xipeng Shen , Miao Yin , Gagan Agrawal , Bin Ren

Compressing large language models (LLMs) for deployment on commodity GPUs remains challenging: conventional scalar quantization is limited to fixed bit-widths (e.g., 8/4/3-bit), offers only a few discrete compression points, and typically…

Machine Learning · Computer Science 2026-05-07 Ye Qiao , Yian Wang , Zhiheng Chen , Hyoukjun Kwon , Sitao Huang

Efficient large-scale inference of transformer-based large language models (LLMs) remains a fundamental systems challenge, frequently requiring multi-GPU parallelism to meet stringent latency and throughput targets. Conventional tensor…

Distributed, Parallel, and Cluster Computing · Computer Science 2026-02-10 Chong Wang , Nan Du , Tom Gunter , Tao Lei , Kulin Seth , Senyu Tong , Jianyu Wang , Guoli Yin , Xiyou Zhou , Kelvin Zou , Ruoming Pang

We propose Dual PatchNorm: two Layer Normalization layers (LayerNorms), before and after the patch embedding layer in Vision Transformers. We demonstrate that Dual PatchNorm outperforms the result of exhaustive search for alternative…

Computer Vision and Pattern Recognition · Computer Science 2023-05-09 Manoj Kumar , Mostafa Dehghani , Neil Houlsby

Large deep learning models have demonstrated strong ability to solve many tasks across a wide range of applications. Those large models typically require training and inference to be distributed. Tensor parallelism is a common technique…

LayerNorm is a critical component in modern large language models (LLMs) for stabilizing training and ensuring smooth optimization. However, it introduces significant challenges in mechanistic interpretability, outlier feature suppression,…

Machine Learning · Computer Science 2024-11-19 Nandan Kumar Jha , Brandon Reagen

The prefill stage of large language model (LLM) inference is a key computational bottleneck for long-context workloads. At short-to-moderate context lengths (1K--16K tokens), Feed-Forward Networks (FFNs) dominate this cost, accounting for…

Machine Learning · Computer Science 2026-02-03 Aayush Gautam , Mukul Gagrani , Junyoung Park , Mingu Lee , Chiris Lott , Narasimha Reddy

This paper introduces an efficient strategy to transform Large Language Models (LLMs) into Multi-Modal Large Language Models (MLLMs). By conceptualizing this transformation as a domain adaptation process, i.e., transitioning from text…

Computation and Language · Computer Science 2023-12-19 Bingchen Zhao , Haoqin Tu , Chen Wei , Jieru Mei , Cihang Xie

Large language models (LLMs) have demonstrated state-of-the-art performance across various tasks. However, the latency of inference and the large GPU memory consumption of LLMs restrict their deployment performance. Recently, there have…

Machine Learning · Computer Science 2024-02-29 Yi Zhang , Fei Yang , Shuang Peng , Fangyu Wang , Aimin Pan

Transformers with linear attention allow for efficient parallel training but can simultaneously be formulated as an RNN with 2D (matrix-valued) hidden states, thus enjoying linear-time inference complexity. However, linear attention…

Machine Learning · Computer Science 2024-08-28 Songlin Yang , Bailin Wang , Yikang Shen , Rameswar Panda , Yoon Kim