paper-with-me

홈 › Papers

GQA: Training Generalized Multi-Query Transformer Models from Multi-Head Checkpoints

2023-05-22 · Joshua Ainslie, James Lee-Thorp, Michiel de Jong, Yury Zemlyanskiy, Federico Lebrón, Sumit Sanghai

Multi-query attention (MQA), which only uses a single key-value head, drastically speeds up decoder inference. However, MQA can lead to quality degradation, and moreover it may not be desirable to train a separate model just for faster inference. We (1) propose a recipe for uptraining existing multi-head language model checkpoints into models with MQA using 5% of original pre-training compute, and (2) introduce grouped-query attention (GQA), a generalization of multi-query attention which uses an intermediate (more than one, less than number of query heads) number of key-value heads. We show that uptrained GQA achieves quality close to multi-head attention with comparable speed to MQA.

📄 PDF Abstract BibTeX arXiv:2305.13245

Code (4)

alansun17904/circuit-stability pytorch
facebookresearch/llama/blob/6c7fe276574e78057f917549435a2554000a876d/llama/model.py pytorch
fkodom/grouped-query-attention-pytorch pytorch
knotgrass/attention/blob/main/attn/attention.py pytorch

Tasks

DecoderLanguage ModelingLanguage Modelling

Methods 이 논문이 사용한 방법론

Attention 설명 없음
Dense Connections Dense Connections, or Fully Connected Connections, are a type of layer in a deep neural network that use a linear operation where every input is connected to every output…
Feedforward Network A Feedforward Network, or a Multilayer Perceptron (MLP), is a neural network with solely densely connected layers. This is the classic neural network architecture of the…
Grouped-query attention 설명 없음
Multi-Query Attention 설명 없음
Softmax The Softmax output function transforms a previous layer's output into a vector of probabilities. It is commonly used for multiclass classification. Given an input vector $x$…
Linear Layer A Linear Layer is a projection $\mathbf{XW + b}$.
SPEED The monocular depth estimation (MDE) is the task of estimating depth from a single frame. This information is an essential knowledge in many computer vision tasks such as scene…

Similar Papers 제목 키워드 기반

UP-DETR: Unsupervised Pre-training for Object Detection with Transformers

2020-11-18 · CVPR 2021 1 · Zhigang Dai, Bolun Cai, Yugeng Lin, Junying Chen

DEtection TRansformer (DETR) for object detection reaches competitive performance compared with Faster R-CNN via a transformer encoder-decoder architecture. However, trained with scratch transformers, DETR needs large-sc…

DecoderMulti-Task Learningobject-detectionObject Detection+2

Generalized Context in Cross Attention for Transfer Learning of Disjoint Tabular Data

2026-08-28 · Kazi F. Akhter, Ibna Kowsar, Manar D. Samad arxiv

Unlike images and text, applying transfer learning to tabular data is challenging due to heterogeneity in feature types, structures, and semantics across disparate domains. Existing methods assume shared features across …

Transfer Learning

Transformer with Fourier Integral Attentions

2022-06-01 · Tan Nguyen, Minh Pham, Tam Nguyen, Khai Nguyen 외

Multi-head attention empowers the recent success of transformers, the state-of-the-art models that have achieved remarkable success in sequence modeling and beyond. These attention mechanisms compute the pairwise dot pro…

image-classificationImage ClassificationLanguage ModelingLanguage Modelling+1

Textual Query-Driven Mask Transformer for Domain Generalized Segmentation

2024-07-12 · Byeonghyun Pak, Byeongju Woo, Sunghwan Kim, Dae-hwan Kim 외

In this paper, we introduce a method to tackle Domain Generalized Semantic Segmentation (DGSS) by utilizing domain-invariant semantic knowledge from text embeddings of vision-language models. We employ the text embedding…

Domain GeneralizationObjectSemantic Segmentation

Groupwise Query Specialization and Quality-Aware Multi-Assignment for Transformer-based Visual Relationship Detection

2024-03-26 · CVPR 2024 1 · Jongha Kim, Jihwan Park, Jinyoung Park, Jinyoung Kim 외

Visual Relationship Detection (VRD) has seen significant advancements with Transformer-based architectures recently. However, we identify two key limitations in a conventional label assignment for training Transformer-ba…

RelationRelationship DetectionScene Graph GenerationVisual Relationship Detection