Nodes/Difforum/Difforum · Upscale (2K / 4K)
ComfyUI Node

Difforum · Upscale (2K / 4K)

Get the clip to 2K without inventing a new one

By chillithebillis·Created 4 months ago·Updated 11 days ago· 10
Difforum · Upscale (2K / 4K)
  • frames
  • upscale_model
  • frames
  • info
◄target2K (2048 long edge)►
◄methodlanczos►
◄sharpen0.15►
◄chunk16►
◄model_useauto (when enlarging 2x or more)►

You rendered at 640 or 768 because rendering at 2K would have taken all night, and now you need a deliverable. Difforum · Upscale is the last block in the template chain for exactly that, and it's deliberately boring: it's a resize, with an optional model in front of it.

That distinction matters more than people think. There are two different jobs hiding under the word "upscale" - adding pixels to an image that already has the detail, and adding detail that was never there. An ESRGAN-family model like RealESRGAN, 4x-UltraSharp or Remacri is firmly the first kind: it sharpens and interpolates, and it cannot invent a face. For a render you made at a lower resolution, that's the correct and cheap answer, and it's why plain Lanczos has quietly come back into fashion rather than being an embarrassment. If you want a model to hallucinate pores and fabric weave, that's SeedVR2 / SUPIR territory and a different node entirely.

What it does

Each frame goes through, in chunks of chunk (16 by default), optionally through ImageUpscaleWithModel with whatever you wired into upscale_model, then gets resized to the exact target with your chosen method, then a light unsharp pass. Sizes are forced even and the aspect is kept, so a 16:9 render stays 16:9 and both dimensions are codec-legal. There's a progress bar and it checks for interrupt between chunks, so cancelling actually cancels.

target is the final size: 2K (2048 long edge), 1080p, 1440p, 4K, or a plain multiplier (x1.5, x2, x4). Note "long edge" means the long edge - a vertical clip gets 2048 on the tall side, which is the correct behaviour and still surprises people. Without an upscale_model connected you get a clean resize and nothing else, which is a legitimate delivery choice, not a broken install.

method is the resize filter and lanczos (the default) is the sharpest of the four. bicubic and bilinear are softer, area is the one for downscaling without aliasing. sharpen at 0.15 is a whisper and it's the right default; push it past about 0.5 and you'll see halos on high-contrast edges that get worse once a video codec compresses them.

Outputs are frames and info - the latter reports frame count, source size, target size, and whether a model was used, which is the line to check when someone asks what you delivered.

Install

ComfyUI Manager → search Difforum, or:

cd ComfyUI/custom_nodes
git clone https://github.com/chillithebillis/Difforum.git difforum

Restart. The node itself needs nothing but numpy - the upscale model is the only extra, and it's a normal ComfyUI model file. Drop RealESRGAN_x4plus.pth, 4x-UltraSharp.pth or 4x_foolhardy_Remacri.pth into ComfyUI/models/upscale_models/ and load it with the core Load Upscale Model node into upscale_model. The pack's templates put this block after Restyle and Look Mix, before the output - copy that ordering.

Where people get burned

The one that catches everybody in video work: a per-frame image upscaler has no idea what the frame before it did. Feed it fine repeating texture - wallpaper, chain-link, fabric weave - and consecutive frames resolve that pattern differently, so it shimmers. It's the single most reported failure in video upscaling and the reason temporally aware models exist. This node is fine for the case it's built for (a clean AI render that just needs more pixels) and the wrong tool for restoring genuinely low-resolution live footage.

Second: upscaling bakes in artifacts. If a face is wrong or an edge is smeared, 4x-UltraSharp will faithfully make a bigger, crisper wrong face. Fix it at render size, re-render those frames (that's what Render Options' start_frame / end_frame chunking is for), then upscale.

Third and most mundane: VRAM. chunk is your lever - the chunks exist so a long clip doesn't have to sit in memory all at once, so if you're failing at 2K with a 4x model, drop chunk to 4 before you start blaming the model. And if you were only exporting a preview, bypass the node or its whole group: the pack's Workflow Switches treat Upscale as a pass-through block, so switching it off leaves the rest of the graph running at render size instead of erroring. The info line is where you confirm which of the two you got.

CategoryDifforum/7 · Post

Inputs (7)

NameTypeDefaultDescription
framesIMAGEThe clip to deliver.
targetCOMBO2K (2048 long edge)Final size. 2K = 2048 on the long edge; xN = multiply.
methodCOMBOlanczosResize filter after the model. lanczos is sharpest.
sharpenFLOAT0.150–1.5Light unsharp after resizing.
chunkINT161–256Frames per model pass; lower it if VRAM runs out.
upscale_modeloptUPSCALE_MODELLoad Upscale Model (RealESRGAN, 4x-UltraSharp, Remacri...). Empty = resize only.
model_useoptCOMBOauto (when enlarging 2x or more)auto: the model runs only when the clip grows 2x or more (640 -> 2K); a clip that is already large (1280 -> 2K) is resized and sharpened, many times faster. always / never force it.

Outputs (2)

NameTypeDescription
framesIMAGE—
infoSTRING—