EBU Scaling Tile
The tile-size calculator Ultimate SD Upscale is missing
- tile_width
- tile_height
If you've ever wired up Ultimate SD Upscale (USDU) in ComfyUI, you know the ritual: it needs a tile size, you don't know what to put, and every workflow you download has a different magic number. EBU Scaling Tile exists to make that number computable instead of mystical. You give it your upscaled image dimensions and a few divisor knobs, and it returns a tile_width and tile_height ready to plug straight into USDU.
The pack's README is explicit about the design intent: "Use this with the excellent Ultimate SD Upscale custom node." This node is the calculator; USDU is the worker.
How it works
The logic is orientation-aware. If the image is taller than wide (profile), it uses the profile_width_div_by and profile_height_div_by divisors; otherwise it uses the landscape_* pair. Each dimension is divided by its divisor, then the padding values are added.
The defaults tell you the intended shape: portrait images get width/1 and height/3 - full width, a third of the height - while landscape gets width/2 and height/2, i.e. four roughly square tiles. That's a sensible default for the tall-images-first reality of most upscale pipelines.
The tile_width_padding / tile_height_padding inputs (default 0) exist because integer division loses pixels. Bump them up a bit and you compensate for the rounding gaps that otherwise show up as seams between tiles. The classic USDU advice is that some overlap padding is better than none.
Inputs and outputs
- upscaled_image_width / upscaled_image_height (INT) - the dimensions of the image you're tiling. Wire these from EBU Scaling Resolution's
upscaled_width/upscaled_heightoutputs and the whole upscale front-end becomes self-consistent. - profile_width_div_by / profile_height_div_by (FLOAT, default 1 and 3) - portrait tiling divisors.
- landscape_width_div_by / landscape_height_div_by (FLOAT, default 2 and 2) - landscape tiling divisors.
- tile_width_padding / tile_height_padding (INT, default 0) - extra pixels per tile to absorb rounding.
Outputs are just tile_width and tile_height (INT). Those two go into USDU's tile size fields.
Why tiling matters
On a 6–8 GB card, running diffusion over a full 2x-upscaled 4K image is a memory wall. Tiling splits the job into pieces that fit, and with ControlNet Tile feeding the original image as a condition, each tile stays faithful to the source instead of drifting into its own little world. That's the "arbitrary output size on limited VRAM" path the upscaling community landed on. This node doesn't do the tiling - it just makes sure your tile sizes aren't nonsense.
Installing
Standard EBU Workflow install: no deps beyond Python stdlib, no models. ComfyUI Manager (search "EBU Workflow"), or:
cd ComfyUI/custom_nodes
git clone https://github.com/burnsbert/ComfyUI-EBU-Workflow
then restart. You'll also need Ultimate SD Upscale itself (ComfyUI Manager: "Ultimate SD Upscale") - this node is useless without it.
Gotchas
- Divisibility is a real concern. An 1152-wide image with
width/2gives 576 - fine. But a 5:3 divisor on an odd width will give you a non-multiple-of-8 tile, which some pipelines tolerate and others complain about. Check the result before it hits USDU. - The orientation check is
height > width- exactly square images take the landscape path. - These divisors are per-orientation, so tuning portrait tiling doesn't affect landscape. That's the point, but it means you have four knobs to reason about, not one.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| upscaled_image_width | INT | 768 | — |
| upscaled_image_height | INT | 1024 | — |
| profile_width_div_by | FLOAT | 1.001–20 | — |
| profile_height_div_by | FLOAT | 3.001–20 | — |
| landscape_width_div_by | FLOAT | 2.001–20 | — |
| landscape_height_div_by | FLOAT | 2.001–20 | — |
| tile_width_padding | INT | 0 | — |
| tile_height_padding | INT | 0 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| tile_width | INT | — |
| tile_height | INT | — |