Token Transforming: A Unified and Training-Free Token Compression Framework for Vision Transformer Acceleration

Fanhu Zeng, Deli Yu, Zhenglun Kong, Hao Tang
6/6/2025
cs.CV
transformer-attention

No confident code implementation found for this paper.

Abstract

Vision transformers have been widely explored in various vision tasks. Due to heavy computational cost, much interest has aroused for compressing vision transformer dynamically in the aspect of tokens.

Show full abstract

Current methods mainly pay attention to token pruning or merging to reduce token numbers, in which tokens are compressed exclusively, causing great information loss and therefore post-training is inevitably required to recover the performance. In this paper, we rethink token reduction and unify the process as an explicit form of token matrix transformation, in which all existing methods are constructing special forms of matrices within the framework. Furthermore, we propose a many-to-many Token Transforming framework that serves as a generalization of all existing methods and reserves the most information, even enabling training-free acceleration. We conduct extensive experiments to validate our framework. Specifically, we reduce 40% FLOPs and accelerate DeiT-S by $\times$1.5 with marginal 0.1% accuracy drop. Furthermore, we extend the method to dense prediction tasks including segmentation, object detection, depth estimation, and language model generation. Results demonstrate that the proposed method consistently achieves substantial improvements, offering a better computation-performance trade-off, impressive budget reduction and inference acceleration.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{zeng2025token,
  title  = {Token Transforming: A Unified and Training-Free Token Compression Framework for Vision Transformer Acceleration},
  author = {Fanhu Zeng and Deli Yu and Zhenglun Kong and Hao Tang},
  year   = {2025},
  eprint = {2506.05709},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2506.05709v1}
}

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/2506.05709.svg)](https://codeofpaper.com/paper/2506.05709)

Discussion