Inpaint Options
Per-slot masks, multi-round inpainting, and CFG — the Person Detailer settings box worth opening
- inpaint_options
Person Detailer will happily detail every matched face with its default settings and you'll get good results on day one. The Inpaint Options node is for when you want to stop trusting those defaults. It's a config bundle that plugs into Person Detailer's inpaint_options input, and it hands you three things Person Detailer alone doesn't expose: a CFG scale, a negative prompt for the inpaint pass, and per-slot control over which mask type each person gets, how many inpaint rounds they get, and whether Detail Daemon runs for them.
Think of it as the difference between one-size-fits-all face detailing and the version where person one gets a face-skin-only pass while person two gets a full head re-render. Same node, wildly different control.
The three inputs that do the work
cfg- Classifier-Free Guidance scale for the inpaint sampling. Default is 1.0, which means no guidance at all. That's not a mistake: it's tuned for distilled/turbo models where CFG over 1 fights the model. If you're on a non-distilled checkpoint and faces come out washed out or low-contrast, this is the dial - 1.5–3.0 fixes paleness, 4.0–7.0 is standard for regular SD models. Go past 8 and you're asking for artifacts.negative_prompt- text that's encoded and merged with whatever negative conditioning you feed Person Detailer. If you connect no negative at all, this text alone becomes the negative. It's the obvious home for "blurry, washed out, pale, low contrast, extra fingers, deformed hands" - the standard inpaint-artifact suppressors from the inpainting playbook.denoise_gradient/denoise_gradient_mode- a center-to-edge falloff for denoise. Set 0 and the whole mask gets uniform denoise (default). Crank to 0.5 and the middle of the mask gets full denoise while edges stay close to the original pixels, which kills the hard seam you get when an inpainted region doesn't blend with untouched surroundings. Modes:linear(smoothest, best default),radial(good for round face masks),smooth(follows the exact mask shape - the one to pick for body parts and accessories).
Per-slot configuration
This is where the node earns its keep. Each reference row (1–5 plus generic) gets four settings:
reference_N_mask_type-face(skin only),head(face + hair, the default),body,hair,facial_skin,eyes,mouth,neck,accessories, oraux(body-part masks from a detector). Yes, you can detail one person's eyes and another person's whole body in the same pass.reference_N_rounds- number of inpaint passes for that slot. Each round re-encodes the previous result (latent cycling).reference_N_detail_daemon- toggles Detail Daemon sigma manipulation for that slot specifically.reference_N_ref_index- which reference (1–10) this row points at, so rows can be remapped if your Person Selector is set up with more references than slots.
For progressive refinement, the two global strings matter: denoise_progression and steps_progression. Pipe-separated values, one per round - 0.5|0.3 as denoise and 6|4 as steps gives you a strong first pass then a gentle refinement pass, which is the classic fix for faces that come out over-detailed or plastic-looking. If a slot has rounds of 1, progression is ignored and Person Detailer's global values win.
Installing and wiring
It ships with the FVMtools pack - install once, every node is there:
cd ComfyUI/custom_nodes
git clone https://github.com/ping1979ping/comfyui-FVMtools
No extra Python deps for this one (numpy's already in ComfyUI). Wire it up: Inpaint Options' single inpaint_options output → Person Detailer's inpaint_options input. That's the whole job - it doesn't touch the image itself.
The trap
The defaults hide a footgun: denoise_gradient at 0 with cfg at 1.0 means your inpaint pass runs with zero guidance and a hard-edged mask. That's fine on a turbo model at low denoise, but the moment someone runs this on Flux or SDXL and wonders why faces look washed out or seams show, these two sliders are the answer. Bump CFG to ~4, add a gradient of 0.3–0.5, and the same workflow suddenly looks like a different pack. Start there before you blame the model.
Inputs (32)
| Name | Type | Default | Description |
|---|---|---|---|
| cfg | FLOAT | 1.01–30 | Classifier-Free Guidance scale. Controls how strongly the sampler follows the prompt vs. generating freely. Higher values = more contrast and prompt adherence, but can oversaturate. Recommended values: 1.0 — no guidance (default, best for distilled/turbo models) 1.5-3.0 — light guidance, reduces paleness 4.0-7.0 — standard guidance for non-distilled models 8.0+ — strong guidance, risk of artifacts |
| negative_prompt | STRING | Additional negative prompt text for inpainting. This is encoded and combined with the negative conditioning input on the Person Detailer node. If no negative conditioning is connected, this text alone is used as negative. Useful for suppressing common inpaint artifacts: 'blurry, washed out, pale, low contrast' 'extra fingers, deformed hands, bad anatomy' Leave empty to use only the connected negative conditioning. | |
| denoise_gradient | FLOAT | 0.00–1 | Center-to-edge denoise falloff during sampling. Creates a gradient denoise mask: full denoise at the center of the masked region, fading toward the edges. 0.0 = uniform denoise everywhere (default) 0.3 = gentle gradient (edges stay closer to original) 0.5 = moderate gradient (recommended starting point) 1.0 = full gradient (edges almost untouched by sampling) Uses ComfyUI's native denoise_mask — the sampler blends with the original at every step, proportional to the gradient value. |
| denoise_gradient_mode | COMBO | linear | Gradient distribution shape for denoise_gradient. linear — USD Upscale style linear ramp from mask edge inward. Smoothest, best for most cases. Reaches full denoise quickly. radial — circular falloff from mask centroid outward. Good for roughly circular masks like faces. smooth — follows the exact mask shape using distance transform. Best for irregular masks (body parts, accessories). |
| mask_fill_holes | BOOLEAN | true | Fill holes in masks before inpainting (closes gaps in segmentation) |
| context_expand_factor | FLOAT | 1.201–3 | Expand crop region beyond mask bbox by this factor (1.0 = tight crop) |
| output_padding | INT | 320–128 | Additional padding around crop region in pixels |
| denoise_progression | STRING | Global per-round denoise override for ALL slots (applied when rounds > 1). Pipe-separated values, one per round. Examples: 0.5|0.3 — round 1: denoise 0.5, round 2: denoise 0.3 0.6|0.4|0.2 — 3 rounds with decreasing denoise 0.5|0.2 — strong first pass, gentle refinement If empty: PersonDetailer's global denoise is used for all rounds. If fewer values than rounds: last value repeats. If more values than rounds: extra values are ignored. | |
| steps_progression | STRING | Global per-round steps override for ALL slots (applied when rounds > 1). Pipe-separated values, one per round. Examples: 6|4 — round 1: 6 steps, round 2: 4 steps 8|6|4 — 3 rounds with decreasing steps 10|4 — thorough first pass, quick refinement If empty: PersonDetailer's global steps are used for all rounds. If fewer values than rounds: last value repeats. If more values than rounds: extra values are ignored. | |
| reference_1_ref_index | INT | 11–10 | Which reference (1-10) this row configures. Default: row 1 → reference 1. Person Selector supports up to 10 references. |
| reference_1_mask_type | COMBO | head | Mask type for this row. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| reference_1_rounds | INT | 11–10 | Number of inpaint passes for this row. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| reference_1_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for this row. Enhances detail preservation during inpainting. |
| reference_2_ref_index | INT | 21–10 | Which reference (1-10) this row configures. Default: row 2 → reference 2. Person Selector supports up to 10 references. |
| reference_2_mask_type | COMBO | head | Mask type for this row. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| reference_2_rounds | INT | 11–10 | Number of inpaint passes for this row. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| reference_2_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for this row. Enhances detail preservation during inpainting. |
| reference_3_ref_index | INT | 31–10 | Which reference (1-10) this row configures. Default: row 3 → reference 3. Person Selector supports up to 10 references. |
| reference_3_mask_type | COMBO | head | Mask type for this row. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| reference_3_rounds | INT | 11–10 | Number of inpaint passes for this row. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| reference_3_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for this row. Enhances detail preservation during inpainting. |
| reference_4_ref_index | INT | 41–10 | Which reference (1-10) this row configures. Default: row 4 → reference 4. Person Selector supports up to 10 references. |
| reference_4_mask_type | COMBO | head | Mask type for this row. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| reference_4_rounds | INT | 11–10 | Number of inpaint passes for this row. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| reference_4_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for this row. Enhances detail preservation during inpainting. |
| reference_5_ref_index | INT | 51–10 | Which reference (1-10) this row configures. Default: row 5 → reference 5. Person Selector supports up to 10 references. |
| reference_5_mask_type | COMBO | head | Mask type for this row. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| reference_5_rounds | INT | 11–10 | Number of inpaint passes for this row. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| reference_5_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for this row. Enhances detail preservation during inpainting. |
| generic_mask_type | COMBO | head | Mask type for generic (unmatched) slot. face=skin only, head=face+hair, body=full body, aux=body-part SEGS from detector |
| generic_rounds | INT | 11–10 | Number of inpaint passes for generic slot. Each round re-encodes the previous result (latent cycling). Use denoise_progression/steps_progression to control per-round values. 1 = single pass (default), 2-3 = progressive refinement |
| generic_detail_daemon | BOOLEAN | true | Enable Detail Daemon sigma manipulation for generic slot. Enhances detail preservation during inpainting. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| inpaint_options | INPAINT_OPTIONS | — |