Load Image #39
The node that replays a PNG's own recipe
- image
- mask
- filename
- index
- ckpt_name
- positive
- negative
- seed
- steps
- cfg
- sampler_name
- scheduler
- denoise
Every PNG ComfyUI writes carries its own recipe baked into the file metadata: the prompt, the seed, the sampler, the CFG, the denoise, even which checkpoint produced it. That's the "workflow included" culture made literal - drag the image back into ComfyUI and the whole graph rebuilds. Load Image In Seq (indexed here as "Load Image #39") is that same trick turned into a node: point it at a folder, step through ComfyUI-generated PNGs, and it hands you the image and the exact settings that made it, ready to wire straight back into a new generation.
It's part of the small "prompt reader" family of nodes - the README name-checks was-node-suite-comfyui and comfyui-prompt-reader-node as its references - but with a batch bent. Instead of reading one image's metadata, it walks a whole folder in order. Think: you queue up forty variations, pick the keepers, then re-run a few with slightly different prompts or denoise. That workflow - load, look, tweak, re-queue - is exactly what this node exists to make painless.
How it works
The mechanism is dead simple: it reads the embedded workflow metadata out of the PNG's tEXt chunks and exposes each field as its own output. The trick is that it only works on PNGs generated by ComfyUI. That's not a bug or a limitation you can fix; it's the entire premise. A JPG, or a PNG saved by A1111 or a screenshot, doesn't carry that metadata and will come back with empty fields. Feed it ComfyUI output and you get the full recipe back.
Inputs that matter
You'll set exactly three:
- dir_path - the folder to scan (defaults to
./ComfyUI/input, so set an absolute path to where your PNGs actually live). - index - which image in the folder you're looking at.
- mode -
fixedorincrement. This is the whole trick: inincrement, every time you hit Queue Prompt (or run in Auto Queue) the node advances to the next image and loops at the end of the folder. That turns the node into an automated batch driver.
Everything else is a default_* fallback: default_positive, default_negative, default_seed, default_steps, default_cfg, default_denoise, and the sampler/scheduler dropdowns. When a PNG's metadata is missing a field, the default is what gets used instead. default_ckpt_name is a dropdown populated from your checkpoints folder, so you can force a model even when the image doesn't name one.
Outputs and what they wire into
image (an IMAGE tensor - feed it to VAE Decode or into an img2img sampler), mask (a MASK, used by the built-in quick inpaint), filename, and index. Then the replay payload: ckpt_name, positive, negative, seed, steps, cfg, sampler_name, scheduler, and denoise. Wire positive and negative into CLIP Text Encode (Prompt), sampler_name/scheduler/denoise/seed into your KSampler, and ckpt_name into a checkpoint loader - the README notes it parses ckpt_name into MODEL, CLIP, and VAE. Set the node, and your graph re-runs the image under whatever tweaks you make. That's the entire point.
Install
No models, no heavy dependencies - this is a thin utility node. Either search "comfyui-load-image-in-seq" in ComfyUI Manager and hit install, or:
cd ComfyUI/custom_nodes
git clone https://github.com/shinich39/comfyui-load-image-39
Then restart ComfyUI. It appears in the Add Node menu under image > Load Image In Seq.
Gotchas
- Non-ComfyUI images return empty metadata. If every field comes back blank, that's why. Check the file isn't a JPG or a re-exported screenshot.
- Increment mode only advances on a queue. Just changing the index in the node won't loop your folder; you have to actually Queue Prompt.
- The dir_path default is relative, so it depends on where ComfyUI was launched from. Point it at an absolute path.
- The quick-inpaint flow (paint a mask on the preview, press the right arrow, inpaint) ties into the mask output - handy for fixing one bad hand mid-batch rather than taking the image out to a full editor. If mask-based inpainting feels like overkill, remember the mask output also works with any standard Set Latent Noise Mask path.
It's a niche tool, but for anyone who keeps folders of generations around and wants to remix or repair them, it's the rare utility that feels like it was built for the workflow you already have.
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| dir_path | STRING | ./ComfyUI/input | — |
| mode | COMBO | 2 options: fixed, increment | |
| index | INT | 0 | — |
| default_ckpt_nameopt | COMBO | 0 options: | |
| default_positiveopt | STRING | — | |
| default_negativeopt | STRING | — | |
| default_seedopt | INT | 00–18446744073709550000 | — |
| default_stepsopt | INT | 201–10000 | — |
| default_cfgopt | FLOAT | 8.000–100 | — |
| default_sampler_nameopt | COMBO | 22 options: euler, euler_ancestral, heun, heunpp2, dpm_2, dpm_2_ancestral, +16 | |
| default_scheduleropt | COMBO | 6 options: normal, karras, exponential, sgm_uniform, simple, ddim_uniform | |
| default_denoiseopt | FLOAT | 1.000–1 | — |
Outputs (13)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |
| filename | STRING | — |
| index | INT | — |
| ckpt_name | STRING | — |
| positive | STRING | — |
| negative | STRING | — |
| seed | INT | — |
| steps | INT | — |
| cfg | FLOAT | — |
| sampler_name | STRING | — |
| scheduler | STRING | — |
| denoise | FLOAT | — |