Hardware-efficient Softmax Approximation for Self-Attention Networks

Softmax函数 计算机科学 数据路径 瓶颈 延迟(音频) 变压器 语言模型 现场可编程门阵列 并行计算 人工智能 人工神经网络 计算机硬件 嵌入式系统 电信 物理 量子力学 电压
作者
Nazim Altar Koca,Anh Tuan,Chip-Hong Chang
标识
DOI:10.1109/iscas46773.2023.10181465
摘要

Self-attention networks such as Transformer have become state-of-the-art models for natural language processing (NLP) problems. Softmax function, which serves as a normalizer to produce attention scores, turns out to be a severe throughput and latency bottleneck of a Transformer network. Softmax datapath consists of data-dependent sequential nonlinear exponentiation and division operations, which are not amenable to pipelining and parallelism, nor can they be directly linearized for pretrained models without substantial accuracy drop. In this paper, we proposed a hardware efficient Softmax approximation which can be used as a direct plug-in substitution into pretrained transformer network to accelerate NLP tasks without compromising its accuracy. Experiment results on FPGA implementation show that our design outperforms vanilla Softmax designed using Xilinx IPs with 15x less LUTs, 55x less registers and 23x lower latency at similar clock frequency and less than 1% accuracy drop on main language benchmark tasks. We also propose a pruning method to reduce the input entropy of Softmax for NLP problems with high number of inputs. It was validated on CoLA task to achieve a further 25% reduction of latency.
最长约 10秒,即可获得该文献文件

科研通智能强力驱动
Strongly Powered by AbleSci AI
更新
PDF的下载单位、IP信息已删除 (2025-6-4)

科研通是完全免费的文献互助平台,具备全网最快的应助速度,最高的求助完成率。 对每一个文献求助,科研通都将尽心尽力,给求助人一个满意的交代。
实时播报
香蕉觅云应助张雅露采纳,获得10
1秒前
akakns完成签到,获得积分10
1秒前
da发布了新的文献求助10
1秒前
1秒前
红箭烟雨发布了新的文献求助10
3秒前
4秒前
4秒前
陈仲完成签到,获得积分10
4秒前
5秒前
加快步伐发布了新的文献求助10
7秒前
8秒前
8秒前
Lucas应助粥粥采纳,获得30
8秒前
9秒前
XT完成签到,获得积分10
10秒前
10秒前
寒假工完成签到 ,获得积分10
10秒前
10秒前
11秒前
12秒前
李某发布了新的文献求助10
13秒前
13秒前
所所应助Somebody采纳,获得10
13秒前
13秒前
wzgkeyantong完成签到,获得积分10
14秒前
yxy发布了新的文献求助10
14秒前
14秒前
14秒前
14秒前
15秒前
yyyyyyy发布了新的文献求助10
16秒前
XT发布了新的文献求助10
16秒前
16秒前
17秒前
17秒前
Owen应助aaa采纳,获得10
17秒前
piranha发布了新的文献求助10
18秒前
18秒前
小猪佩奇发布了新的文献求助10
18秒前
张雅露发布了新的文献求助10
19秒前
高分求助中
Picture Books with Same-sex Parented Families: Unintentional Censorship 1000
A new approach to the extrapolation of accelerated life test data 1000
ACSM’s Guidelines for Exercise Testing and Prescription, 12th edition 500
Nucleophilic substitution in azasydnone-modified dinitroanisoles 500
Indomethacinのヒトにおける経皮吸収 400
Phylogenetic study of the order Polydesmida (Myriapoda: Diplopoda) 370
基于可调谐半导体激光吸收光谱技术泄漏气体检测系统的研究 310
热门求助领域 (近24小时)
化学 材料科学 医学 生物 工程类 有机化学 生物化学 物理 内科学 纳米技术 计算机科学 化学工程 复合材料 遗传学 基因 物理化学 催化作用 冶金 细胞生物学 免疫学
热门帖子
关注 科研通微信公众号,转发送积分 3979779
求助须知:如何正确求助?哪些是违规求助? 3523794
关于积分的说明 11218782
捐赠科研通 3261278
什么是DOI,文献DOI怎么找? 1800526
邀请新用户注册赠送积分活动 879143
科研通“疑难数据库(出版商)”最低求助积分说明 807182