paper-with-me

Papers

Dynamic Spatial Sparsification for Efficient Vision Transformers and Convolutional Neural Networks

2022-07-04 · Yongming Rao, Zuyan Liu, Wenliang Zhao, Jie zhou, Jiwen Lu

In this paper, we present a new approach for model acceleration by exploiting spatial sparsity in visual data. We observe that the final prediction in vision Transformers is only based on a subset of the most informative tokens, which is sufficient for accurate image recognition. Based on this observation, we propose a dynamic token sparsification framework to prune redundant tokens progressively and dynamically based on the input to accelerate vision Transformers. Specifically, we devise a lightweight prediction module to estimate the importance score of each token given the current features. The module is added to different layers to prune redundant tokens hierarchically. While the framework is inspired by our observation of the sparse attention in vision Transformers, we find the idea of adaptive and asymmetric computation can be a general solution for accelerating various architectures. We extend our method to hierarchical models including CNNs and hierarchical vision Transformers as well as more complex dense prediction tasks that require structured feature maps by formulating a more generic dynamic spatial sparsification framework with progressive sparsification and asymmetric computation for different spatial locations. By applying lightweight fast paths to less informative features and using more expressive slow paths to more important locations, we can maintain the structure of feature maps while significantly reducing the overall computations. Extensive experiments demonstrate the effectiveness of our framework on various modern architectures and different visual recognition tasks. Our results clearly demonstrate that dynamic spatial sparsification offers a new and more effective dimension for model acceleration. Code is available at https://github.com/raoyongming/DynamicViT

📄 PDF Abstract BibTeX arXiv:2207.01580

Code (1)

raoyongming/DynamicViT 공식 구현 pytorch

Similar Papers 제목 키워드 기반

DynamicViT: Efficient Vision Transformers with Dynamic Token Sparsification

2021-06-03 · NeurIPS 2021 12 · Yongming Rao, Wenliang Zhao, Benlin Liu, Jiwen Lu 외

Attention is sparse in vision transformers. We observe the final prediction in vision transformers is only based on a subset of most informative tokens, which is sufficient for accurate image recognition. Based on this o…

BlockingEfficient ViTsImage Classification

DeSparsify: Adversarial Attack Against Token Sparsification Mechanisms in Vision Transformers

2024-02-04 · Oryan Yehezkel, Alon Zolfi, Amit Baras, Yuval Elovici 외

Vision transformers have contributed greatly to advancements in the computer vision domain, demonstrating state-of-the-art performance in diverse tasks (e.g., image classification, object detection). However, their high …

Adversarial AttackGPUimage-classificationImage Classification+2

SPOT: Sparsification with Attention Dynamics via Token Relevance in Vision Transformers

2025-11-13 · Oded Schlesinger, Amirhossein Farzam, J. Matias Di Martino, Guillermo Sapiro arxiv

While Vision Transformers (ViT) have demonstrated remarkable performance across diverse tasks, their computational demands are substantial, scaling quadratically with the number of processed tokens. Compact attention rep…

Computational Efficiency

Utilizing dynamic sparsity on pretrained DETR

2025-10-10 · Reza Sedghi, Anand Subramoney, David Kappel arxiv

Efficient inference with transformer-based models remains a challenge, especially in vision tasks like object detection. We analyze the inherent sparsity in the MLP layers of DETR and introduce two methods to exploit it …

Object Detection

Vision Big Bird: Random Sparsification for Full Attention

2023-11-10 · Zhemin Zhang, Xun Gong

Recently, Transformers have shown promising performance in various vision tasks. However, the high costs of global self-attention remain challenging for Transformers, especially for high-resolution vision tasks. Inspired…