paper-with-me

Papers

Token Pooling in Vision Transformers

2021-10-08 · Dmitrii Marin, Jen-Hao Rick Chang, Anurag Ranjan, Anish Prabhu, Mohammad Rastegari, Oncel Tuzel

Despite the recent success in many applications, the high computational requirements of vision transformers limit their use in resource-constrained settings. While many existing methods improve the quadratic complexity of attention, in most vision transformers, self-attention is not the major computation bottleneck, e.g., more than 80% of the computation is spent on fully-connected layers. To improve the computational complexity of all layers, we propose a novel token downsampling method, called Token Pooling, efficiently exploiting redundancies in the images and intermediate token representations. We show that, under mild assumptions, softmax-attention acts as a high-dimensional low-pass (smoothing) filter. Thus, its output contains redundancy that can be pruned to achieve a better trade-off between the computational cost and accuracy. Our new technique accurately approximates a set of tokens by minimizing the reconstruction error caused by downsampling. We solve this optimization problem via cost-efficient clustering. We rigorously analyze and compare to prior downsampling methods. Our experiments show that Token Pooling significantly improves the cost-accuracy trade-off over the state-of-the-art downsampling. Token Pooling is a simple and effective operator that can benefit many architectures. Applied to DeiT, it achieves the same ImageNet top-1 accuracy using 42% fewer computations.

📄 PDF Abstract BibTeX arXiv:2110.03860

Code (0)

등록된 구현이 없습니다.

Methods 이 논문이 사용한 방법론

Attention 설명 없음
Linear Layer A Linear Layer is a projection $\mathbf{XW + b}$.
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$…
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…
Multi-Head Attention 설명 없음
Dropout Dropout is a regularization technique for neural networks that drops a unit (along with connections) at training time with a specified probability $p$ (a common value is…
Attention Dropout Attention Dropout is a type of dropout used in attention-based architectures, where elements are randomly dropped out of the…
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…

Similar Papers 제목 키워드 기반

PPT: Token Pruning and Pooling for Efficient Vision Transformers

2023-10-03 · Xinjian Wu, Fanhu Zeng, Xiudong Wang, Xinghao Chen

Vision Transformers (ViTs) have emerged as powerful models in the field of computer vision, delivering superior performance across various vision tasks. However, the high computational complexity poses a significant barr…

Efficient ViTs

Maximizing the Position Embedding for Vision Transformers with Global Average Pooling

2025-02-05 · Wonjun Lee, Bumsub Ham, Suhyun Kim

In vision transformers, position embedding (PE) plays a crucial role in capturing the order of tokens. However, in vision transformer structures, there is a limitation in the expressiveness of PE due to the structure whe…

Position

Attribute Surrogates Learning and Spectral Tokens Pooling in Transformers for Few-shot Learning

2022-03-17 · CVPR 2022 1 · Yangji He, Weihan Liang, Dongyang Zhao, Hong-Yu Zhou 외

This paper presents new hierarchically cascaded transformers that can improve data efficiency through attribute surrogates learning and spectral tokens pooling. Vision transformers have recently been thought of as a prom…

AttributeFew-Shot Image ClassificationFew-Shot LearningSelf-Supervised Learning

PSViT: Better Vision Transformer via Token Pooling and Attention Sharing

2021-08-07 · BoYu Chen, Peixia Li, Baopu Li, Chuming Li 외

In this paper, we observe two levels of redundancies when applying vision transformers (ViT) for image recognition. First, fixing the number of tokens through the whole network produces redundant features at the spatial …

Efficient Transformers with Dynamic Token Pooling

2022-11-17 · Piotr Nawrot, Jan Chorowski, Adrian Łańcucki, Edoardo M. Ponti

Transformers achieve unrivalled performance in modelling language, but remain inefficient in terms of memory and time complexity. A possible remedy is to reduce the sequence length in the intermediate layers by pooling f…