Joint Token Pruning and Squeezing Towards More Aggressive Compression of Vision Transformers

Siyuan Wei, Tianzhu Ye, Shen Zhang, Yao Tang, Jiajun Liang
2/14/2026

No official code found. Best implementation: megvii-research/TPS-CVPR2023 (48 stars, Apache-2.0, last commit 2023-08-07).

Abstract

Although vision transformers (ViTs) have shown promising results in various computer vision tasks recently, their high computational cost limits their practical applications. Previous approaches that prune redundant tokens have demonstrated a good trade-off between performance and computation costs. Nevertheless, errors caused by pruning strategies can lead to significant information loss. Our quantitative experiments reveal that the impact of pruned tokens on performance should be noticeable. To address this issue, we propose a novel joint Token Pruning & Squeezing module (TPS) for compressing vision transformers with higher efficiency. Firstly, TPS adopts pruning to get the reserved and pruned subsets. Secondly, TPS squeezes the information of pruned tokens into partial reserved tokens via the unidirectional nearest-neighbor matching and similarity-based fusing steps. Compared to state-of-the-art methods, our approach outperforms them under all token pruning intensities. Especially while shrinking DeiT-tiny&small computational budgets to 35%, it improves the accuracy by 1%-6% compared with baselines on ImageNet classification. The proposed method can accelerate the throughput of DeiT-small beyond DeiT-tiny, while its accuracy surpasses DeiT-tiny by 4.78%. Experiments on various transformers demonstrate the effectiveness of our method, while analysis experiments prove our higher robustness to the errors of the token pruning policy. Code is available at https://github.com/megvii-research/TPS-CVPR2023.

View on arXivView PDF

Code Implementations(1)

Apache-2.0
481Shell, PythonMar 16, 20233 years agoApache-2.0

Similar Papers

Cite this paper

@article{wei2026joint,
  title  = {Joint Token Pruning and Squeezing Towards More Aggressive Compression of Vision Transformers},
  author = {Siyuan Wei and Tianzhu Ye and Shen Zhang and Yao Tang and Jiajun Liang},
  year   = {2026},
  eprint = {2304.10716},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/pdf/2304.10716},
  journal = {CVPR 2023 2023}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2304.10716.svg)](https://codeofpaper.com/paper/2304.10716)

Discussion