ComfyUI Node Runs on cloud

ToLatentList

Collect loose latents into one list

By bmad4ever·Created 3 years ago·Updated about a year ago· 64
ToLatentList
    • LATENT
    inputs_len2

    ToLatentList is the latent member of the bmad "make a list" family: it takes several individual LATENT inputs and collects them into a single Python list on one output. It's the answer to the same problem as its siblings - some nodes want a real list of latents rather than a batched latent or a handful of separate wires - and this node is how you build that list from loose ends.

    The input that matters

    inputs_len - how many input sockets appear (default 2, up to 32). Set it to 4 and you get latent_0 through latent_3. Wire in each latent; the output is a single LATENT list. Leave a slot unplugged and it shows up as empty in the list, so size it to what you're actually feeding.

    Why you'd reach for it

    Any workflow that processes a set of latents through a list-aware node needs this at the front. It pairs with the family's splitter nodes - FromListGetLatents gives you the latents back on individual sockets, FromListGet1Latent pulls a single one - so you can convert between "many wires" and "one list" without restructuring your graph. If you're doing per-latent operations in a loop or feeding a list-consuming sampler stack, this is the collection point.

    It's deliberately different from just stacking latents into a batch: a batch means one tensor with all samples, while a list keeps them as separate objects with their own noise/noise_mask dicts intact. When a node's input type is literally "LATENT list," this is what it's asking for.

    Installing

    Ships in comfyui_bmad_nodes, bmad4ever's grab-bag of API, CV, and utility nodes. ComfyUI Manager - search "comfyui_bmad_nodes" (or "Bmad Nodes") - install, restart. Manual:

    cd ComfyUI/custom_nodes
    git clone https://github.com/bmad4ever/comfyui_bmad_nodes
    cd comfyui_bmad_nodes
    pip install -r requirements.txt
    

    Restart after. No model downloads; pure Python, no extra dependencies for this node.

    Like all the list builders, it's unglamorous - but when a workflow suddenly demands latents as a list and you've got them on separate wires, it's the least fussy way to get there.

    CategoryBmad/Lists/Make or Intercalate

    Inputs (1)

    NameTypeDefaultDescription
    inputs_lenINT20–32

    Outputs (1)

    NameTypeDescription
    LATENTLATENT