Single Trajectory Distillation for Accelerating Image and Video Style Transfer
Sijie Xu, Runqi Wang, Wei Zhu, Dejia Song, Nemo Chen, Xu Tang, Yao Hu
TL;DR
Single Trajectory Distillation (STD) tackles slow diffusion-based image and video stylization by distilling a complete $PF\text{-}ODE$ denoising trajectory starting from a fixed partial-noise state, rather than only aligning the initial step. The method introduces a trajectory bank to reuse teacher trajectories and an asymmetric adversarial loss with DINO-v2 features to enhance style and saturation while suppressing texture noise. Empirical results on image and video stylization show STD surpasses prior acceleration methods in style similarity and aesthetics, with ablations confirming contributions from STD and the asymmetric loss. The approach promises practical speedups for real-world stylization tasks and can extend to other partially-noised editing tasks such as inpainting.
Abstract
Diffusion-based stylization methods typically denoise from a specific partial noise state for image-to-image and video-to-video tasks. This multi-step diffusion process is computationally expensive and hinders real-world application. A promising solution to speed up the process is to obtain few-step consistency models through trajectory distillation. However, current consistency models only force the initial-step alignment between the probability flow ODE (PF-ODE) trajectories of the student and the imperfect teacher models. This training strategy can not ensure the consistency of whole trajectories. To address this issue, we propose single trajectory distillation (STD) starting from a specific partial noise state. We introduce a trajectory bank to store the teacher model's trajectory states, mitigating the time cost during training. Besides, we use an asymmetric adversarial loss to enhance the style and quality of the generated images. Extensive experiments on image and video stylization demonstrate that our method surpasses existing acceleration models in terms of style similarity and aesthetic evaluations. Our code and results will be available on the project page: https://single-trajectory-distillation.github.io.
