Timestep Rescheduling in Diffusion Inversion

Shangquan Sun, Ting Gong, Zhirui Liu, Jiamin Wu, Runkai Zhao, Mianxin Liu, Wenqi Ren, Xiaochun Cao

Introduction

To edit a real-world image using a diffusion model, the image must first undergo diffusion inversion—the process of mapping a clean image back into the model's "latent noise" space. In a perfect inversion, the model can take that noise and reconstruct the original image exactly. However, most diffusion inversion methods assume that using "uniform" timesteps is the gold standard.

This paper challenges that assumption, proving that uniform spacing actually accumulates significant errors. By introducing TRDI (Timestep Rescheduling in Diffusion Inversion), the authors provide a zero-overhead, "off-the-shelf" scheduler that uses dynamic programming to strategically allocate timesteps, drastically improving image reconstruction and editing fidelity.

The Problem: Accumulating Errors and "Drift"

The industry standard for this process, DDIM inversion, is fast but relies on a mathematical approximation that introduces small errors at every step. Over time, these errors accumulate, leading to "drift." As a result, the reconstructed image loses fine details, such as the exact shape of an eyelid or the texture of a background.

While recent research has attempted to fix this by adding complex iterative refinements—which significantly slow down the process—this paper asks a more fundamental question: Are we even picking the right timesteps?

Currently, almost all pipelines use a uniform schedule (e.g., steps 0, 20, 40, 60...). The authors argue that this "one-size-fits-all" approach is suboptimal because the difficulty of inversion is not constant across the diffusion trajectory.

The TRDI Framework

The authors propose a two-stage framework called TRDI to find a better "path" through the noise.

1. Theoretical Error Analysis

The researchers derived a formula showing that inversion error is a "scaled fixed-point problem." Crucially, they identified a parabolic trend: errors are naturally higher at very small timesteps (near the clean image) and very large timesteps (near pure noise). Uniform steps are "lazy" because they ignore the fact that some parts of the diffusion trajectory are much more sensitive to discretization than others.

2. Global Rescaling

To address this, TRDI first applies a coarse adjustment using a power-law scaling factor ($\gamma$). This "stretches" the timeline to give more breathing room to high-error regions.

3. Local Rescheduling via Dynamic Programming (DP)

To fine-tune the schedule, the authors use a windowed Dynamic Programming (DP) algorithm. This algorithm treats the noise schedule as a graph and finds the discrete sequence of timesteps that minimizes a "surrogate" error function.

Because they use a mathematical proxy (the scaling coefficient $c_\alpha$) that depends only on the noise schedule parameters, they don't need to run the heavy neural network to find the best schedule. The DP optimization is done offline. Once the optimal schedule is calculated for a specific model, it can be reused indefinitely with zero additional computational cost during the actual image editing process.

Experimental Setup

The researchers evaluated their method across several popular benchmarks and models:

  • Datasets: MSCOCO for image reconstruction (1,000 image-caption pairs) and PIE-Bench for prompt-based image editing (700 images across 10 edit types).
  • Models: Stable Diffusion v1.5, SDXL, and the lightning-fast SDXL Turbo (which only uses 4 steps).

Key Results

TRDI is not a new inversion method; it is a scheduler retrofit. It can be plugged into existing state-of-the-art methods like ReNoise or GNRI to give them an instant performance boost without changing their underlying logic.

  • Quantitative Gains: On the MSCOCO dataset using SDXL, TRDI improved the LPIPS score (a measure of perceptual similarity) by 13.47% over standard DDIM. Even when paired with advanced methods like ReNoise, it still provided a significant 16.57% boost in LPIPS.
  • Qualitative Improvements: In reconstruction tasks, TRDI corrected "hallucinated" details. Where standard DDIM might distort a child's eyelids or change the shape of a fruit, TRDI preserved the original structures faithfully.
  • Editing Fidelity: In PIE-Bench editing tasks, TRDI consistently achieved better "Background Preservation" scores, meaning it successfully altered the targeted regions while leaving the rest of the image untouched.
  • Zero Overhead: The DP solver takes about 9 seconds to run once on a CPU, which is negligible compared to the hours required for large-scale image processing.

Limitations and Future Work

While highly effective, TRDI has a few limitations. The error proxy assumes the diffusion model is "well-trained" and follows a standard Gaussian distribution. If a model has significant "mismatch" or if the edit involves massive semantic conflicts, the surrogate might be less accurate.

Additionally, while TRDI works exceptionally well for first-order solvers like DDIM, its interaction with more complex, higher-order ODE solvers (like DPM-Solver++) remains an area for future exploration. Finally, the logic of non-uniform timestep allocation could potentially be extended beyond inversion to improve the generation (sampling) side of diffusion models as well.

Summary updated

BibTeX
@inproceedings{sun2026timestep,
  author = {Shangquan Sun and Ting Gong and Zhirui Liu and Jiamin Wu and Runkai Zhao and Mianxin Liu and Wenqi Ren and Xiaochun Cao},
  title = {{Timestep Rescheduling in Diffusion Inversion}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=WsZwXIx5r8},
}
Figure