easy xyAny
Build every combination of two lists
- X
- Y
- X
- Y
easy xyAny takes two lists - any type, doesn't matter what - and expands them into every possible pairing: the Cartesian product. Three seeds and four LoRA strengths in, twelve seed/strength pairs out, ready to feed into a for-loop. It's a Logic node, not an image tool, and despite the "XY" in the name it has nothing to do with the pack's easy XY Plot Advanced grid-image nodes - those build a visual comparison grid; this one just builds a combination list for you to iterate over however you want.
Why you'd reach for it
Any time you're sweeping two dimensions at once inside a loop rather than a plot. Say you're batch-testing five prompts against three checkpoints and want every one of the fifteen combinations run through your pipeline, or you want a for-loop to walk every pairing of two style presets and two aspect ratios. Without this node you'd nest two loops manually; easy xyAny flattens the nesting into one list pair you can drive with a single easy forLoopStart/easy forLoopEnd.
How it works
Both X and Y accept a list of values, not a single one - connect a node that outputs multiple items (the pack's list-producing utilities, a batch, or several links merged upstream) and this node collects all of them. It then interleaves the two lists into paired output lists X and Y where X[i]/Y[i] is one combination. The direction toggle controls the order the combinations come out in:
horizontal(default) - X cycles fastest: for every Y value, it runs through the whole X list before moving to the next Y. This is the order you'd want if you're thinking of the result as rows of a grid, filled left to right.vertical- Y cycles fastest instead, filling column by column.
The order only matters if you care about the sequence your loop processes combinations in (say, for a progress preview); the set of combinations is identical either way.
The inputs and outputs that matter
XandY- the two lists to combine. Wildcard type, so numbers, strings, prompts, whatever two upstream sources hand you.direction-horizontalorvertical, controls iteration order as described above.
Outputs are X and Y, now expanded to the full combination count (list length X × list length Y), index-aligned so pairing X[i] with Y[i] at every position gives you one full combination. Feed both into a for-loop's inputs and the loop body sees one matched pair per iteration.
Installing it
ComfyUI Manager: search ComfyUI Easy Use, install, restart. Or by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/yolain/ComfyUI-Easy-Use
Windows: double-click install.bat. Linux/Mac: pip install -r requirements.txt. Restart ComfyUI. No models, nothing heavy - it's a small logic utility.
Common issues & troubleshooting
The main trap is forgetting this node needs lists on both inputs, not single values - if you wire in a single number or string, you'll get a "combination list" of exactly one item, which technically works but defeats the point. Make sure whatever feeds X and Y is actually producing multiple items (a list-output node, or several values merged together upstream), not a single constant.
The other one is scale: this is a full Cartesian product, so the output length is the product of both input lengths, not the sum. Ten values on each side is 100 combinations, not 20 - fine for a quick sweep, expensive if you're running a full generation per combination and each one costs real GPU time. Sanity-check the combination count before you queue a loop over it.
And since this lives in EasyUse/Logic next to the pack's easy ifElse, switches and loop nodes rather than in EasyUse/XY Inputs, don't go looking for it as a way to build an image comparison grid - for that you want the dedicated XY Inputs nodes (CFG Scale, Denoise, and friends) wired into easy XY Plot Advanced instead. This node's job ends at producing the combination list; what you do with each pairing is entirely up to the rest of your graph.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| X | * | — | |
| Y | * | — | |
| direction | COMBO | horizontal | 2 options: horizontal, vertical |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| X | * | — |
| Y | * | — |