LanPaint: Training-Free Diffusion Inpainting with Asymptotically Exact and Fast Conditional Sampling
Abstract: Diffusion models excel at joint pixel sampling for image generation but lack efficient training-free methods for partial conditional sampling (e.g., inpainting with known pixels). Prior works typically formulate this as an intractable inverse problem, relying on coarse variational approximations, heuristic losses requiring expensive backpropagation, or slow stochastic sampling. These limitations preclude (1) accurate distributional matching in inpainting results, (2) efficient inference modes without gradients, and (3) compatibility with fast ODE-based samplers. To address these limitations, we propose LanPaint: a training-free, asymptotically exact partial conditional sampling method for ODE-based and rectified-flow diffusion models. By leveraging carefully designed Langevin dynamics, LanPaint enables fast, backpropagation-free Monte Carlo sampling. Experiments demonstrate that our approach achieves superior performance with precise partial conditioning and visually coherent inpainting across diverse tasks. Code is available on https://github.com/scraed/LanPaint.
Submission Length: Regular submission (no more than 12 pages of main content)
Changes Since Last Submission: We sincerely thank the reviewers and AE for their thorough reading and valuable feedback. In camera-ready version, we have revised the manuscript as follows:
1. Added Section 4.4: Emphasis LanPaint's dimension-agnostic property that supporting conditional sampling for arbitrary dimension data.
2. Added demonstration for video inpainting (section 5.6), showcasing LanPaint's applicability beyond images.
3. Added the link to code in the abstract
Code: https://github.com/scraed/LanPaint
Assigned Action Editor: ~Jakub_Mikolaj_Tomczak1
Submission Number: 5448
Loading