NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Plug-and-Play Diffusion Distillation

Yi-Ting Hsiao, Siavash Khodadadeh, Kevin Duarte, Wei-An Lin, Hui Qu, Mingi Kwon, Ratheesh Kalarot

Introduction

Diffusion models have revolutionized image generation, but their high computational cost remains a significant barrier to real-time application. This latency is primarily driven by two factors: the iterative nature of the denoising process and the use of Classifier-Free Guidance (CFG), which requires two forward passes per step. While distillation techniques exist to speed up these models, they typically require retraining the entire network, making them impractical for the vast ecosystem of fine-tuned, domain-specific models like those found in DreamBooth or LoRA.

This paper introduces a "Plug-and-Play" distillation framework that addresses these challenges. By training a lightweight external guide model while keeping the base diffusion model frozen, the researchers achieve a 50% reduction in inference computation with minimal parameter overhead and zero-shot generalization to customized models.

The Challenge of Classifier-Free Guidance

Classifier-Free Guidance is essential for ensuring that generated images align with text prompts. However, it necessitates calculating both a conditioned and an unconditioned output at every step, effectively doubling the Floating Point Operations (FLOPs). Furthermore, existing distillation methods are "style-locked"—if a user wants to speed up a specific watercolor or 3D cartoon model, they would traditionally need to perform a costly distillation process for that specific model. This lack of scalability prevents distillation from being a universal solution for the community's diverse set of fine-tuned models.

Methodology: Lightweight External Guidance

The core innovation of this work is the decoupling of the guidance signal from the base model. The authors propose a framework where the base UNet remains frozen, and a separate, lightweight "guide model" is trained to mimic the CFG output.

CFG Distillation

The guide model takes the guidance scale ($g$), time embeddings, and text embeddings as inputs. It then injects feature maps directly into the decoder of the frozen base UNet. This allows the system to produce a guided result in a single forward pass, eliminating the need for the unconditioned pass and cutting the per-step compute in half.

Architectural Variants

The researchers explored two versions of the guide model:

  1. Full Guide Model: Based on the ControlNet architecture, providing high capacity for complex guidance.
  2. Tiny Guide Model: A highly optimized version that removes encoder blocks and uses a simplified 1D-array input. This version adds only 8.27 million parameters—roughly 1% of the Stable Diffusion v1.5 base (859M parameters).

Progressive Distillation

To further enhance speed, the authors applied progressive distillation. This technique enables the model to maintain high image quality while reducing the total number of sampling steps from the standard 50 down to 8 or 16. By combining CFG distillation with step reduction, the overall generation time is drastically lowered.

Experimental Results

The framework was trained on the LAION dataset (512x512 resolution) and evaluated using the COCO 30k dataset, focusing on FID (Fréchet Inception Distance) and CLIP scores.

Efficiency and Quality

The method successfully halved the inference FLOPs per step. In terms of quality, the 16-step distilled model achieved an FID of 20.74 at a guidance scale of 8, which is nearly identical to the teacher model's performance at 50 steps (FID 21.0). This indicates that the guide model effectively captures the necessary information to maintain image fidelity despite the reduced computation.

Zero-Shot Generalization

The most significant advantage of this approach is its "Plug-and-Play" nature. Because the base model is frozen during the training of the guide model, the resulting guide can be applied to other models derived from the same base. The authors demonstrated this by applying a single guide model to various DreamBooth styles (e.g., "3D Cartoon," "Watercolor," "Realistic") without any additional training. The guide model successfully maintained the unique aesthetics of these fine-tuned models while providing the expected speedup.

Insights into Guidance Dynamics

By analyzing the injected feature maps, the researchers discovered that the guide model's influence is not uniform throughout the generation process. It is most active during the early stages of the diffusion process, where it establishes the global structure of the image. In the later stages, it shifts focus toward high-frequency details, such as edges and texture refinements.

Limitations and Future Directions

While the reduction in FLOPs is significant, the current implementation requires the base UNet and the guide model to run in parallel. This can increase GPU memory usage. Additionally, the "Tiny" guide model shows some performance degradation at very low step counts (e.g., 8 steps) compared to the "Full" version, suggesting a minimum capacity requirement for effective guidance. Future work may focus on tighter architectural integration to overcome hardware-specific sequential bottlenecks and further optimize real-world inference times.

Summary updated

BibTeX
@inproceedings{hsiao2024plug,
  author = {Yi-Ting Hsiao and Siavash Khodadadeh and Kevin Duarte and Wei-An Lin and Hui Qu and Mingi Kwon and Ratheesh Kalarot},
  title = {{Plug-and-Play Diffusion Distillation}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2024},
}
Figure