Master Local Edits & Style Transfers with This Cutting-Edge Workflow
1. Workflow Overview

This workflow specializes in local inpainting and style transfer, leveraging ICEdit (In-Context Editing) and Flux models to:
Edit Specific Areas: Modify masked regions (e.g., changing couch color to sky blue).
Apply Artistic Styles: Support Van Gogh-style transformations.
Auto-Upscaling: Default 512px output with ESRGAN enlargement.
Core Models:
Flux Fill dev: Official redraw model (FP8 optimized).
ICEdit-LoRA: Fine-tuned for local edits.
T5-XXL & CLIP-L: Dual-text encoders for multilingual prompts.
2. Key Nodes
Built-in Nodes:
DiptychCreate: Splits input image into original + mask pairs.
ICEFConditioning: Fuses text instructions with image context.
FluxGuidance: Controls semantic guidance intensity (default=50).
Custom Nodes:
LibLibTranslate (Install via ComfyUI Manager)
Translates Chinese prompts to English (e.g., "梵高画风" → "Van Gogh style").
easy cleanGpuUsed (From
ComfyUI-Easy-Use
)Prevents OOM errors by clearing VRAM.
Model Dependencies:
ESRGAN_4x: Upscale model loaded via
UpscaleModelLoader
.ae.sft: Custom VAE (place in
models/vae
).
3. Workflow Structure
Group | Function | Input/Output |
---|---|---|
Global Control | Image upload + prompt translation | Input: Image + Chinese → Output: English + Mask |
Model Loaders | Loads UNET, VAE, LoRA | Input: Config → Output: Initialized models |
Sampling | Generates images via KSamplerAdvanced | Input: Text + Mask → Output: Latent space |
Upscaling | Enhances resolution with ESRGAN | Input: 512px → Output: HD (e.g., 1024px) |
Output | Preview & save results | Input: Processed image → Output: PNG |
4. Inputs & Outputs
Required:
Image: Upload via
DiptychCreate
(e.g.,原图2.png
).Prompt: Enter Chinese in
LibLibTranslate
(e.g., "Van Gogh style").
Optional:
Seed: Randomized by default (editable in
KSamplerAdvanced
).Guidance Scale: Adjust in
FluxGuidance
(affects style strength).
Output:
Final images saved to
/ComfyUI/output/
with metadata.Real-time preview via
PreviewImage
.
5. Notes
VRAM: Recommend 12GB+ GPU. Disable
ImageUpscaleWithModel
for low-end GPUs.Troubleshooting:
Missing VAE: Ensure
ae.sft
is inmodels/vae
.Mask issues: Verify
DiptychCreate
mask channels.
Optimization:
Reduce
KSamplerAdvanced
steps (default 28 → 20).Use
easy cleanGpuUsed
to free VRAM periodically.