中文
相关论文

相关论文: A Study on ReLU and Softmax in Transformer

200 篇论文

We explore Multi-Head FFN (MH-FFN) as a replacement of FFN in the Transformer architecture, motivated by the structural similarity between single-head attention and FFN. While multi-head mechanisms enhance expressivity in attention, naively…

机器学习 · 计算机科学 2025-12-09 Minshen Zhang , Xiang Hu , Jianguo Li , Wei Wu , Kewei Tu

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…

机器学习 · 计算机科学 2024-08-28 Songlin Yang , Bailin Wang , Yikang Shen , Rameswar Panda , Yoon Kim

In this paper, we have extended the well-established universal approximator theory to neural networks that use the unbounded ReLU activation function and a nonlinear softmax output layer. We have proved that a sufficiently large neural…

机器学习 · 计算机科学 2020-02-12 Behnam Asadi , Hui Jiang

The original softmax-based attention mechanism (regular attention) in the extremely successful Transformer architecture computes attention between $N$ tokens, each embedded in a $D$-dimensional head, with a time complexity of $O(N^2D)$.…

机器学习 · 计算机科学 2025-10-28 Armin Gerami , Ramani Duraiswami

The key to a Transformer model is the self-attention mechanism, which allows the model to analyze an entire sequence in a computationally efficient manner. Recent work has suggested the possibility that general attention mechanisms used by…

机器学习 · 计算机科学 2020-01-01 Thomas Dowdell , Hongyu Zhang

Incremental processing allows interactive systems to respond based on partial inputs, which is a desirable property e.g. in dialogue agents. The currently popular Transformer architecture inherently processes sequences as a whole,…

计算与语言 · 计算机科学 2024-05-03 Patrick Kahardipraja , Brielen Madureira , David Schlangen

Various linear complexity models, such as Linear Transformer (LinFormer), State Space Model (SSM), and Linear RNN (LinRNN), have been proposed to replace the conventional softmax attention in Transformer structures. However, the optimal…

机器学习 · 计算机科学 2024-11-19 Yuhong Chou , Man Yao , Kexin Wang , Yuqi Pan , Ruijie Zhu , Yiran Zhong , Yu Qiao , Jibin Wu , Bo Xu , Guoqi Li

Transformers are state-of-the-art models for a variety of sequence modeling tasks. At their core is an attention function which models pairwise interactions between the inputs at every timestep. While attention is powerful, it does not…

计算与语言 · 计算机科学 2021-03-23 Hao Peng , Nikolaos Pappas , Dani Yogatama , Roy Schwartz , Noah A. Smith , Lingpeng Kong

Self Normalizing Neural Networks(SNN) proposed on Feed Forward Neural Networks(FNN) outperform regular FNN architectures in various machine learning tasks. Particularly in the domain of Computer Vision, the activation function Scaled…

计算与语言 · 计算机科学 2019-05-07 Avinash Madasu , Vijjini Anvesh Rao

Recently, it has been argued that encoder-decoder models can be made more interpretable by replacing the softmax function in the attention with its sparse variants. In this work, we introduce a novel, simple method for achieving sparsity in…

计算与语言 · 计算机科学 2021-10-07 Biao Zhang , Ivan Titov , Rico Sennrich

Most of convolutional neural networks share the same characteristic: each convolutional layer is followed by a nonlinear activation layer where Rectified Linear Unit (ReLU) is the most widely used. In this paper, we argue that the designed…

计算机视觉与模式识别 · 计算机科学 2018-09-03 Gangming Zhao , Zhaoxiang Zhang , He Guan , Peng Tang , Jingdong Wang

Decision Transformer-based decision-making agents have shown the ability to generalize across multiple tasks. However, their performance relies on massive data and computation. We argue that this inefficiency stems from the forgetting…

机器学习 · 计算机科学 2024-05-30 Jikun Kang , Romain Laroche , Xingdi Yuan , Adam Trischler , Xue Liu , Jie Fu

This paper questions whether the strong performance of softmax attention in transformers stems from producing a probability distribution over inputs. Instead, we argue that softmax's effectiveness lies in its implicit regularization of the…

机器学习 · 计算机科学 2026-03-16 Hemanth Saratchandran , Jianqiao Zheng , Yiping Ji , Wenbo Zhang , Simon Lucey

Recently, numerous efficient Transformers have been proposed to reduce the quadratic computational complexity of standard Transformers caused by the Softmax attention. However, most of them simply swap Softmax with an efficient attention…

计算与语言 · 计算机科学 2022-07-29 Zexiang Liu , Dong Li , Kaiyue Lu , Zhen Qin , Weixuan Sun , Jiacheng Xu , Yiran Zhong

Transformer-based models have demonstrated remarkable in-context learning capabilities, prompting extensive research into its underlying mechanisms. Recent studies have suggested that Transformers can implement first-order optimization…

机器学习 · 计算机科学 2024-03-06 Angeliki Giannou , Liu Yang , Tianhao Wang , Dimitris Papailiopoulos , Jason D. Lee

Modern autoregressive models rely on attention, yet the Softmax full attention in Transformers scales quadratically with sequence length. Sliding Window Attention (SWA) achieves linear-time encoding/decoding by constraining the attention…

机器学习 · 计算机科学 2026-01-08 Jiaxu Liu , Yuhe Bai , Xiangyu Yin , Christos-Savvas Bouganis

This work presents an analysis of the effectiveness of using standard shallow feed-forward networks to mimic the behavior of the attention mechanism in the original Transformer model, a state-of-the-art architecture for sequence-to-sequence…

计算与语言 · 计算机科学 2024-02-06 Vukasin Bozic , Danilo Dordevic , Daniele Coppola , Joseph Thommes , Sidak Pal Singh

The self-attention mechanism distinguishes transformer-based large language models (LLMs) apart from convolutional and recurrent neural networks. Despite the performance improvement, achieving real-time LLM inference on silicon remains…

硬件体系结构 · 计算机科学 2024-11-18 Shiwei Liu , Guanchen Tao , Yifei Zou , Derek Chow , Zichen Fan , Kauna Lei , Bangfei Pan , Dennis Sylvester , Gregory Kielian , Mehdi Saligane

The feed-forward networks (FFNs) in transformers are recognized as a group of key-value neural memories to restore abstract high-level knowledge. In this work, we conduct an empirical ablation study on updating keys (the 1st layer in the…

计算与语言 · 计算机科学 2024-02-20 Zihan Qiu , Zeyu Huang , Youcheng Huang , Jie Fu

Federated learning is an emerging research paradigm enabling collaborative training of machine learning models among different organizations while keeping data private at each institution. Despite recent progress, there remain fundamental…

机器学习 · 计算机科学 2022-04-15 Liangqiong Qu , Yuyin Zhou , Paul Pu Liang , Yingda Xia , Feifei Wang , Ehsan Adeli , Li Fei-Fei , Daniel Rubin