๐ผ> Sharpen
A maskable sharpening filter โ note the floor is 1, not 0
- image
- mask_opt
- image
A slightly soft VAE decode, an upscaled image that lost some crispness, or just a generation that could use a touch more edge definition - that's the job for this node. One knob, one optional mask, nothing fancier.
How it works
Where most of this pack's adjustment nodes (Brightness, Contrast, Saturation) run 0โ2 with 1 as the neutral midpoint, Sharpen is different: its range is 1 to 5, with 1 as the floor. That's not a typo in the schema - it means this node only ever sharpens or does nothing. There's no way to soften an image through Sharpen; that's a separate job handled by this pack's own Blur node.
The optional mask works the same way it does across the rest of the post-processing suite: leave it disconnected and sharpening applies globally, or feed one in to confine the effect - a common use being sharpening just the eyes or a texture-heavy area without also sharpening noise in flat background regions, where over-sharpening tends to be most visible and least flattering.
The inputs and outputs that matter
image(IMAGE) - required.sharpen(FLOAT, 1โ5, step 0.01, default 1) - 1 is off, higher values sharpen more. There's no soften direction on this slider.mask_opt(MASK, optional) - confine the effect to a region.imageout.
How to install it
Via ComfyUI Manager: search "yanc" or "ComfyUI_yanc" and install, then restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/ALatentPlace/ComfyUI_yanc
then restart ComfyUI. No extra dependencies or model downloads.
Common issues & troubleshooting
Edges get visible white/dark halos. That's the classic oversharpen artifact, and it shows up fast as you climb toward the top of this node's 1โ5 range on output that's already reasonably detailed. Moderate values - roughly 1.2 to 1.8 - cover most real correction needs; if you need more than that to make an image look acceptable, the problem is more likely upstream (a soft base generation, an aggressive upscaler) than something this filter should be fixing.
You expected a value below 1 to soften the image and it did nothing. The range genuinely starts at 1 - there's no soften direction here. Use this pack's Blur node instead if you want less detail, not more.
Noise in flat areas gets sharpened along with real detail. Sharpening amplifies whatever's already there, noise included, and it's most visible in smooth regions like skies or skin. If that's happening, confine the effect with mask_opt to just the areas that actually need it - an eye, a piece of fabric, a texture-heavy prop - rather than applying it globally.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | โ | |
| sharpen | FLOAT | 1.001โ5 | โ |
| mask_optopt | MASK | โ |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | โ |