Nodes/ComfyUI-SUPIR/SUPIR Conditioner
ComfyUI Node Runs on cloud

SUPIR Conditioner

Turning your prompts (and optional captions) into what the sampler needs

By kijai·Created 2 years ago·Updated 3 months ago· 2,303
SUPIR Conditioner
  • SUPIR_model
  • latents
  • positive
  • negative
positive_prompthigh quality, detailed
negative_promptbad quality, blurry, messy
captions

This is SUPIR's answer to a CLIP Text Encode node, except it's built specifically for the restoration use case and it can optionally fold in an image caption on top of your prompt. If you've used SUPIR's SUPIR_Upscale all-in-one node and wondered where the a_prompt/n_prompt fields went when you moved to the split-node workflow - they're here.

What it does

It takes your positive and negative prompt text, the SUPIR model, and the latents you're about to sample, and produces the two conditioning objects the sampler actually consumes. The defaults - "high quality, detailed" for positive, "bad quality, blurry, messy" for negative - are generic restoration-flavored prompts, and honestly most people leave them close to that; SUPIR's job is repairing the image, not generating new content from your prompt, so elaborate prompting matters far less here than it would for a text-to-image checkpoint.

The optional caption input is the more interesting feature. If you feed a single caption, it just gets appended to the positive prompt - an easy way to steer restoration with a one-line description of the subject ("a photo of a mountain landscape" nudges it away from inventing something else). It gets more capable with multiple images or a tiled workflow: feed a list of captions matching your batch size and each image gets its own caption, or feed a list matching your tile count (paired with the SUPIR_tiles node) and each tile gets steered individually.

Inputs and outputs that matter

Required: SUPIR_model and latents (from your encode/first-stage step), plus positive_prompt and negative_prompt as multiline text fields with the defaults described above.

Optional: captions - a string input, single caption or list, as covered above.

Outputs: positive and negative, typed as SUPIR_cond_pos and SUPIR_cond_neg respectively - these are SUPIR-specific conditioning types, not the standard ComfyUI CONDITIONING type, so they only plug into SUPIR_sample's matching inputs and nowhere else in a normal graph.

How to install it

ComfyUI Manager: search "SUPIR", install, restart. Manual install:

cd ComfyUI/custom_nodes
git clone https://github.com/kijai/ComfyUI-SUPIR
pip install -r ComfyUI-SUPIR/requirements.txt

Portable: python_embeded\python.exe -m pip install -r .... Needs a reasonably recent PyTorch; xformers optional. This node itself doesn't touch the model files - it needs SUPIR_model from an upstream loader, which needs a SUPIR checkpoint and an SDXL checkpoint sitting in ComfyUI/models/checkpoints.

Common issues

The most common confusion is expecting prompt text to do more than it does. SUPIR isn't generating a scene from your words - it's restoring an existing image, so the prompt mostly nudges tone and detail level rather than composition. If you're writing an elaborate prompt hoping to steer specific content into the output, that's fighting the tool; you'll get better results adjusting control_scale and restore_cfg on the sampler than piling text on here.

If you're using the captions list feature and getting a mismatch error or captions applying to the wrong image/tile, count carefully - the list length has to match either your image batch size or your tile count exactly, there's no partial-match fallback. And remember the caption-per-tile path is explicitly flagged as a work-in-progress feature in the companion SUPIR_tiles node, so treat it as something to experiment with rather than something to depend on for a production pipeline.

CategorySUPIR

Inputs (5)

NameTypeDefaultDescription
SUPIR_modelSUPIRMODEL
latentsLATENT
positive_promptSTRINGhigh quality, detailed
negative_promptSTRINGbad quality, blurry, messy
captionsoptSTRING

Outputs (2)

NameTypeDescription
positiveSUPIR_cond_pos
negativeSUPIR_cond_neg