TopV: Compatible Token Pruning with Inference Time Optimization for Fast and Low-Memory Multimodal Vision Language Model

Cheng Yang, Yang Sui, Jinqi Xiao, Lingyi Huang, Yu Gong, Chendi Li, Jinghua Yan, Yu Bai, Ponnuswamy Sadayappan, Xia Hu, Bo Yuan

Abstract

Vision-Language Models (VLMs) are computationally intensive due to the high volume of visual tokens. Existing pruning methods often rely on noisy heuristics and conflict with modern hardware optimizations like KV caching. We present TopV, a training-free token pruning method that formulates pruning as an optimization problem solved during the initial prefilling stage. By utilizing the Sinkhorn algorithm and a visual-aware cost function, TopV achieves up to a 2.1× speedup and 61% reduction in dynamic memory usage while maintaining or improving model accuracy.

Introduction

Modern VLMs, such as LLaVA and InternVL, process images by converting them into hundreds or thousands of visual tokens. In many architectures, these tokens constitute over 90% of the input sequence, leading to significant bottlenecks in both computation and memory. Previous attempts to mitigate this through token pruning have struggled with two primary issues: the use of raw attention scores as unreliable importance heuristics, and incompatibility with FlashAttention and KV Caching. When tokens are pruned dynamically across layers, the KV cache cannot be efficiently reused, negating the performance benefits of pruning.

The TopV Framework

TopV addresses these challenges by moving away from greedy heuristics toward a mathematically grounded Optimal Transport formulation.

Overview of the TopV pruning mechanism and the visual-aware cost matrix optimization.

Pruning as Optimization

Instead of simple ranking, TopV identifies the optimal mapping between "source" visual tokens and "target" tokens (the outputs of transformer blocks). This is solved efficiently using the Sinkhorn algorithm during the prefilling stage. The importance of a token is determined by its contribution to the target tokens, calculated via a visual-aware cost function incorporating:

  1. Feature Similarity: Semantic relevance to the target.
  2. Relative Spatial Distance: A Gaussian prior reflecting the locality of visual information.
  3. Absolute Central Distance: A center-bias prior acknowledging that critical information typically resides in the image center.

One-and-Done Pruning

To ensure compatibility with KV caching, TopV performs pruning exactly once, typically at the second layer of the model. By fixing the token set early in the prefilling stage, the model can leverage standard inference accelerations throughout the remainder of the generation process. To prevent "visual collapse" and preserve fine-grained details (crucial for OCR), a small subset of pruned tokens is recovered via uniform sampling, maintaining a global structural view.

Experimental Evaluation

TopV was evaluated across diverse benchmarks, including AI2D, MMMU, MMBench, and VideoMME, using LLaVA-v1.5 and InternVL2 architectures.

Key Results

The method demonstrates superior efficiency without compromising performance:

  • Inference Speedup: TopV achieved a 2.1× speedup on InternVL2 and 1.68× on LLaVA models.
  • Memory Efficiency: Dynamic memory usage was reduced by up to 61% for InternVL2.
  • Accuracy Preservation: Unlike heuristic methods, TopV often improved accuracy (e.g., +1.2% on InternVL2) by filtering out redundant visual noise.
  • OCR Performance: In OCRBench, TopV significantly outperformed previous methods (scoring 31 vs. 5.1), proving its ability to retain critical fine-grained information.
GPU memory usage comparison over time, demonstrating the significant reduction in allocated and reserved memory.

Conclusion

TopV provides a robust, training-free solution for accelerating VLMs. By treating pruning as an optimization problem and ensuring hardware compatibility through early, static pruning, it offers a practical path toward deploying large-scale multimodal models on resource-constrained devices. Future work may explore integrating this optimization-based approach directly into the training phase for further distillation gains.

Summary updated

BibTeX
@inproceedings{yang2025topv,
  author = {Cheng Yang and Yang Sui and Jinqi Xiao and Lingyi Huang and Yu Gong and Chendi Li and Jinghua Yan and Yu Bai and Ponnuswamy Sadayappan and Xia Hu and Bo Yuan},
  title = {{TopV: Compatible Token Pruning with Inference Time Optimization for Fast and Low-Memory Multimodal Vision Language Model}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2025},
  doi = {10.1109/cvpr52734.2025.01844},
}
Figure