APNext Sharpen FX
In-graph unsharp mask for your renders
- images
- image
Sometimes a render comes out a touch soft - after an upscale, after a VAE decode that eats fine detail, or just because the model played it safe. APNext Sharpen FX is the in-graph fix so you don't have to round-trip the image through Photoflop. It's one of the image-effect nodes in dagthomas's "SDXL Auto Prompter" pack (which, despite the name, is a big grab-bag of prompt tools and post-processing FX), and it does exactly one thing well: sharpen an image tensor.
It's not doing anything exotic - it's the same family of sharpening you'd find in any photo editor - but having it live in the ComfyUI graph means you can sharpen conditionally, between passes, or right before saving, all without leaving your workflow. That's the whole pitch, and it's a good one.
How it works
It takes your decoded IMAGE and runs a sharpening pass on it, then hands back the sharpened image. Three methods are on offer via the method dropdown: unsharp_mask (the default and the one you want 90% of the time - the classic detail-boost that works by subtracting a blurred copy), high_pass (a harsher edge-frequency boost), and edge_enhance (leans into outlines). It's a pure tensor operation, so no model and no API key - it runs on whatever's already in your graph.
The inputs that matter
images- the image to sharpen. Wire this from your VAE Decode or upscaler output.strength(default 1, range 0–5) - how hard it sharpens. 1 is a sane default; push toward 2–3 for a soft upscale, and back off if edges start to crunch.radius(default 1, range 0.1–10) - the size of the detail it acts on. Small radius = fine texture; large radius = broad local contrast. For most renders 1–2 is right.threshold(default 0, range 0–255) - the protect-the-flats control. At 0 it sharpens everything, including noise in smooth skies and skin. Nudge it up and low-contrast areas are left alone while edges still get sharpened - this is the setting that keeps sharpening from amplifying grain.method- start withunsharp_mask.
The single output is image, which you feed onward to a Save Image, another FX node, or a compositing step.
How to install it
ComfyUI Manager: search comfyui_dagthomas, install, restart. Manual:
cd ComfyUI/custom_nodes && git clone https://github.com/dagthomas/comfyui_dagthomas
cd comfyui_dagthomas && pip install -r requirements.txt
then restart. The requirements.txt installs the whole pack's stack - blend-modes, color_matcher, scipy for the FX nodes, plus openai, anthropic, google-generativeai, transformers and decord for the LLM and video nodes the same repo ships. The FX nodes really only lean on the imaging libraries; decord is the dependency most likely to fail a build, and if it does, the FX and prompt nodes generally still load.
Where people get burned
- Over-sharpening. High
strengthplus smallradiusgives you that gritty, over-processed halo look. If edges are getting bright outlines, drop strength or raise radius. - Sharpening noise. With
thresholdat 0, any grain in flat areas gets crunched up along with the detail you wanted. Raise the threshold to protect skies and skin. - Order matters. Sharpen after upscaling, not before - sharpening first just gives the upscaler crunchy input to enlarge. And sharpen last, right before saving, so later steps don't blur your work back out.
high_passandedge_enhanceare aggressive. They're there for stylistic bite, not general cleanup. For "make this render a little crisper," stick withunsharp_mask.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| strength | FLOAT | 1.00–5 | — |
| radius | FLOAT | 1.00.1–10 | — |
| threshold | INT | 00–255 | — |
| method | COMBO | unsharp_mask | 3 options: unsharp_mask, high_pass, edge_enhance |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |