English
Related papers

Related papers: cosFormer: Rethinking Softmax in Attention

200 papers

Following up on the linear transformer part of the article from Katharopoulos et al., that takes this idea from Shen et al., the trick that produces a linear complexity for the attention mechanism is re-used and extended to a second-order…

Machine Learning · Computer Science 2020-10-29 Jean Mercat

Recently, conformer-based end-to-end automatic speech recognition, which outperforms recurrent neural network based ones, has received much attention. Although the parallel computing of conformer is more efficient than recurrent neural…

Sound · Computer Science 2021-07-26 Shengqiang Li , Menglong Xu , Xiao-Lei Zhang

Transformers have enabled impressive improvements in deep learning. They often outperform recurrent and convolutional models in many tasks while taking advantage of parallel processing. Recently, we proposed the SepFormer, which obtains…

Audio and Speech Processing · Electrical Eng. & Systems 2023-05-30 Cem Subakan , Mirco Ravanelli , Samuele Cornell , Francois Grondin , Mirko Bronzi

Transformer-based language models have found many diverse applications requiring them to process sequences of increasing length. For these applications, the causal self-attention -- which is the only component scaling quadratically w.r.t.…

Machine Learning · Computer Science 2023-06-05 Matteo Pagliardini , Daniele Paliotta , Martin Jaggi , François Fleuret

At the core of the popular Transformer architecture is the self-attention mechanism, which dynamically assigns softmax weights to each input token so that the model can focus on the most salient information. However, the softmax structure…

Machine Learning · Computer Science 2025-05-27 Fanqi Yan , Huy Nguyen , Pedram Akbarian , Nhat Ho , Alessandro Rinaldo

While the Transformer architecture dominates many fields, its quadratic self-attention complexity hinders its use in large-scale applications. Linear attention offers an efficient alternative, but its direct application often degrades…

Computer Vision and Pattern Recognition · Computer Science 2026-01-15 Kewei Zhang , Ye Huang , Yufan Deng , Jincheng Yu , Junsong Chen , Huan Ling , Enze Xie , Daquan Zhou

Large language models rely on attention mechanisms with a softmax activation. Yet the dominance of softmax over alternatives (e.g., component-wise or linear) remains poorly understood, and many theoretical works have focused on the…

Machine Learning · Computer Science 2026-02-27 O. Duranthon , P. Marion , C. Boyer , B. Loureiro , L. Zdeborová

The attention mechanism in Transformers is an important primitive for accurate and scalable sequence modeling. Its quadratic-compute and linear-memory complexity however remain significant bottlenecks. Linear attention and state-space…

Machine Learning · Computer Science 2026-03-03 Han Guo , Songlin Yang , Tarushii Goel , Eric P. Xing , Tri Dao , Yoon Kim

Transformers have greatly advanced the state-of-the-art in Natural Language Processing (NLP) in recent years, but present very large computation and storage requirements. We observe that the design process of Transformers (pre-train a…

Computation and Language · Computer Science 2022-06-13 Amrit Nagarajan , Sanchari Sen , Jacob R. Stevens , Anand Raghunathan

A core limitation of standard softmax attention is that it does not provide an independently interpretable measure of query--key relevance: attention scores are unbounded, while attention weights are defined only relative to competing keys.…

Machine Learning · Computer Science 2026-05-08 Ken M. Nakanishi

SqueezeFormer has recently shown impressive performance in automatic speech recognition (ASR). However, its inference speed suffers from the quadratic complexity of softmax-attention (SA). In addition, limited by the large convolution…

Audio and Speech Processing · Electrical Eng. & Systems 2023-03-16 Yuguang Yang , Yu Pan , Jingjing Yin , Jiangyu Han , Lei Ma , Heng Lu

Transformer models have been successful in various sequence processing tasks, but the self-attention mechanism's computational cost limits its practicality for long sequences. Although there are existing attention variants that improve…

Machine Learning · Computer Science 2024-04-19 Zicheng Liu , Li Wang , Siyuan Li , Zedong Wang , Haitao Lin , Stan Z. Li

While transformers have shown great potential on video recognition with their strong capability of capturing long-range dependencies, they often suffer high computational costs induced by the self-attention to the huge number of 3D tokens.…

Computer Vision and Pattern Recognition · Computer Science 2022-11-23 Yuxuan Liang , Pan Zhou , Roger Zimmermann , Shuicheng Yan

Recent works show we can linearize large language models (LLMs) -- swapping the quadratic attentions of popular Transformer-based LLMs with subquadratic analogs, such as linear attention -- avoiding the expensive pretraining costs. However,…

Machine Learning · Computer Science 2025-03-07 Michael Zhang , Simran Arora , Rahul Chalamala , Alan Wu , Benjamin Spector , Aaryan Singhal , Krithik Ramesh , Christopher Ré

With the rising popularity of Transformer-based large language models (LLMs), reducing their high inference costs has become a significant research focus. One effective approach is to compress the long input contexts. Existing methods…

Computation and Language · Computer Science 2024-11-06 Xiangfeng Wang , Zaiyi Chen , Zheyong Xie , Tong Xu , Yongyi He , Enhong Chen

Transformers have recently revolutionized many domains in modern machine learning and one salient discovery is their remarkable in-context learning capability, where models can solve an unseen task by utilizing task-specific prompts without…

Machine Learning · Computer Science 2023-10-10 Yu Huang , Yuan Cheng , Yingbin Liang

In pursuit of faster computation, Efficient Transformers demonstrate an impressive variety of approaches -- models attaining sub-quadratic attention complexity can utilize a notion of sparsity or a low-rank approximation of inputs to reduce…

Machine Learning · Computer Science 2022-11-09 Uladzislau Yorsh , Alexander Kovalenko

As one of the most popular neural network modules, 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. The effectiveness of the…

Machine Learning · Computer Science 2023-10-30 Shen Yuan , Hongteng Xu

The softmax-based loss functions and its variants (e.g., cosface, sphereface, and arcface) significantly improve the face recognition performance in wild unconstrained scenes. A common practice of these algorithms is to perform…

Computer Vision and Pattern Recognition · Computer Science 2022-08-25 Hongwei Xu , Suncheng Xiang , Dahong Qian

Transformer is the backbone of modern NLP models. In this paper, we propose RealFormer, a simple and generic technique to create Residual Attention Layer Transformer networks that significantly outperform the canonical Transformer and its…

Machine Learning · Computer Science 2021-09-14 Ruining He , Anirudh Ravula , Bhargav Kanagal , Joshua Ainslie