EP-CFG: Energy-Preserving Classifier-Free Guidance

Kai Zhang, Fujun Luan, Sai Bi, Jianming Zhang
12/13/2024
cs.CVcs.AIcs.LG

No confident code implementation found for this paper.

Abstract

Classifier-free guidance (CFG) is widely used in diffusion models but often introduces over-contrast and over-saturation artifacts at higher guidance strengths. We present EP-CFG (Energy-Preserving Classifier-Free Guidance), which addresses these issues by preserving the energy distribution of the conditional prediction during the guidance process. Our method simply rescales the energy of the guided output to match that of the conditional prediction at each denoising step, with an optional robust variant for improved artifact suppression. Through experiments, we show that EP-CFG maintains natural image quality and preserves details across guidance strengths while retaining CFG's semantic alignment benefits, all with minimal computational overhead.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{zhang2024epcfg,
  title  = {EP-CFG: Energy-Preserving Classifier-Free Guidance},
  author = {Kai Zhang and Fujun Luan and Sai Bi and Jianming Zhang},
  year   = {2024},
  eprint = {2412.09966},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2412.09966v1}
}

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/2412.09966.svg)](https://codeofpaper.com/paper/2412.09966)

Discussion