pith. sign in

arxiv: 2605.02417 · v2 · pith:TYGMOWYBnew · submitted 2026-05-04 · 💻 cs.CV

DirectEdit: Step-Level Accurate Inversion for Flow-Based Image Editing

Pith reviewed 2026-05-08 18:58 UTC · model grok-4.3

classification 💻 cs.CV
keywords image editingflow modelsinversiontext-to-imageattention injectionreconstruction errortraining-free editing
0
0 comments X

The pith

DirectEdit aligns forward paths in flow transformers to eliminate reconstruction drift in image editing without extra computations.

A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.

The paper aims to solve the problem of accumulated drift in training-free image editing methods that use inversion on pre-trained text-to-image flow models. Existing approaches approximate the reconstruction path with noisy latents from mismatched timesteps, causing errors that limit fidelity. DirectEdit instead directly aligns the forward paths of reconstruction and editing, achieving precise step-level accurate inversion. It also adds a preservation mechanism using attention feature injection and mask-guided blending to balance keeping the original image details with making the desired edits. This matters because it allows high-quality edits using the same number of model calls as before.

Core claim

DirectEdit eliminates the inherent reconstruction error in flow-based editing by directly aligning the forward paths rather than attempting to fix the inversion path, enabling precise reconstruction and reliable feature sharing between paths at no additional neural function evaluations. The method further incorporates attention feature injection and multi-branch mask-guided noise blending for effective preservation.

What carries the argument

Direct forward-path alignment in the flow transformer, which matches the denoising steps exactly between the reconstruction and editing branches to avoid timestep mismatch.

If this is right

  • Reconstruction fidelity improves because the path uses exact matching timesteps instead of approximations.
  • Feature sharing becomes reliable since both paths follow identical forward trajectories.
  • Editing performance surpasses prior methods across various scenarios while using the original number of evaluations.
  • The preservation mechanism allows balancing fidelity and editability through attention injection and blending.

Where Pith is reading between the lines

These are editorial extensions of the paper, not claims the author makes directly.

  • This alignment strategy might apply to other generative models that use similar forward processes, potentially improving inversion in diffusion models as well.
  • Users could achieve more intricate edits, such as combining multiple changes, while maintaining original image consistency.
  • Future work might explore automating the mask generation for the blending step to reduce manual input.

Load-bearing premise

The flow transformer allows exact alignment of the forward paths at every timestep without introducing inconsistencies or requiring additional model evaluations.

What would settle it

Running the reconstruction on a test image using DirectEdit and checking if the output matches the original input pixel-for-pixel or with near-zero error, compared to previous methods that show visible drift.

Figures

Figures reproduced from arXiv: 2605.02417 by Desong Yang, Mang Ye.

Figure 1
Figure 1. Figure 1: We present DirectEdit, a simple yet highly effective training-free method for flow-based image editing. Compared with existing inversion-based approaches, DirectEdit explicitly aligns the reconstruction and inversion trajectories and introduces an effective latent feature interaction mechanism, enabling step-level accurate reconstruction and precise background preservation. Extensive experiments across div… view at source ↗
Figure 2
Figure 2. Figure 2: Comparison of Inversion Methods. (a) Standard Euler inversion. Due to the accumulation of approximation errors between the reconstruction and inversion paths, it fails to accomplish successful reconstruction and editing. (b) Inversion via stepwise correction. Although error accumulation is mitigated, the persistence of step-level reconstruction errors results in the continuous injection of “drifted” featur… view at source ↗
Figure 3
Figure 3. Figure 3: Overview of DirectEdit. Left: Direct Alignment for Accurate Inversion. By explicitly aligning with the inversion trajectory, we achieve step-level accurate reconstruction, thereby facilitating the extraction of ideal source image features. Right: Latent Feature Interaction. We further introduce a preservation mechanism that leverages noisy latents and attention features from the reconstruction path. This m… view at source ↗
Figure 4
Figure 4. Figure 4: Qualitative comparison with various editing methods. Our method demonstrates exceptional performance across a diverse range of editing tasks, outperforming prior state-of-the-art approaches in terms of both background preservation and text alignment. 4. Experiments 4.1. Setup Evaluation Datasets and Metrics. We evaluate our pro￾posed method and all baselines on the PIE-Bench dataset (Ju et al., 2023) for i… view at source ↗
Figure 5
Figure 5. Figure 5: Trade-off between CLIP similarity versus PSNR. DirectEdit achieves the optimal balance between editability (CLIP) and background preservation (PSNR) compared to other methods. Connected markers represent different hyperparameters. consistency with editing prompts, often resulting in under￾editing. In comparison, DirectEdit excels across diverse editing scenarios, achieving the best balance between pre￾serv… view at source ↗
Figure 6
Figure 6. Figure 6: Comparison of reconstruction errors across different inversion methods. DirectEdit demonstrates the lowest recon￾struction error among all compared approaches. still suffers from severe error accumulation. Stepwise Cor￾rection (Ju et al., 2023) employs a strategy that realigns the trajectory with the correct inversion path after each recon￾struction step; however, step-level errors remain pronounced. Build… view at source ↗
Figure 7
Figure 7. Figure 7: Ablation study on attention feature injection steps in DirectEdit. Attention feature injection primarily influences the consistency between the edited region and the source image, where a greater number of injection steps results in higher similarity. 5. Conclusion In this paper, we present DirectEdit, a simple yet highly effective training-free framework for flow-based image edit￾ing. Unlike existing meth… view at source ↗
Figure 8
Figure 8. Figure 8: DirectEdit with Virtual Reconstruction. As shown in Algorithm 1, DirectEdit achieves precise reconstruction and facilitates drift-free feature interaction. Crucially, we observe that the editing process leverages features extracted from the reconstruction path. Given that the reconstruction path is explicitly aligned with the inversion trajectory in our framework, the computation of the reconstruction path… view at source ↗
Figure 9
Figure 9. Figure 9: System prompt for generating multi-branch mask. D. More Implementation Details In our experiments, we implement our method utilizing FLUX.1-dev (Labs, 2024) and SD3.5-medium (Esser et al., 2024) as the backbone models, respectively. For both architectures, the number of denoising steps is uniformly set to 30. We configure the Classifier-Free Guidance (CFG) (Ho & Salimans, 2022) scale to 1 for the inversion… view at source ↗
Figure 10
Figure 10. Figure 10: Additional qualitative comparisons on PIE-Bench. E.2. More Ablation Study We conducted additional ablation studies on FLUX.1-dev to investigate the impact of various design choices on editing performance. Exp. ⃝1 employ the standard Euler method; due to the absence of editing components such as attention injection and noise blending, this configuration is equivalent to direct generation guided by the targ… view at source ↗
Figure 11
Figure 11. Figure 11: presents additional results of DirectEdit applied to high-resolution real-world images. As observed, DirectEdit achieves versatile image editing across diverse scenarios, capable of handling diverse local edits (e.g., object replacement, attribute modification, and fine-grained editing) as well as global style transfer (e.g., transforming photographs into painting or cartoon styles). Furthermore, by lever… view at source ↗
Figure 12
Figure 12. Figure 12: Failure case study. Our method shows inherent limitations when handling specific editing tasks (e.g., size change, spatial movement, viewpoint change, complex reasoning). 16 view at source ↗
read the original abstract

With recent advancements in large-scale pre-trained text-to-image (T2I) models, training-free image editing methods have demonstrated remarkable success. Typically, these methods involve adding noise to a clean image via an inversion process, followed by separate denoising steps for the reconstruction and editing paths during the forward process. However, since the reconstruction path is approximated using noisy latents from mismatched timesteps, existing methods inevitably suffer from accumulated drift, which fundamentally limits reconstruction fidelity. To address this challenge, we systematically analyze the inversion process within the flow transformer and propose DirectEdit, a simple yet effective editing method that eliminates the inherent reconstruction error without introducing additional neural function evaluations (NFEs). Unlike most prior works that attempt to rectify the inversion path, DirectEdit focuses on directly aligning the forward paths, enabling precise reconstruction and reliable feature sharing. Furthermore, we introduce a preservation mechanism based on attention feature injection and multi-branch mask-guided noise blending, which effectively balances fidelity and editability. Extensive experiments across diverse scenarios demonstrate that DirectEdit achieves efficient and accurate image editing, delivering superior performance that outperforms state-of-the-art methods. Code and examples are available at https://desongyang.github.io/Directedit.

Editorial analysis

A structured set of objections, weighed in public.

Desk editor's note, referee report, simulated authors' rebuttal, and a circularity audit. Tearing a paper down is the easy half of reading it; the pith above is the substance, this is the friction.

Referee Report

2 major / 3 minor

Summary. The paper claims that existing training-free image editing methods in flow-based T2I models suffer from accumulated drift due to mismatched timesteps in reconstruction and editing paths. DirectEdit addresses this by directly aligning forward paths in the flow transformer to achieve zero reconstruction error without extra NFEs, combined with attention feature injection and multi-branch mask-guided noise blending for balancing fidelity and editability. Experiments show it outperforms SOTA methods across diverse scenarios.

Significance. If the alignment mechanism holds without drift, this would provide a computationally efficient way to achieve high-fidelity reconstruction and editing in flow-based models, improving upon inversion-rectification approaches. The open code and examples strengthen potential impact for reproducibility in the CV community.

major comments (2)
  1. [§3] §3 (Method), the core alignment claim: DirectEdit asserts exact forward-path alignment at every timestep produces identical latents and features to the clean-image path with no drift and no additional NFEs. However, this is load-bearing for the zero-reconstruction-error result; under standard Euler discretization of the flow ODE, non-linear dynamics or timestep-dependent attention recomputation could still introduce mismatches, as noted in the stress-test. The manuscript needs explicit analysis or empirical verification that the proposed discrete matching prevents accumulation of error.
  2. [§4] §4 (Experiments), quantitative tables: While superiority is claimed, the support for 'eliminating inherent reconstruction error' relies on visual and qualitative results; if reconstruction metrics (e.g., PSNR or LPIPS on inversion) are reported, they should be highlighted to directly test the zero-error claim rather than relying solely on editing quality.
minor comments (3)
  1. [Abstract] The abstract and introduction use 'flow transformer' without a brief definition or reference to the specific ODE formulation (e.g., the velocity field or attention structure) on first use; this would aid readers unfamiliar with the exact architecture.
  2. [Figures] Figure captions and method diagrams could more explicitly label the 'direct alignment' step versus prior inversion paths to clarify the difference at a glance.
  3. [§3] Minor notation inconsistency: 'NFE' is defined once but used interchangeably with 'neural function evaluations' later; consistent abbreviation after first use would improve clarity.

Simulated Author's Rebuttal

2 responses · 0 unresolved

We thank the referee for the constructive feedback on our manuscript. We have carefully addressed each major comment below and revised the paper to incorporate additional analysis and quantitative metrics.

read point-by-point responses
  1. Referee: [§3] §3 (Method), the core alignment claim: DirectEdit asserts exact forward-path alignment at every timestep produces identical latents and features to the clean-image path with no drift and no additional NFEs. However, this is load-bearing for the zero-reconstruction-error result; under standard Euler discretization of the flow ODE, non-linear dynamics or timestep-dependent attention recomputation could still introduce mismatches, as noted in the stress-test. The manuscript needs explicit analysis or empirical verification that the proposed discrete matching prevents accumulation of error.

    Authors: We appreciate the referee highlighting the importance of verifying the alignment under discretization. In DirectEdit, alignment is achieved by starting the reconstruction path from the exact clean latent and using the identical timestep schedule and transformer inputs for both paths, with attention features injected from the aligned forward computation. This ensures identical latents and features at every discrete Euler step. We have added a new derivation in the revised §3 proving that the proposed matching yields exact equivalence (no accumulation) under the flow ODE discretization, and expanded the stress-test appendix with quantitative latent-difference plots over timesteps confirming zero drift. revision: yes

  2. Referee: [§4] §4 (Experiments), quantitative tables: While superiority is claimed, the support for 'eliminating inherent reconstruction error' relies on visual and qualitative results; if reconstruction metrics (e.g., PSNR or LPIPS on inversion) are reported, they should be highlighted to directly test the zero-error claim rather than relying solely on editing quality.

    Authors: We agree that explicit reconstruction metrics strengthen the zero-error claim. In the revised manuscript, we have added Table 1 in §4.1 reporting PSNR, LPIPS, and MSE for inversion reconstruction on COCO and editing benchmarks. DirectEdit achieves PSNR > 42 dB and LPIPS < 0.01 (near-zero error), outperforming baselines with visible drift. These metrics are now highlighted in the text and compared directly to editing quality results. revision: yes

Circularity Check

0 steps flagged

No circularity: algorithmic proposal derived from flow transformer analysis

full rationale

The paper presents DirectEdit as a new editing method obtained by analyzing inversion in flow transformers and introducing attention injection plus mask blending. No equations reduce a claimed prediction to a fitted input by construction, no self-citation chain bears the central claim, and no ansatz or uniqueness result is imported from the authors' prior work. The derivation remains self-contained against external flow-model benchmarks and does not rename known results.

Axiom & Free-Parameter Ledger

0 free parameters · 1 axioms · 0 invented entities

The method rests on standard assumptions about flow transformer behavior and attention mechanisms in pre-trained T2I models; no new free parameters or invented entities are introduced beyond algorithmic choices.

axioms (1)
  • domain assumption Flow transformers permit exact forward path alignment at each timestep without additional NFEs
    Invoked in the analysis of the inversion process to justify eliminating reconstruction error.

pith-pipeline@v0.9.0 · 5501 in / 1214 out tokens · 98582 ms · 2026-05-08T18:58:44.200710+00:00 · methodology

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.

Lean theorems connected to this paper

Citations machine-checked in the Pith Canon. Every link opens the source theorem in the public Lean library.

What do these tags mean?
matches
The paper's claim is directly supported by a theorem in the formal canon.
supports
The theorem supports part of the paper's argument, but the paper may add assumptions or extra steps.
extends
The paper goes beyond the formal theorem; the theorem is a base layer rather than the whole result.
uses
The paper appears to rely on the theorem as machinery.
contradicts
The paper's claim conflicts with a theorem or certificate in the canon.
unclear
Pith found a possible connection, but the passage is too broad, indirect, or ambiguous to say the theorem truly supports the claim.