HyperAIHyperAI

Command Palette

Search for a command to run...

5 months ago

Beyond Attentive Tokens: Incorporating Token Importance and Diversity for Efficient Vision Transformers

Long Sifan ; Zhao Zhen ; Pi Jimin ; Wang Shengsheng ; Wang Jingdong

Beyond Attentive Tokens: Incorporating Token Importance and Diversity
  for Efficient Vision Transformers

Abstract

Vision transformers have achieved significant improvements on various visiontasks but their quadratic interactions between tokens significantly reducecomputational efficiency. Many pruning methods have been proposed to removeredundant tokens for efficient vision transformers recently. However, existingstudies mainly focus on the token importance to preserve local attentive tokensbut completely ignore the global token diversity. In this paper, we emphasizethe cruciality of diverse global semantics and propose an efficient tokendecoupling and merging method that can jointly consider the token importanceand diversity for token pruning. According to the class token attention, wedecouple the attentive and inattentive tokens. In addition to preserving themost discriminative local tokens, we merge similar inattentive tokens and matchhomogeneous attentive tokens to maximize the token diversity. Despite itssimplicity, our method obtains a promising trade-off between model complexityand classification accuracy. On DeiT-S, our method reduces the FLOPs by 35%with only a 0.2% accuracy drop. Notably, benefiting from maintaining the tokendiversity, our method can even improve the accuracy of DeiT-T by 0.1% afterreducing its FLOPs by 40%.

Code Repositories

Benchmarks

BenchmarkMethodologyMetrics
efficient-vits-on-imagenet-1k-with-deit-sBAT (70%)
GFLOPs: 3.0
Top 1 Accuracy: 79.6
efficient-vits-on-imagenet-1k-with-deit-sBAT (60%)
GFLOPs: 2.6
Top 1 Accuracy: 79.3
efficient-vits-on-imagenet-1k-with-deit-sBAT (20%)
GFLOPs: 1.6
Top 1 Accuracy: 76.4
efficient-vits-on-imagenet-1k-with-deit-sBAT (50%)
GFLOPs: 2.3
Top 1 Accuracy: 79.0
efficient-vits-on-imagenet-1k-with-deit-sBAT (30%)
GFLOPs: 1.8
Top 1 Accuracy: 77.8
efficient-vits-on-imagenet-1k-with-deit-sBAT (40%)
GFLOPs: 2.0
Top 1 Accuracy: 78.6
efficient-vits-on-imagenet-1k-with-deit-tBAT
GFLOPs: 0.8
Top 1 Accuracy: 72.3
efficient-vits-on-imagenet-1k-with-lv-vit-sBAT
GFLOPs: 4.7
Top 1 Accuracy: 83.1

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp
Beyond Attentive Tokens: Incorporating Token Importance and Diversity for Efficient Vision Transformers | Papers | HyperAI