π Image Repeat
Turn one image into a batch of N
- image
- image
Small node, one job: take a single image and duplicate it into a list of N copies. That sounds trivial until you hit the situation it exists for - you have one input image and you want to run it through a process several times to get several variations. Feed it into Image Repeat set to 4, and downstream you've got four copies to fan out.
The reason this matters in ComfyUI is that a lot of nodes iterate over a list. If you want four img2img results from one source photo, or you want to pair one image against a batch of prompts, you first need that image to exist four times. Repeat is how you manufacture that.
How it works
It takes your IMAGE and emits it repeat times as an image list (note: a list, where each item is processed one at a time by downstream nodes, as opposed to a stacked batch tensor). Everything after it that runs per-list-item will now run once per copy. It's a pure structural op - no pixels change, nothing is generated.
The inputs and outputs that matter
Just two inputs:
image- the one you're duplicating.repeat- how many copies (minimum 1). Set this to the number of variations or passes you want.
The output is image as a list. The list part is the whole point - wire it into something that iterates, and each copy travels through separately. If a downstream node reseeds or randomizes per item, you get N different results from the one source.
How to install it
ComfyUI Manager: search SDVN_Comfy_node, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/StableDiffusionVN/SDVN_Comfy_node
then pip install -r custom_nodes/SDVN_Comfy_node/requirements.txt from your ComfyUI root, and restart. It's under SDVN β Image.
Common issues & troubleshooting
All my copies came out identical. That's Repeat doing its job - it makes copies. To get variation, something downstream has to differ per item, usually a seed set to randomize or increment. Repeat only supplies the copies; it doesn't add randomness.
The workflow got slow / ran out of memory. Each copy is real work. Set repeat to 8 and you've asked for eight full passes of whatever follows. Keep the number honest to what your VRAM and patience allow.
List vs batch confusion. This outputs a list, which some nodes handle differently from a batched tensor. If a downstream node expects a batch and chokes on a list (or vice versa), that's the mismatch - this pack and ComfyUI both have list/batch conversion helpers to bridge it.
I only need the image twice but got a weird count. repeat is the total count, not "extra copies." repeat = 1 gives you one (the original), repeat = 4 gives four total.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| repeat | INT | 1 | β |
| image | IMAGE | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | Danh sΓ‘ch αΊ£nh sau khi lαΊ·p. |