Nodes/ComfyUI-Replicate/Replicate fofr/ultrapixel
ComfyUI Node

Replicate fofr/ultrapixel

Ultra-high-res image synthesis via API

By replicate·Created 2 years ago·Updated 2 years ago· 206
Replicate fofr/ultrapixel
  • canny_control_image
  • IMAGE
prompt
width2048
height2048
stage_b_steps10
stage_b_cfg1.10
stage_c_steps20
stage_c_cfg4.00
controlnet_weight0.70
output_formatwebp
output_quality80
seed
force_rerunfalse

UltraPixel is a text-to-image model built for one thing: generating genuinely large images - think 2K, 4K, up to 5120px on a side - natively, in one pass, rather than making a small image and upscaling it afterward. This node runs it through Replicate's cloud, so you get those huge canvases without needing the VRAM to hold a multi-megapixel latent yourself. It's a Replicate node: account, REPLICATE_API_TOKEN, pay-per-run, nothing downloaded locally.

Worth being honest about the model's reputation. UltraPixel landed in mid-2024 with big "ultra-high-resolution synthesis to new peaks" claims and a skeptical reception - a chunk of the community rolled its eyes at demos posted before the code was out. It's a niche tool, not a daily driver. But for a straight shot at a large coherent image without an upscaling pipeline, it does the job.

How it works

The parameter names give the architecture away: stage_b_steps, stage_c_steps, stage_b_cfg, stage_c_cfg. That's the two-stage Stable Cascade design underneath. Stage C generates in a tiny, highly-compressed latent space (cheap, which is how it reaches high resolutions), and Stage B decodes that up into the full detailed image. UltraPixel is the method layered on top to push Cascade's ceiling into ultra-high-res territory. fofr packaged it onto Replicate so you can call it from a graph.

The inputs and outputs that matter

  • prompt - plain description of what you want.
  • width / height (both default 2048, up to 5120) - the payoff. This is where you set the big canvas.
  • stage_c_steps (20) and stage_c_cfg (4) - the main generation stage; the knobs that most affect the actual image.
  • stage_b_steps (10) and stage_b_cfg (1.1) - the decode/upscale stage; leave these near default unless you know what you're chasing.
  • canny_control_image (IMAGE) + controlnet_weight (0.7) - optional Canny ControlNet, if you want to constrain the composition to an edge map.

seed, output_format, and output_quality do the usual; force_rerun forces a fresh generation. Output is one IMAGE.

How to install it

One install covers every Replicate node.

  • ComfyUI Manager: search ComfyUI-Replicate, install, restart.
  • Manual:
    cd ComfyUI/custom_nodes
    git clone https://github.com/replicate/comfyui-replicate
    cd comfyui-replicate
    pip install -r requirements.txt
    
    then restart.

Nothing lands on your GPU - the model runs on Replicate's servers, so the only install is the replicate Python client. Set your token before launching ComfyUI: export REPLICATE_API_TOKEN="r8_..." (replicate.com/account/api-tokens). No token, no runs.

Common issues & troubleshooting

Auth error on the first run. The token isn't set. REPLICATE_API_TOKEN must be in the environment before ComfyUI launches - set it, restart.

It's slow. Big images cost compute, and a hosted model can cold-boot. A 4K generation is not a snappy operation; that's the trade for not needing the hardware yourself.

Output looks soft or over-smooth at high res. Push stage_c_steps up a bit and make sure your prompt actually describes fine detail - a big empty canvas magnifies vagueness. The Stage B defaults are tuned; changing them rarely helps.

Same result on a re-run. Replicate returned a cached prediction for identical inputs. Change the seed or set force_rerun.

Remember it bills. Each run is a paid Replicate prediction, and large resolutions are on the pricier end. Fine for the occasional big render, not for spraying dozens.

CategoryReplicate

Inputs (13)

NameTypeDefaultDescription
promptoptSTRING
widthoptINT20481024–5120
heightoptINT20481024–5120
stage_b_stepsoptINT101–50
stage_b_cfgoptFLOAT1.100.1–10
stage_c_stepsoptINT201–50
stage_c_cfgoptFLOAT4.000.1–10
canny_control_imageoptIMAGE
controlnet_weightoptFLOAT0.700.1–1
output_formatoptCOMBOwebp3 options: webp, jpg, png
output_qualityoptINT800–100
seedoptINT
force_rerunoptBOOLEANfalse

Outputs (1)

NameTypeDescription
IMAGEIMAGE