Effective Quantization for Diffusion Models on CPUs

Hanwen Chang, Haihao Shen, Yiyang Cai, Xinyu Ye, Zhenzhong Xu +5 more
11/2/2023
8 citations
cs.CVcs.AI
diffusion-flowquantization-pruning

Official code: intel/intel-extension-for-transformers (2,173 stars, Python, Apache-2.0, last commit 2024-10-08).

Abstract

Diffusion models have gained popularity for generating images from textual descriptions. Nonetheless, the substantial need for computational resources continues to present a noteworthy challenge, contributing to time-consuming processes.

Show full abstract

Quantization, a technique employed to compress deep learning models for enhanced efficiency, presents challenges when applied to diffusion models. These models are notably more sensitive to quantization compared to other model types, potentially resulting in a degradation of image quality. In this paper, we introduce a novel approach to quantize the diffusion models by leveraging both quantization-aware training and distillation. Our results show the quantized models can maintain the high image quality while demonstrating the inference efficiency on CPUs. The code is publicly available at: https://github.com/intel/intel-extension-for-transformers.

View on arXivView PDF

Code Implementations(1)

Apache-2.0

⚡ Build your chatbot within minutes on your favorite device; offer SOTA compression techniques for LLMs; run LLMs efficiently on Intel Platforms⚡

2,173213Python, C++Nov 11, 20222 years agoApache-2.0
4-bitsautoroundchatbotchatpdfgaudi3+11 more

Similar Papers

Cite this paper

@article{chang2023effective,
  title  = {Effective Quantization for Diffusion Models on CPUs},
  author = {Hanwen Chang and Haihao Shen and Yiyang Cai and Xinyu Ye and Zhenzhong Xu and Wenhua Cheng and Kaokao Lv and Weiwei Zhang and Yintong Lu and Heng Guo},
  year   = {2023},
  eprint = {2311.16133},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2311.16133v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2311.16133.svg)](https://codeofpaper.com/paper/2311.16133)

Discussion