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

SUGAR: Spectral Uncertainty Guidance for Adaptive Reverse Diffusion Sampling

Tianqi Zhao, Xixi Liu, Zhengrui Xiang, Liangrui PengNeurIPS 2026

TL;DR

Diffusion models still occasionally hallucinate mangled hands or broken geometry, and trying to fix these artifacts by measuring uncertainty pixel-by-pixel ignores how neighboring pixels form coherent structures. SUGAR shifts uncertainty estimation into the frequency domain, allowing a pretrained diffusion model to detect and steer away from structural collapses on the fly. Best of all, it requires zero extra training and improves both the denoising direction and the injected noise during sampling.

What Problem Does This Paper Address?

Diffusion models generate images by iteratively sculpting random Gaussian noise into clean pictures. Sometimes, however, the model gets "confused" mid-generation, resulting in structural collapses or visual artifacts.

Recent work has tried to catch and correct these mistakes during inference by measuring the model's uncertainty at each denoising step and nudging the generation toward more confident territory. The catch? Computing the full covariance matrix of pixel relationships for a high-resolution image is computationally impossible. Existing methods take a shortcut: they treat every pixel as an independent island (a spatial diagonal approximation).

In real images, adjacent pixels are deeply correlated—they form edges, textures, and semantic objects. Guiding pixels independently can shatter local coherence, sometimes introducing new discontinuities right where you are trying to fix old ones (like human hands). Furthermore, standard diffusion sampling injects uniform, fixed-schedule noise at each reverse step, missing an opportunity to adaptively explore uncertain structures without training an auxiliary variance-prediction network.

Methods

SUGAR (Spectral Uncertainty Guidance for Adaptive Reverse Diffusion Sampling) moves the entire uncertainty estimation and guidance pipeline from pixel space into the frequency domain.

  1. Spectral Uncertainty Estimation: Building on a standard Monte Carlo resampling trick, the authors take a noisy image at step $t$, estimate a pseudo-clean anchor image, and re-inject noise $M=5$ times to see how much the model's score predictions vary. What's new: Instead of computing pixel-wise variance, SUGAR applies a 2D Discrete Cosine Transform (DCT) to the predicted scores before taking the variance. Because natural images behave like Markov processes with strong local correlations, the DCT acts as an approximate mathematical decorrelator—meaning a cheap diagonal variance in frequency space preserves rich spatial correlations once transformed back to pixel space.
  2. Structure-Aware Mean Guidance: At each guided step, SUGAR takes a one-step gradient descent update on the predicted score to minimize high-uncertainty frequencies. Because low frequencies dictate global layout and semantics, the authors apply a negative exponential weight that penalizes low-frequency uncertainty more aggressively.
  3. Training-Free Covariance Modulation: In reverse diffusion, each step transitions via a Gaussian distribution with a mean and a covariance. Using a statistical tool called Louis' identity, the authors prove that the optimal reverse covariance is directly tied to the posterior variance of the true forward noise. SUGAR uses its frequency-domain uncertainty map as a training-free proxy for this optimal covariance—injecting more exploratory noise into uncertain frequencies and less into confident ones, before projecting back via Inverse DCT (IDCT).

To keep compute low, SUGAR is only applied during steps 3–5 of a 50-step generation.

Datasets

Because SUGAR is a training-free inference method, no datasets are used for training (aside from a synthetic 2D Mixture of Gaussians toy dataset used to benchmark against trained baselines). Evaluation spans existing standard benchmarks:

  • ImageNet ($128^2$, $256^2$, and $512^2$) for class-conditional generation.
  • DrawBench (200 challenging prompts across 11 categories) for text-to-image generation.
  • LSUN-Churches ($256^2$) for unconditional generation.

Key Insights and Ideas

  • Artifacts have a spectral signature: When the authors separated generated images into "Good" and "Bad" (artifact-heavy) piles, the bad images consistently showed higher score uncertainty across the spectrum, with a dramatic gap in the low-frequency region where core semantic shapes live.
Frequency-domain uncertainty comparison showing artifact-heavy images have noticeably higher uncertainty than structurally sound images, especially at low frequencies.
  • DCT gives you pixel correlations for free: Truncating a covariance matrix to its diagonal in pixel space throws away spatial structure. Doing the exact same truncation in DCT space discards far less off-diagonal energy, naturally inducing spatially correlated adjustments when inverted back to image space.
  • Uncertainty and optimal noise injection are two sides of the same coin: Via Louis' identity, measuring how sensitive the denoising network is to input perturbations serves as a surprisingly accurate, zero-training stand-in for the intractable Hessian matrix needed for optimal reverse-process variance.

Key Results

SUGAR consistently outperforms both standard sampling and spatial-domain uncertainty guidance across U-Net, U-ViT, and Stable Diffusion 3 (SD3) architectures:

  • Class-Conditional (ImageNet): On U-Net ($128^2$), SUGAR drops FID (lower is better) from 15.76 (baseline) and 15.68 (spatial guidance) down to 13.21, while boosting CLIP alignment to 27.93. On U-ViT ($256^2$), FID improves from 5.88 to 5.42.
  • Text-to-Image (SD3 on DrawBench): SUGAR improves CLIP score from 31.95 to 32.27 and human-preference score (HPSv2) from 28.35 to 28.52. Qualitatively, it fixes mangled hands and semantic prompt mismatches where spatial guidance leaves structural glitches.
  • Unconditional (LSUN-Churches): FID drops from 12.25 to 11.44 (whereas spatial guidance slightly degrades FID to 12.34), proving the method doesn't rely on text or class labels to work.
  • Minimal DCT Overhead: Guiding steps 3–5 increases NFE (function evaluations) from 50 to 65 per image, and DCT/IDCT adds virtually zero cost over spatial guidance (108.37s vs. 107.87s for 256 images, with identical 6.703 GiB peak memory). It also shines in 5-step generation, dropping U-ViT FID from 25.89 to 24.59.

Limitations and Future Work

  • Global side effects: Because the 2D-DCT operates globally across the entire image, individual frequencies aren't tied to specific $(x, y)$ coordinates. Tweaking a frequency to fix a broken hand can unintentionally alter other plausible details elsewhere in the image—for example, adding eyeglasses to a woman's face while fixing her fingers:

Spatial guidance (left) leaves finger artifacts, while SUGAR's frequency guidance (right) fixes the hand structure inside the green box but globally alters the image by adding glasses. SUGAR's frequency-guided output fixing the woman's hand on the book, while subtly introducing eyeglasses due to global DCT modulation.

  • White-box requirement: SUGAR needs access to intermediate noisy states and model gradients during sampling, so it cannot be bolted onto closed-source APIs that only return finished images.
  • Future directions: To get the structural benefits of spectral guidance without global collateral changes, the authors plan to explore spatially localized transforms, such as patch-level DCTs or multi-scale wavelets.

Summary updated

BibTeX
@inproceedings{zhao2026sugar,
  author = {Tianqi Zhao and Xixi Liu and Zhengrui Xiang and Liangrui Peng},
  title = {{SUGAR: Spectral Uncertainty Guidance for Adaptive Reverse Diffusion Sampling}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=UfOJVYkmfd},
}
Figure