Saved in:
Bibliographic Details
Main Authors: Zhang, Evelyn, Xiao, Bang, Tang, Jiayi, Ma, Qianli, Zou, Chang, Ning, Xuefei, Hu, Xuming, Zhang, Linfeng
Format: Preprint
Published: 2024
Subjects:
Online Access:https://arxiv.org/abs/2501.00375
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866916546993979392
author Zhang, Evelyn
Xiao, Bang
Tang, Jiayi
Ma, Qianli
Zou, Chang
Ning, Xuefei
Hu, Xuming
Zhang, Linfeng
author_facet Zhang, Evelyn
Xiao, Bang
Tang, Jiayi
Ma, Qianli
Zou, Chang
Ning, Xuefei
Hu, Xuming
Zhang, Linfeng
contents Stable Diffusion has achieved remarkable success in the field of text-to-image generation, with its powerful generative capabilities and diverse generation results making a lasting impact. However, its iterative denoising introduces high computational costs and slows generation speed, limiting broader adoption. The community has made numerous efforts to reduce this computational burden, with methods like feature caching attracting attention due to their effectiveness and simplicity. Nonetheless, simply reusing features computed at previous timesteps causes the features across adjacent timesteps to become similar, reducing the dynamics of features over time and ultimately compromising the quality of generated images. In this paper, we introduce a dynamics-aware token pruning (DaTo) approach that addresses the limitations of feature caching. DaTo selectively prunes tokens with lower dynamics, allowing only high-dynamic tokens to participate in self-attention layers, thereby extending feature dynamics across timesteps. DaTo combines feature caching with token pruning in a training-free manner, achieving both temporal and token-wise information reuse. Applied to Stable Diffusion on the ImageNet, our approach delivered a 9$\times$ speedup while reducing FID by 0.33, indicating enhanced image quality. On the COCO-30k, we observed a 7$\times$ acceleration coupled with a notable FID reduction of 2.17.
format Preprint
id arxiv_https___arxiv_org_abs_2501_00375
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Token Pruning for Caching Better: 9 Times Acceleration on Stable Diffusion for Free
Zhang, Evelyn
Xiao, Bang
Tang, Jiayi
Ma, Qianli
Zou, Chang
Ning, Xuefei
Hu, Xuming
Zhang, Linfeng
Computer Vision and Pattern Recognition
Machine Learning
Stable Diffusion has achieved remarkable success in the field of text-to-image generation, with its powerful generative capabilities and diverse generation results making a lasting impact. However, its iterative denoising introduces high computational costs and slows generation speed, limiting broader adoption. The community has made numerous efforts to reduce this computational burden, with methods like feature caching attracting attention due to their effectiveness and simplicity. Nonetheless, simply reusing features computed at previous timesteps causes the features across adjacent timesteps to become similar, reducing the dynamics of features over time and ultimately compromising the quality of generated images. In this paper, we introduce a dynamics-aware token pruning (DaTo) approach that addresses the limitations of feature caching. DaTo selectively prunes tokens with lower dynamics, allowing only high-dynamic tokens to participate in self-attention layers, thereby extending feature dynamics across timesteps. DaTo combines feature caching with token pruning in a training-free manner, achieving both temporal and token-wise information reuse. Applied to Stable Diffusion on the ImageNet, our approach delivered a 9$\times$ speedup while reducing FID by 0.33, indicating enhanced image quality. On the COCO-30k, we observed a 7$\times$ acceleration coupled with a notable FID reduction of 2.17.
title Token Pruning for Caching Better: 9 Times Acceleration on Stable Diffusion for Free
topic Computer Vision and Pattern Recognition
Machine Learning
url https://arxiv.org/abs/2501.00375