Block-based Symmetric Pruning and Fusion for Efficient Vision Transformers

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Hsieh, Yi-Kuan, Hsieh, Jun-Wei, Li, Xin, Chang, Yu-Ming, Tseng, Yu-Chee
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866911060411285504
author Hsieh, Yi-Kuan
Hsieh, Jun-Wei
Li, Xin
Chang, Yu-Ming
Tseng, Yu-Chee
author_facet Hsieh, Yi-Kuan
Hsieh, Jun-Wei
Li, Xin
Chang, Yu-Ming
Tseng, Yu-Chee
contents Vision Transformer (ViT) has achieved impressive results across various vision tasks, yet its high computational cost limits practical applications. Recent methods have aimed to reduce ViT's $O(n^2)$ complexity by pruning unimportant tokens. However, these techniques often sacrifice accuracy by independently pruning query (Q) and key (K) tokens, leading to performance degradation due to overlooked token interactions. To address this limitation, we introduce a novel {\bf Block-based Symmetric Pruning and Fusion} for efficient ViT (BSPF-ViT) that optimizes the pruning of Q/K tokens jointly. Unlike previous methods that consider only a single direction, our approach evaluates each token and its neighbors to decide which tokens to retain by taking token interaction into account. The retained tokens are compressed through a similarity fusion step, preserving key information while reducing computational costs. The shared weights of Q/K tokens create a symmetric attention matrix, allowing pruning only the upper triangular part for speed up. BSPF-ViT consistently outperforms state-of-the-art ViT methods at all pruning levels, increasing ImageNet classification accuracy by 1.3% on DeiT-T and 2.0% on DeiT-S, while reducing computational overhead by 50%. It achieves 40% speedup with improved accuracy across various ViTs.
format Preprint
id arxiv_https___arxiv_org_abs_2507_12125
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Block-based Symmetric Pruning and Fusion for Efficient Vision Transformers
Hsieh, Yi-Kuan
Hsieh, Jun-Wei
Li, Xin
Chang, Yu-Ming
Tseng, Yu-Chee
Computer Vision and Pattern Recognition
Vision Transformer (ViT) has achieved impressive results across various vision tasks, yet its high computational cost limits practical applications. Recent methods have aimed to reduce ViT's $O(n^2)$ complexity by pruning unimportant tokens. However, these techniques often sacrifice accuracy by independently pruning query (Q) and key (K) tokens, leading to performance degradation due to overlooked token interactions. To address this limitation, we introduce a novel {\bf Block-based Symmetric Pruning and Fusion} for efficient ViT (BSPF-ViT) that optimizes the pruning of Q/K tokens jointly. Unlike previous methods that consider only a single direction, our approach evaluates each token and its neighbors to decide which tokens to retain by taking token interaction into account. The retained tokens are compressed through a similarity fusion step, preserving key information while reducing computational costs. The shared weights of Q/K tokens create a symmetric attention matrix, allowing pruning only the upper triangular part for speed up. BSPF-ViT consistently outperforms state-of-the-art ViT methods at all pruning levels, increasing ImageNet classification accuracy by 1.3% on DeiT-T and 2.0% on DeiT-S, while reducing computational overhead by 50%. It achieves 40% speedup with improved accuracy across various ViTs.
title Block-based Symmetric Pruning and Fusion for Efficient Vision Transformers
topic Computer Vision and Pattern Recognition
url https://arxiv.org/abs/2507.12125