Nodes/Wildcard Pipeline/WP Image Filter
ComfyUI Node

WP Image Filter

Stop the Run and Pick Which Images Get Upscaled

By DumiFlex·Created 7 months ago·Updated 3 days ago· 13
WP Image Filter
  • images
  • latent
  • masks
  • positive
  • negative
  • context
  • extra_1
  • extra_2
  • clip
  • wp_image_filter
  • images
  • latent
  • masks
  • positive
  • negative
  • positive_text
  • negative_text
  • context
  • extra_1
  • extra_2
  • picks
◄positive_text—►
◄negative_text—►

You queue a batch of eight, four are keepers, and the hi-res pass upscales all eight anyway. WP Image Filter ends that: it stops the run mid-graph, shows you what the first pass made, and only the images you click go on.

Two-pass generation - render at native resolution, then a second low-denoise pass at 1.5–2x for real detail - is still the backbone of anything above native size, because one high-res pass gives you tiling instead of pores. The annoying part was never the second pass. It was which images deserve it.

How it works

When the node runs it writes every image it was handed to ComfyUI's temp folder, fires a websocket event at the canvas, and waits, polling for your answer every 150 ms. The picker answers over an HTTP route, and the node slices everything wired through it down to your picks.

It's an input-list node, so when a Context Loop runs upstream, all N frames arrive in one call and land in one picker. A pick is a (frame, image) pair, which is why a two-wildcard sweep opens as a grid you click by row or column, not a flat wall of thumbnails.

And "everything follows the picks" is literal. Every other slot is aligned to the frames first (one item per frame), then anything batched like its frame's images - a latent's samples, a mask, a conditioning matching the batch - is sliced to match. Anything else, a prompt string, a Context, a single conditioning shared by the whole batch, is kept or dropped with its frame. The upscaler doesn't just get the right pixels, it gets the right prompt for them.

Pick nothing and hit Stop branch and you get ComfyUI's ExecutionBlocker on all eleven outputs: everything downstream is quietly skipped; the rest of the run finishes.

Inputs and outputs

images is the only required input, and it's what the picker shows. Wire only what you need; every input has a matching output. For the first-pass-to-upscaler hop:

  • latent - the first KSampler's output, so the second pass starts from the picks instead of re-encoding.
  • context - the WP Context of each frame. Because it travels with the frame, an Assembler after the filter only sees the prompts of the images you kept. Skip this and you get gorgeous images with someone else's prompt.
  • positive / negative and positive_text / negative_text - conditioning and raw strings, sliced the same way.
  • clip - optional and worth wiring: with it, a prompt you edit in the picker is re-encoded on the spot. Without it, an edit changes only the text and the image ignores you.

extra_1 and extra_2 are any-type slots for whatever else must stay attached. picks is the only output that isn't a copy of an input: a string like 1:2, 3:1, frame and image numbers, 1-based - handy in filenames. Masks are the nice surprise: paint one in the picker's zoom and it replaces that image's mask on the masks output.

The settings that bite

These live in the node's widget, not as sockets. Mode: Pause & pick asks every run, Reuse last picks keeps the last answer without asking, Pass all lets everything through. Send picks as sends a frame's picks downstream as one batch (Same shape) or as separate items (One per image) - the latter if each pick gets its own hires pass. Timeout is seconds; 0 waits indefinitely.

Install

Manager → search Wildcard Pipeline by dumiflex → Install → restart. Prefer that path; the Manager brings the built frontend with it. By hand, a clone needs Node and pnpm, because the frontend is build output that isn't in the repo:

cd ComfyUI/custom_nodes
git clone https://github.com/DumiFlex/ComfyUI-Wildcard-Pipeline
cd ComfyUI-Wildcard-Pipeline
pnpm install
pnpm build

No models, no Python dependencies - the pack declares an empty dependency list and needs ComfyUI 0.3.36+ for its V3 node schema.

Where people get burned

A clone without pnpm build gives you a node with no picker. The canvas JavaScript is Vite output that isn't tracked in git; it's force-included into the published package instead. Skip the build and the node waits for an answer no UI will ever send, until the timeout runs out.

Unattended runs just sit there. The picker is a browser thing, so for anything launched from the API or a queue you aren't watching, use Pass all - or a timeout plus what to do when nobody answers (keep all, keep the first, stop the branch). The default is keep all: an unattended run quietly upscales the whole batch.

It always re-runs, and that costs you the cache. The node opts out of caching on purpose - a cached result would skip the picker - with the same NaN fingerprint the plumbing layer has always used. The documented side effect applies: one always-dirty node defeats the cache for everything behind it.

Categorywildcard-pipeline

Inputs (12)

NameTypeDefaultDescription
imagesIMAGEThe images to pick from: one batch, or one batch per frame when a Context Loop runs upstream.
latentoptLATENTLatents of the same images. Sliced to the picks.
masksoptMASKMasks of the same images. Sliced to the picks.
positiveoptCONDITIONINGPositive conditioning. One per frame: kept with its frame. Batched like the images: sliced to the picks.
negativeoptCONDITIONINGNegative conditioning, handled like positive.
positive_textoptSTRINGPositive prompt text (one per frame). Kept with its frame.
negative_textoptSTRINGNegative prompt text (one per frame). Kept with its frame.
contextoptPIPELINE_CONTEXTWP context (one per frame). Kept with its frame, so a later Assembler only sees the picked frames.
extra_1optCOMFY_MATCHTYPE_V3Anything else to carry along. The output takes its type.
extra_2optCOMFY_MATCHTYPE_V3Anything else to carry along. The output takes its type.
clipoptCLIPOptional. Re-encodes a prompt you edit in the picker, so the positive/negative conditioning follows the edit.
wp_image_filteroptWP_IMAGE_FILTER—

Outputs (11)

NameTypeDescription
imagesIMAGE—
latentLATENT—
masksMASK—
positiveCONDITIONING—
negativeCONDITIONING—
positive_textSTRING—
negative_textSTRING—
contextPIPELINE_CONTEXT—
extra_1COMFY_MATCHTYPE_V3—
extra_2COMFY_MATCHTYPE_V3—
picksSTRING—