How do you edit part of an image?
7 posts from 7 authors
Playbook
Practitioners manage localized image edits by using masking tools, post-processing patches to prevent pixel drift, or returning to original references to avoid cumulative drift.
- Mitigate pixel drift via patch pasting
In Qwen-Edit, use a ComfyUI post-processing node to find the changed region, feather it, and paste only that patch back onto the original using defaults of threshold 16, blur 3, dilate 6 and feather 4 . 2
- Prevent cumulative drift in successive edits
When chaining edits in Nano Banana 2.1, return to the original image every few steps or merge changes into a single prompt . Similarly, when using Qwen Image 2.1, go back to a clean reference and merge instructions if drift builds up . 14
- Localized repainting with masks
Use SAM 3.1 in ComfyUI to create masks from prompts or hand-drawn inputs to repaint only the masked area when working with MiniMax H3 . 6
- Add inpainting to Krea2
Implement a workaround in Krea2 by using LanPaint KSampler with Differential Diffusion while keeping resolution small and increasing LanPaint's NumSteps to 10 . 5
- Reduce outpainting seams
When using Flux Klein 9B in ComfyUI, pair Outpaint and Outpaint Stitch nodes and apply Feather and Color Match settings to reduce visible seams . 7
- Handle translucent details via prompting
To maintain realistic semi-transparent details for subjects like jellyfish or dragonfly wings in GPT Image 2.5, describe the subject directly in the prompt instead of using the one-click background removal button . 3
Choosing between approaches
Global style edits require bypassing the patch-pasting method used for local changes in Qwen-Edit 2. In outpainting with Flux Klein 9B, users must choose between keeping the original image or letting the AI redraw the entire frame 7.
Not covered yet
The material does not cover how to specifically edit text within an image or how to handle color correction for specific subject types.
Posts
- Return to the original image every few edits when chaining changes in Nano Banana 2.1The author had two models make eight successive edits to one bakery image (change a door color, add labels, remove a car), then measured drift in areas the prompt never mentioned.

- Paste back only the changed region after an edit to stop pixel drift in Qwen-EditGritAI maintains a ComfyUI post-processing node that compares the image before and after an edit, finds the region that actually changed, feathers it and pastes only that patch back onto the original.
- Prompt translucent subjects directly instead of using one-click background removalFuturepedia covers background removal in GPT Image 2.5.

- Diagnose instruction-based edits in ComfyUI by comparing denoising strengths and a diff imageThe author runs instruction-based image editing locally in ComfyUI with Qwen Image 2.1.

- Enable inpainting in Krea2 with LanPaint KSampler and Differential DiffusionAltruistic_Tax1317 provides a workaround for Krea2 since it lacks native inpainting support.
- Replace a head or whole body locally with SAM 3.1 masks that repaint only the masked areaMickmumpitz demonstrates a local workflow built on ComfyUI and MiniMax H3.

- Outpaint in ComfyUI with Flux Klein 9B and reduce seams using Feather and Color Matchpixaroma outpaints images in ComfyUI with Flux Klein 9B, pairing the Outpaint and Outpaint Stitch nodes.
