๐ฎ Iterative Upscale with Models Node (Yaser)
Upscale with the model that matches your scale factor โ in one node
- image
- model1x
- model2x
- model4x
- model8x
- upscaled_image
Upscaling has exactly one decision at its core, and it's not "which node": it's do you want more pixels, or more invented detail? As the KB's upscaling essay hammers home, those are two different jobs. This node - Iterative Upscale with Models Node (Yaser) - is firmly in the "more pixels" camp, and it exists to make one thing painless: picking the right upscaler for the size you're targeting, without a pile of upscale nodes cluttering the graph.
The idea is simple. You load up to four upscale models (a 1x, a 2x, a 4x, an 8x - ESRGAN-family models like 4x-UltraSharp or Remacri are the usual suspects, sitting in models/upscale_models/). You set a scale_factor dropdown to 1, 2, 4, or 8. The node hands your image to the model that matches your chosen factor, runs it through ComfyUI's tiled upscaling, and hands you the result.
How it actually works (and where the name overpromises)
The mechanism is a direct port of ComfyUI's core ImageUpscaleWithModel logic. The image is split into tiles (512px, with 32px overlap), each tile is run through the upscale model, and the tiles are blended back together with tiled_scale - which is what keeps an 8x pass from blowing up your VRAM. There's also genuine OOM protection: if the GPU throws an out-of-memory error mid-pass, the code halves the tile size and retries, all the way down to 128px tiles before it gives up. On a small card that's the difference between "works, slowly" and "crash."
Now the honesty part: despite the name, it is not iterative. It doesn't chain a 2x model into another 2x model to reach 4x, and it doesn't do the multiple-refine-passes thing that name implies. It picks one model based on scale_factor and runs it once. The scale_factor dropdown only selects which model - it does not force the output to that scale. The model determines the output size. Feed a 4x model with scale_factor set to 2, and you get a 4x image anyway. So set the dropdown to match the model you're loading, and load models whose native scale matches what you want out.
The inputs that matter
- image - what you're upscaling.
- scale_factor - 1, 2, 4, or 8. This picks which model input is used.
- model1x / model2x / model4x / model8x - four
UPSCALE_MODELslots. They're all required, which is the mildly annoying part: you must wire all four, even if you only ever use one. Wire the same model into multiple slots if you have to.
Output is upscaled_image - same IMAGE type, just bigger.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/YaserJaradeh/comfyui-yaser-nodes.git
restart ComfyUI, or ComfyUI Manager โ "Yaser-nodes". Then drop your upscaler .safetensors/.pth files into ComfyUI/models/upscale_models/.
Where people get burned
- The four required model slots. A workflow loads fine but nothing runs until all four are connected. Annoying, but harmless.
- The model, not the dropdown, decides the output size. This is the #1 surprise. Match them.
- It's a pixel upscaler, not a detail generator. If you're trying to add detail that was never in the source (the SeedVR2/SUPIR job, per the KB), this isn't it - this just makes the image bigger, cleanly. For 4K print work on a small card it's a solid, memory-safe workhorse.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | โ | |
| scale_factor | COMBO | 4 options: 1, 2, 4, 8 | |
| model1x | UPSCALE_MODEL | โ | |
| model2x | UPSCALE_MODEL | โ | |
| model4x | UPSCALE_MODEL | โ | |
| model8x | UPSCALE_MODEL | โ |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| upscaled_image | IMAGE | โ |