mlsanityData to 14 Oct 2026

Your Latent Mask is Wrong: Pixel-Equivalent Latent Compositing for Diffusion Models

arXiv 2512.05198 ↗First posted 4 Dec 2025cs.CV cs.GR cs.LGcited by 4

On the map: Diffusion models → Diffusion foundations and sampling

Abstract (arXiv)

Latent inpainting in diffusion models still relies almost universally on linearly interpolating VAE latents under a downsampled mask. We propose a key principle for compositing image latents: Pixel-Equivalent Latent Compositing (PELC). An equivalent latent compositor should be the same as compositing in pixel space. This principle enables full-resolution mask control and true soft-edge alpha compositing, even though VAEs compress images 8x spatially. Modern VAEs capture global context beyond patch-aligned local structure, so linear latent blending cannot be pixel-equivalent: it produces large artifacts at mask seams and global degradation and color shifts. We introduce DecFormer, a 7.7M-parameter transformer that predicts per-channel blend weights and an off-manifold residual correction to realize mask-consistent latent fusion. DecFormer is trained so that decoding after fusion matches pixel-space alpha compositing, is plug-compatible with existing diffusion pipelines, requires no backbone finetuning and adds only 0.07% of FLUX.1-Dev's parameters and 3.5% FLOP overhead. On the FLUX.1 family, DecFormer restores global color consistency, soft-mask support, sharp boundaries, and high-fidelity masking, reducing error metrics around edges by up to 53% over standard mask interpolation. Used as an inpainting prior, a lightweight LoRA on FLUX.1-Dev with DecFormer achieves fidelity comparable to FLUX.1-Fill, a fully finetuned inpainting model. While we focus on inpainting, PELC is a general recipe for pixel-equivalent latent editing, as we demonstrate on a complex color-correction task.

Key facts. Cited by 4 papers in the map (data through 14 Oct 2026). Placed in Diffusion foundations and sampling, one of 14 directions in Diffusion models. Builds on 15 of its 25 references that are in the map. First posted on arXiv 4 Dec 2025.

Builds on

15 of 25 references.

Closest ancestors · 2

Same direction, newest first

  1. 2022Scalable Diffusion Models with Transformers19 Dec
  2. 2021High-Resolution Image Synthesis with Latent Diffusion Models20 Dec

Other references · 13

  1. 2021LoRA: Low-Rank Adaptation of Large Language Modelscited by 14,380
  2. 2018The Unreasonable Effectiveness of Deep Features as a Perceptual Metriccited by 11,177
  3. 2023Adding Conditional Control to Text-to-Image Diffusion Modelscited by 5,503
  4. 2021SDEdit: Guided Image Synthesis and Editing with Stochastic Differential Equationscited by 1,937
  5. 2021Blended Diffusion for Text-driven Editing of Natural Imagescited by 927
  6. 2022DiffEdit: Diffusion-based semantic image editing with mask guidancecited by 647
  7. 2022Paint by Example: Exemplar-based Image Editing with Diffusion Modelscited by 489
  8. 2024BrushNet: A Plug-and-Play Image Inpainting Model with Decomposed Dual-Branch Diffusioncited by 202
  9. 2023A Task is Worth One Word: Learning with Task Prompts for High-Quality Versatile Image Inpaintingcited by 169
  10. 2020Bridging Composite and Real: Towards End-to-end Deep Image Mattingcited by 89
  11. 2024DiffEditor: Boosting Accuracy and Flexibility on Diffusion-based Image Editingcited by 88
  12. 2021Privacy-Preserving Portrait Mattingcited by 60
1 more
  1. 2023Differential Diffusion: Giving Each Pixel Its Strengthcited by 29

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 4.

4 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2024Simpler Diffusion (SiD2): 1.5 FID on ImageNet512 with pixel-space diffusion
  2. 2023Latent Consistency Models: Synthesizing High-Resolution Images with Few-Step Inference
  3. 2025One Small Step in Latent, One Giant Leap for Pixels: Fast Latent Upscale Adapter for Your Diffusion Models
  4. 2025DiP: Taming Diffusion Models in Pixel Space
  5. 2026DA-VAE: Plug-in Latent Compression for Diffusion via Detail Alignment
  6. 2025PixPerfect: Seamless Latent Diffusion Local Editing with Discriminative Pixel-Space Refinement
  7. 2022Unifying Diffusion Models' Latent Space, with Applications to CycleDiffusion and Guidance
  8. 2026Source-Agnostic Image Translation Based on Latent Aware Adaptive Masking