ClownGuide_FrequencySeparation
Apply a style guide to low or high detail bands
- guides
- mask
- guides
If you've ever done frequency separation in Photoshop - splitting an image into a soft low-frequency layer (color, broad shapes) and a crisp high-frequency layer (texture, edges) so you can retouch each independently - this is the same idea, applied to a RES4LYF style guide. ClownGuide FrequencySeparation lets a style guide act on the low band, the high band, or a weighted mix, instead of hitting everything at once.
This is a modifier node, not a standalone guide. It sits in the guide chain: it requires an incoming GUIDES bundle and hands back a modified GUIDES. So the pattern is: build an AdaIN-style guide, run it through FrequencySeparation to decide which detail band it affects, then pass the result to the sampler. It's a precision tool for when a plain style transfer is bleeding into detail you wanted to keep, or vice versa.
How it works
The node splits the guide's influence into frequency bands using a blur - Gaussian or median, with per-window variants - and then lets you weight the low-pass and high-pass parts separately. Weight the low band and leave the high band low, and you transfer broad color and form while preserving your generation's own texture. Do the opposite and you borrow the reference's fine texture without disturbing your composition's palette. The apply_to control names which style operation the separation is applied to (AdaIN).
The inputs and outputs that matter
guides(GUIDES) - the incoming guide chain this modifies. Required; this node needs something to act on.method(enum:gaussian,gaussian_pw,median,median_pw; defaultmedian) - how the low/high split is computed. Median tends to preserve edges better; Gaussian is smoother.lowpass_weight/highpass_weight(FLOAT, default1each) - the heart of the node. These decide how much of the guide lands on broad tone versus fine texture. Change these to steer the split.sigma,kernel_size,inner_kernel_size,stride- the blur's shape and scale; the defaults are sensible starting points, adjust only if the band split looks wrong.mask(MASK, optional) - confine the effect to a region.
Output is a guides (GUIDES) bundle for the sampler or the next modifier.
How to install it
ComfyUI Manager: search RES4LYF, install, restart. Manual: cd ComfyUI/custom_nodes && git clone https://github.com/ClownsharkBatwing/RES4LYF/, pip install -r requirements.txt in your venv (portable: embedded python's pip), restart, hard-refresh F5. Nested sampler menu: rgthree-comfy with "Auto Nest Subdirectories" on.
Common issues
The number-one mistake is wiring it up with nothing feeding its guides input. It's a modifier - no incoming guide means nothing to separate, and you'll get an error or a no-op. Build your style guide first, then chain this after it.
Beyond that, this is genuinely advanced and under-documented, like most of the pack's guide extensions. The band split behaves differently depending on method and the kernel settings, and there's no official table telling you which combination suits which model. Move lowpass_weight and highpass_weight first - they're the intuitive controls - and only touch the kernel parameters if the separation is obviously coarse or missing detail. Fixed seed, one change at a time. And if you're not already fighting a specific problem where a style guide is contaminating a detail band, you probably don't need this node at all; it's a scalpel for a specific cut, not a general improvement.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| apply_to | COMBO | AdaIN | 1 options: AdaIN |
| method | COMBO | median | 4 options: gaussian, gaussian_pw, median, median_pw |
| sigma | FLOAT | 3.00-10000–10000 | Low values produce results closer to the guide image. No effect with median. |
| kernel_size | INT | 81–11111 | Primary control with median. Set the Re___Patcher node to float32 or lower precision if you have OOMs. You may have them regardless at higher kernel sizes with median. |
| inner_kernel_size | INT | 21–11111 | Should be equal to, or less than, kernel_size. |
| stride | INT | 21–11111 | Should be equal to, or less than, inner_kernel_size. |
| lowpass_weight | FLOAT | 1.00-10000–10000 | Typically should be set to 1.0. Lower values may sharpen the image, higher values may blur the image. |
| highpass_weight | FLOAT | 1.00-10000–10000 | Typically should be set to 1.0. Higher values may sharpen the image, lower values may blur the image. |
| guides | GUIDES | — | |
| maskopt | MASK | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| guides | GUIDES | — |