Batch Image Single Saver
The gotcha hiding in \"preserve original name\"
- image
- saved_path
If you paired this pack's Batch Image Iterator with a process-one-frame-at-a-time step, this is the node that writes the result back down. Batch Image Single Saver takes a single image, its original filename, and an output folder, and saves it - built to sit at the end of an iterate-one-image workflow.
But there's a trap in the defaults, and you should read this before wiring it up: preserve_original_name is on by default, and it still prefixes your filename. The naming logic literally does:
filename = f"{filename_prefix}{name}{ext}" if filename_prefix else original_filename
So feed it photo.jpg with the default prefix of processed_ and you get processed_photo.jpg. The original name is preserved - just not alone. If you want the exact original filename, clear filename_prefix to an empty string. And if you flip preserve_original_name off, the original name is dropped entirely and you get processed_output.png no matter what came in.
Inputs and outputs
image- the single image to save. Required.original_filename- required, and it's just a string. Unlike the batch saver there's no list handling here; pass the Iterator'sfilenameoutput and you're golden.output_folder- default empty → the standard ComfyUIoutput/directory. Anything else is created on the fly and used verbatim.filename_prefix- defaultprocessed_. See the trap above.preserve_original_name- default on.
Output: saved_path, one absolute path string. There's no preview - it's an output node - so check the folder or the returned path.
How it works
Boring and fine. Convert the tensor to a PIL image, save it under the computed name. Pillow picks the format from the extension, so photo.jpg in → JPEG out. It does not add a uniqueness counter or refuse to overwrite - run the same image twice and the second save silently replaces the first. In an iterate loop that's usually what you want (each run overwrites the previous frame), but it's also exactly how you lose a file without noticing.
Install
One repo, same as its siblings:
cd ComfyUI/custom_nodes
git clone https://github.com/cedarconnor/comfyui-BatchNameLoop
Restart ComfyUI, or search "Batch Name Loop" in ComfyUI Manager. No extra dependencies - the pack relies only on what ComfyUI already ships (Pillow, torch, numpy) - and there's no requirements.txt to trip over and nothing to download.
Verdict
A tiny, unglamorous node with exactly one job and a default that will surprise you exactly once. Set filename_prefix to blank, feed it the Iterator's filename, and you've got a clean save step that keeps your naming intact through a whole folder's worth of processing.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| original_filename | STRING | — | |
| output_folder | STRING | — | |
| filename_prefixopt | STRING | processed_ | — |
| preserve_original_nameopt | BOOLEAN | true | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| saved_path | STRING | — |