TL;DR
CREPE (Controlling with REPlica Exchange) is a novel framework that leverages parallel tempering to steer diffusion models at inference time without the need for retraining. By swapping samples across different noise levels, CREPE overcomes the "mode collapse" issues common in Sequential Monte Carlo (SMC) methods. It offers superior sample diversity, memory efficiency, and the unique ability to refine constraints on the fly.
Introduction: The Challenge of Inference-Time Control
While diffusion models excel at generating high-quality data, controlling them at inference time—steering them to satisfy specific rewards or constraints—remains a significant challenge.
Currently, researchers often rely on Sequential Monte Carlo (SMC) to "debias" these models. While effective, SMC introduces three major bottlenecks:
- Mode Collapse: SMC requires a massive batch of particles to function well. Otherwise, its "reweight and resample" step forces all particles to converge on a single, repetitive output.
- Memory Intensity: A large number of particles must be held in memory throughout the entire denoising process.
- Rigidity: Once an SMC run begins, constraints cannot be easily altered. If the output strays, the process must be restarted from scratch.
The authors of CREPE sought a more flexible, diverse, and memory-efficient alternative for inference-time control.
Methodology: Adapting Replica Exchange
The core innovation of CREPE is adapting Replica Exchange (also known as Parallel Tempering) to the diffusion setting.
In traditional Parallel Tempering, multiple Markov Chains run at different "temperatures" (levels of randomness), occasionally swapping samples. High-temperature chains explore the space broadly, while low-temperature chains hone in on the target distribution. CREPE applies this concept to the "time" axis of diffusion:
- Parallel Replicas: It maintains several particles at different diffusion timesteps (noise levels) simultaneously.
- Accelerated Swaps: Using Accelerated Parallel Tempering (APT), it simulates forward and backward paths to propose swaps between these noise levels.
- Score-Based Guidance: Unlike standard Parallel Tempering, which requires an explicit target density, CREPE derives swap rates directly from the pretrained model's score functions.
Crucially, CREPE generates samples sequentially over time rather than in one massive parallel batch. This allows the chain to "burn in" and explore the entire distribution, maintaining much higher diversity than SMC.
Key Insights and Advantages
- Diversity via MCMC: Because CREPE is an MCMC-based sampler, it naturally avoids the "rich get richer" resampling bias of SMC. Instead of killing off "weak" particles, it moves them to different noise levels for further exploration.
- Computational Duality: Parallel Tempering is essentially the computational dual of SMC. While SMC parallelizes over particles and runs sequentially through time, CREPE parallelizes over noise levels and runs sequentially through particles.
- The "Anytime" Advantage: CREPE is an "anytime" algorithm. Users can stop the chain at any iteration after the burn-in period and retrieve a valid sample.
- Online Refinement: Because the chain is continuous, users can introduce a new constraint mid-run. The chain will naturally adapt to the new reward without needing a full restart.
Experimental Results
The authors evaluated CREPE across a wide range of modalities, demonstrating highly competitive performance:
- Molecular Accuracy: In protein folding tasks (Alanine Dipeptide, Tetrapeptide, Hexapeptide), CREPE achieved significantly lower Total Variation Distance (TVD) and better captured multi-modal molecular states compared to SMC.
- Image Quality: On ImageNet-64, CREPE achieved a Fréchet Inception Distance (FID) of 1.79, outperforming the best SMC baseline (1.96) when generating a large number of samples.
- Text Debiasing: When controlling sentiment in text generation (SST-2 dataset), CREPE reduced perplexity by up to 5x compared to standard Classifier-Free Guidance, effectively removing the "gibberish" often introduced by strong steering.
- Maze Navigation: In a long-horizon trajectory stitching task, CREPE reached an 84.6% success rate, significantly outperforming specialized models like CompDiffuser (68%).
Limitations and Future Work
While powerful, CREPE has a few limitations. Like all MCMC methods, it requires a "burn-in" period where initial samples are discarded, making it potentially slower than a single-pass diffusion run for generating just one or two images. Additionally, the method assumes the underlying diffusion model is highly accurate; errors in the learned score function can accumulate over many MCMC iterations, leading to "drift." Finally, choosing the optimal "swap schedule" and noise levels requires tuning, though future work may automate this using advanced schedule-tuning techniques.
Summary updated