TensorX
返回文献探索

Paper · arXiv 2305.15798

On Architectural Compression of Text-to-Image Diffusion Models

Bo-Kyeong Kim, Hyoung-Kyu Song, Thibault Castells, Shinkook Choi

5 upvotesMay 25, 2023arXiv 预印本
AI 摘要

Classical architectural compression and knowledge distillation reduce the size and computational cost of Stable Diffusion models while maintaining competitive text-to-image synthesis performance.

text-to-image (T2I) generationStable Diffusion models (SDMs)sampling stepsnetwork quantizationblock-removed knowledge-distilled SDMs (BK-SDMs)residual blocksattention blocksU-Netdistillation-based pretrainingLAION pairszero-shot MS-COCO benchmarkDreamBooth finetuning

Abstract

Exceptional text-to-image (T2I) generation results of Stable Diffusion models (SDMs) come with substantial computational demands. To resolve this issue, recent research on efficient SDMs has prioritized reducing the number of sampling steps and utilizing network quantization. Orthogonal to these directions, this study highlights the power of classical architectural compression for general-purpose T2I synthesis by introducing block-removed knowledge-distilled SDMs (BK-SDMs). We eliminate several residual and attention blocks from the U-Net of SDMs, obtaining over a 30% reduction in the number of parameters, MACs per sampling step, and latency. We conduct distillation-based pretraining with only 0.22M LAION pairs (fewer than 0.1% of the full training pairs) on a single A100 GPU. Despite being trained with limited resources, our compact models can imitate the original SDM by benefiting from transferred knowledge and achieve competitive results against larger multi-billion parameter models on the zero-shot MS-COCO benchmark. Moreover, we demonstrate the applicability of our lightweight pretrained models in personalized generation with DreamBooth finetuning.

北京市昌平区探索星信息技术及软件开发工作室

京ICP备2026059466号
On Architectural Compression of Text-to-Image Diffusion Models | TensorX