Nodes/FlowState-Creator-Nodes/🌊🌱 FlowState Latent Source
ComfyUI Node

🌊🌱 FlowState Latent Source

A latent source that can take an uploaded image, not just a wired one

By flowstatelabsΒ·Created 2 years agoΒ·Updated 11 months agoΒ· 25
🌊🌱 FlowState Latent Source
  • vae
  • input_img
  • Latent Image
β—„resolutionβ–Ύβ–Ί
β—„orientationβ–Ύβ–Ί
β—„latent_typeβ–Ύβ–Ί
β—„custom_width1024β–Ί
β—„custom_height1024β–Ί
β—„custom_batch_size1β–Ί
β—„imageβ–Ύβ–Ί

Every sampler in ComfyUI wants a LATENT, and most of the time that latent is one of two things: a blank canvas at a set resolution, or an image you've encoded through a VAE. FlowState Latent Source is a single node that produces either - with one twist that earns it a place over the core Empty Latent Image node: it can pull an image straight off disk through a file-picker widget, no Load Image node and no wire required.

What it makes

Latent Image (LATENT) is the only output, and that's the whole job. Internally an empty latent is just a torch.zeros tensor with shape [batch, 4, height/8, width/8] - the 8s are the VAE's downsampling factor, which is why the node wants a VAE input even though an empty latent never touches it. If you choose an image instead, the node runs that image through the VAE's encoder and hands you the encoded result. Standard stuff, packaged.

The three latent types

  • Empty Latent - a fresh noise-free canvas at your chosen resolution and batch size.
  • Input Image - encodes whatever is wired into the optional input_img socket. Wire it from a Load Image node, or from anything else that outputs an IMAGE.
  • Uploaded Image - the differentiator. This mode gives you a file-picker widget (image) that browses your ComfyUI input directory directly. The node validates the file exists, checks on every run whether it changed, and loads it itself. It's the mode for iterating on one reference image without building Load-Image-into-sampler plumbing every time.

The settings that matter

  • resolution - 18 presets from 1920x1080 - 16:9 up to 4096x2048 - 2:1, plus Custom for the custom_width / custom_height pair. The presets lean hard on the production ratios the whole FlowState suite targets (thumbnails, banners).
  • orientation - presets are listed horizontal; flip to Vertical and the node swaps width and height.
  • custom_batch_size - how many latents to stack. Feed 4 and a sampler will denoise 4 images from the same canvas.
  • vae - required, used only for the image-encoding modes.

Where it sits in a workflow

This is plumbing in the purest sense - it produces the thing samplers consume and nothing else. Its natural home is feeding the optional latent input on something like FlowState Flux Engine, or any KSampler. Because it accepts an uploaded file, it also makes a tidy img2img workflow: pick your image in the widget, set a low denoise on the sampler, and iterate on a starting point without dragging wires around.

Install

It comes with the FlowState Creator Suite, so you install the pack once:

cd ComfyUI/custom_nodes
git clone https://github.com/flowstateeng/FlowState-Creator-Nodes

then restart, or use ComfyUI Manager and search FlowState-Creator-Nodes. Zero pip dependencies - the whole pack wraps ComfyUI's own node set. The only thing you need to bring is a VAE that matches the model you're about to sample with (the Flux ae.safetensors for Flux, the Wan VAE for Wan, and so on). Use a VAE that doesn't match your model family and the encode will produce latents the sampler won't know what to do with.

The honest take

If you're only ever making empty latents, this node is nicer than Empty Latent Image but not life-changing. The Uploaded Image mode is the reason it exists - it kills a whole category of plumbing for img2img. If you never use that mode, its simpler sibling FlowState_SimpleLatent does the rest with fewer options.

CategoryFlowState Creator Suite/Latent

Inputs (9)

NameTypeDefaultDescription
resolutionCOMBO Resolution Selector -------------------------------- - Select "Custom" to use the entered custom_width & custom_height. - Select a preset resolution & orientation.
orientationCOMBO Orientaion Selector -------------------------------- - Resolutions given in horizontal orientation. Select vertical to swap resolution aspect ratio.
latent_typeCOMBO Latent Type -------------------------------- - Your choice of an empty latent (all zeros) or an image as a latent.
custom_widthINT102416–16384 Width -------------------------------- - Defines the width of the image.
custom_heightINT102416–16384 Height -------------------------------- - Defines the height of the image.
custom_batch_sizeINT11–4096 Custom Batch Size -------------------------------- - The number of images you want to generate.
imageCOMBO1 options: example.png
vaeVAE Variational AutoEncoder (VAE) -------------------------------- - The VAE model used for encoding and decoding images.
input_imgoptIMAGEβ€”

Outputs (1)

NameTypeDescription
Latent ImageLATENTThe latent image batch.