ComfyUI Node

Demofusion

DemoFusion's gateway node — giant images, giant downloads, zero training

By deroberon·Created 3 years ago·Updated 2 years ago· 88
Demofusion
    • IMAGE
    ckpt_namestabilityai/stable-diffusion-xl-base-1.0
    positive
    negative
    width2048
    height2048
    inference_steps40
    cfg7.5
    seed522

    DemoFusion is the 2023 paper with the best title in the business: "Democratising High-Resolution Image Generation With No $$$." The pitch is that SDXL can generate far beyond its 1024px training resolution if you feed it smartly, so Ruoyi Du and the PRIS-CV group built a training-free pipeline that progressively upscales while it samples. This node is the reference wrapper for that technique - and the first thing to know is that it's not the variant you'll actually want to use.

    The catch is ckpt_name. On the plain Demofusion node that field is a plain text string defaulting to stabilityai/stable-diffusion-xl-base-1.0 - a Hugging Face repo id, not a file in your ComfyUI folder. On first run the node calls from_pretrained and drags a whole diffusers-format SDXL off the hub. Early threads about this pack reported tens of gigabytes of downloads, and nobody's 30GB drive thanked them. That's exactly why the pack's second node, Demofusion From Single File, exists. Check its page - it's the one you want.

    What the node actually does is the interesting part. It samples at SDXL's native resolution first, then upscales the latents roughly 2x per stage toward your target size. At each stage it re-injects the upscaled previous result via a "skip residual" while denoising, and runs a windowed "dilated sampling" pass - the code moves overlapping patches with a 64px stride, batches them four at a time, and gaussian-blends the overlaps so seams don't show. All of that machinery, the cosine blending schedules and the sigma and the stride, is hardcoded here. You don't tune the technique; you just set size, prompts, and the sampler knobs and let it grind. The node returns a single IMAGE - the final, highest-resolution frame - and throws away the progressive previews the paper brags about. Wire IMAGE into PreviewImage or SaveImage and that's the whole workflow.

    The inputs that matter are width and height, floored at 2048 (2x SDXL native) and capped at 4096 in steps of 64. The author only ever validated square outputs at 2048 and 3072, so treat non-square as experimental. inference_steps defaults to 40 and cfg to 7.5 - sane starting points, not rules.

    Install is standard: in ComfyUI Manager search "demofusion-comfyui", or run git clone https://github.com/deroberon/demofusion-comfyui inside ComfyUI/custom_nodes and restart. On first import the pack auto-pips in diffusers~=0.21.4 and matplotlib if they're missing - and that pinned, ancient diffusers is a genuine gotcha, since it can fight with other custom nodes expecting a newer version in the same environment. It's also CUDA-only and loads everything fp16.

    The honest verdict: this is a reference implementation and a curiosity. The author calls it their first custom node, warns it's under development, and the pack lands in ComfyUI's "tests" category - your first clue about its ambitions. It's slow, about a minute per 2048px image on a 4090, and VRAM hungry; the README says 18GB+, and real users measured ~12GB at 2048 on a 4090, which puts 12GB cards on the wrong side of the line. Background detail gets indistinct at the high end and seams can appear. It's a fun slice of 2023 history and a genuinely clever no-training approach, but by 2026 the community moved on to hi-res fix, DeepShrink, and tiled upscaling for the same job. Use it to play with the technique; use something else if you have a deadline.

    Categorytests

    Inputs (8)

    NameTypeDefaultDescription
    ckpt_nameSTRINGstabilityai/stable-diffusion-xl-base-1.0
    positiveSTRING
    negativeSTRING
    widthINT20482048–4096
    heightINT20482048–4096
    inference_stepsINT401–100
    cfgFLOAT7.51–20
    seedINT522

    Outputs (1)

    NameTypeDescription
    IMAGEIMAGE