Research
EraseLoRA: MLLM-Driven Foreground Exclusion and Background Subtype Aggregation for Dataset-Free Object Removal
EraseLoRA: MLLM-Driven Foreground Exclusion and Background Subtype Aggregation for Dataset-Free Object Removal Overview Research area: Computer vision, specifically image editing and object removal wi
- arXiv
- 2512.21545
- Published
- 2025-12-25
- Authors
- Sanghyun Jo, Donghwan Lee, Eunji Jung, Seong Je Oh, Kyungsu Kim
AI summary
EraseLoRA: MLLM-Driven Foreground Exclusion and Background Subtype Aggregation for Dataset-Free Object RemovalOverview
- Research area: Computer vision, specifically image editing and object removal with diffusion models, combined with multimodal large-language model (MLLM) reasoning and test-time adaptation.
- Technical level: Intermediate. The paper builds on latent diffusion, self-/cross-attention, LoRA, and MLLM prompting, but its central ideas (removing an object and rebuilding what was hidden behind it) can be understood without deep math.
- Scope: The paper introduces a dataset-free, model-agnostic framework for removing a masked object from an image and faithfully reconstructing the background it was hiding, evaluated on two benchmarks against both dataset-free and dataset-driven baselines.
What This Paper Is About
Object removal is not the same as generic inpainting: the goal is to make the masked target disappear and to restore the occluded background faithfully, rather than to invent plausible new content. Existing dataset-free methods do this by manipulating the diffusion model's internal self-attention inside the mask, but the authors argue this fails in two ways: it treats the masked region as the only foreground (so non-target objects outside the mask get mistaken for background and regenerated), and it constrains attention uniformly without distinguishing different background subtypes (so textures blur and structures misalign). EraseLoRA replaces attention surgery with explicit background-aware reasoning plus test-time optimization, requiring no training data.
Key Contributions
- Identification of a failure mode. The authors name a specific, previously under-analyzed failure in object removal: non-target foregrounds outside the mask are frequently misinterpreted as background, causing their unintended regeneration across recent dataset-free methods.
- The EraseLoRA framework. A background-aware, dataset-free object-removal method combining MLLM-guided separation of target foreground, non-target foregrounds, and background (the BFE stage) with a multi-background-subtype test-time adaptation scheme (the BRSA stage), preventing foreground regeneration while keeping contextual coherence.
- New annotations and metrics. Three-label ground-truth annotations (target foreground / non-target foreground / background) that distinguish distractor regions, plus two evaluation metrics designed for unpaired object-removal settings.
- Strong empirical and flexibility results. EraseLoRA improves background fidelity by at least 23% over previous dataset-free methods while nearly halving unwanted foreground re-generation, and it retains these gains when the diffusion backbone and the MLLM are each swapped for alternatives.
Main Findings
- Background fidelity improves substantially over the dataset-free baseline. Against SD3.5-M, BG Sim. rises from 0.605 to 0.743 on OpenImages V7 and from 0.582 to 0.779 on RORD — absolute gains of +0.14 and +0.20, corresponding to roughly 23% and 34% relative improvements. The abstract states at least 23% more faithful background reconstruction than previous dataset-free methods.
- Foreground re-generation is nearly halved. FG Sim. (lower is better) drops from 0.286 to 0.151 on OpenImages V7 and from 0.319 to 0.138 on RORD.
- EraseLoRA also beats dataset-driven methods on the reported metrics. It attains the highest BG Sim. and lowest FG Sim. on both benchmarks while keeping background preservation around 0.90, about 0.18 higher than all five dataset-driven methods compared (SDXL-Inpainting, PowerPaint, CLIPAway, SmartEraser, EntityErasure) — despite using no training data.
- BFE works as a plug-in for prior methods. Inserting the foreground-exclusion stage into DesignEdit and AttentiveEraser without changing their inference pipelines improved background similarity by up to 6.6% and decreased foreground similarity by 8.6% (e.g., AttentiveEraser moved from 0.559/0.276 to 0.596/0.252; DesignEdit from 0.600/0.255 to 0.603/0.251).
- Both losses are needed, and they play different roles. The reconstruction loss alone lifts BG Sim. from 0.605 to 0.736 (+21.7%) but can leave faint foreground traces; the puzzle loss alone (0.561/0.278) suppresses artifacts but lacks background anchoring and misses fine structure; together they give the best result (0.743 BG Sim., 0.151 FG Sim.).
- The framework is not tied to one MLLM. Across LLaVA-7B (0.728/0.164), LLaVA-7B with MARINE (0.727/0.161), Qwen2.5-VL-72B (0.726/0.165), and InternVL3-78B (0.743/0.151), all variants improve over the baseline. Lightweight 7B models still yield gains of up to 20.3% in BG Sim. and 42.7% in FG Sim.
- Tag2Mask choice matters but all options help. Seg4Diff (0.666/0.205), YOLOE (0.709/0.177), SAM3 (0.708/0.177), and Grounded SAM2 (0.743/0.151) all beat the baseline, with at least 10.0% BG Sim. gains and 28.3% FG Sim. reductions; Grounded SAM2 gives up to 22.8% BG Sim. improvement and 47.2% FG Sim. reduction.
- Occluded content can be reconstructed as background. Because the MLLM reasons at the scene level, EraseLoRA can treat content hidden behind the target (e.g., a painting, stairs) as background and rebuild it.
- Cost is a tradeoff. The full 500-iteration optimization takes roughly three minutes per test image on the default backbone SD3.5-M; an early stopping strategy reduces the average to approximately 141 iterations, over 3.5× faster, while preserving more than 96.5% of background similarity.
Methodology in Plain English
EraseLoRA works in two stages, both applied at test time with no additional training dataset.
Stage one — Background-aware Foreground Exclusion (BFE). Given an image and a mask marking the object to delete, an MLLM (default: InternVL3-78B) lists the semantic tags in the scene and sorts them into three groups: the masked object (target foreground), visible objects that might otherwise get regenerated (non-target foregrounds), and the objects or scene parts believed to lie behind the target (background subtypes). Tag2Mask models (default: Grounding DINO plus SAM2, referred to as Grounded SAM2) then turn the non-target foreground tags into pixel-level masks. The image's latent space is partitioned into three masks — target, non-target foreground, and clean background — so that "background" means genuinely clean background, not everything outside the target mask.
Stage two — Background-aware Reconstruction with Subtype Aggregation (BRSA). All backbone parameters stay frozen; only small LoRA adapters (rank 32) inserted into attention blocks are optimized for 500 iterations. Two complementary objectives drive this: a background reconstruction loss, which pins the reconstructed latent to the original latent only on the clean-background mask, and a background puzzle loss, which treats each inferred background subtype as a puzzle piece and pushes the strongest normalized cross-attention response at each location to land on valid regions (target or clean background) rather than on non-target foregrounds. The two are combined as L_total = L_recon + λ·L_puzzle with λ = 0.2. This softly regulates where attention flows instead of hard-blocking attention as prior methods do.
Evaluation. On 200 samples from OpenImages V7 and 343 frames from RORD, the authors report DINO-based FG Sim. (lower is better), BG Sim. (higher is better), and BG Pres. via SSIM on unmasked regions. Because both datasets originally lacked separation between non-target foregrounds and background, they re-annotated them with three-label ground-truth masks.
Why This Matters
Impact on research. The paper reframes dataset-free object removal from an attention-manipulation problem into a reasoning problem: the bottleneck is not where the model looks but whether it correctly understands what counts as background. It also contributes three-label annotations and two metrics tailored to unpaired removal evaluation, and demonstrates that a generally useful MLLM plus a lightweight adapter can substitute for a removal-specific trained model.
Real-world applications (plausible uses of object removal; the paper does not enumerate these itself):
- Consumer photo editing: deleting unwanted people, signs, or clutter while keeping the scene looking untouched.
- E-commerce and product photography: cleaning up studio or location shots without altering the product itself.
- Real estate, travel, and publishing imagery: removing distractions while preserving the original architecture and landscape.
- Privacy and media workflows: removing identifying objects or bystanders from footage and stills, and supporting video post-production.
Industry relevance. Because EraseLoRA is model-agnostic and needs no paired before/after training data, it can be plugged into existing text-to-image pipelines (SD1.5, SDXL, SD3.5-M, FLUX.1 are all tested) rather than requiring an expensive data-collection and fine-tuning effort. The measured cost — roughly three minutes per image at 500 iterations, reducible to about 141 iterations with early stopping — and the fact that GPU-memory-heavy large MLLMs can be swapped for 7B models make deployment tradeoffs explicit and tunable.
Future Directions
- Video object removal. The paper explicitly names this as an interesting future direction, noting that shared background context across frames could amortize the per-image optimization cost.
- Reducing inference cost further. Combining lightweight MLLMs, early stopping, or other efficiency measures to narrow the gap between the roughly three-minute default and practical interactive latency.
- Robustness to imperfect background reasoning. Complex scenes with subtle semantic boundaries or heavy occlusion can lead the MLLM to define the background incorrectly, producing incomplete or inaccurate removal; improving this is left open.
- Human-in-the-loop control. The interactive variant (point or bounding-box prompts, manual correction of the non-target foreground mask and background tags) is offered as a way to fix challenging failure cases; refining how such guidance is captured and reused is a natural extension.
Target Audience
Researchers and practitioners in computer vision and generative modeling who work on image editing, inpainting, and object removal; engineers integrating diffusion-based editing into products who need a training-data-free, backbone-agnostic method; and readers interested in how MLLMs can supply visual reasoning that diffusion models lack on their own.
Authors’ abstract
Object removal must prevent the masked target from reappearing and reconstruct the occluded background with structural and contextual fidelity, rather than merely filling a hole plausibly. Recent dataset-free approaches manipulate the diffusion model's internal self-attention to prevent it from referencing the masked region, yet they fail in two critical ways: (i) they treat the masked region as the sole foreground, misinterpreting non-target objects as background and regenerating them, and (ii) they apply uniform attention constraints without distinguishing diverse background subtypes, leading to textural blurring and structural misalignment. Both failures stem from the absence of explicit background-aware reasoning. We propose EraseLoRA, a dataset-free framework that replaces attention surgery with background-aware reasoning and test-time adaptation. The first stage, Background-aware Foreground Exclusion (BFE), leverages a multimodal large-language model to separate target foreground, non-target foregrounds, and clean background from a single image-mask pair. The second stage, Background-aware Reconstruction with Subtype Aggregation (BRSA), performs test-time optimization that treats inferred background subtypes as complementary pieces, enforcing their consistent integration through reconstruction and alignment objectives without explicit attention intervention. As a model-agnostic plug-in applicable to diverse diffusion backbones, EraseLoRA reconstructs backgrounds at least 23% more faithful to the original scene than previous dataset-free methods while nearly halving unwanted foreground re-generation, and surpasses all dataset-driven approaches in both aspects despite requiring no training data. Code is available at https://shjo-april.github.io/EraseLoRA.