Load Latent (Upload)
The upload button ComfyUI's stock Load Latent forgot
- samples
The stock ComfyUI Load Latent node has no upload button. You can drag images onto the canvas, upload reference photos from a button on Load Image, but a .latent file? You were stuck copying it into input/ by hand or hunting through folder paths. Load Latent (Upload) exists to fix exactly that one gap, and it's the finishing step of the Model Phase Sync pack's "split the workflow into phases" trick.
It matters because of the phase-split pipeline this pack is built around. Instead of one monster graph that keeps CLIP, UNet, and VAE loaded at once, you run:
- CLIP only - encode prompts, save conditionings
- Diffusion only - load conditionings, sample,
Save Latentto disk - VAE only - this node → VAE Decode → Save Image
People reach for that shape for a few reasons, and they're real: decoding is often the step that OOMs after a long run, so saving the latent and decoding later lets you keep the expensive sampling work; a crash mid-batch stops losing finished branches; and on unified-memory Macs you stop paying for CLIP sitting resident through all of diffusion. The community has been hand-rolling latent savers for exactly this ("Made a Latent Saver to avoid Decode OOM after long Wan runs" is a familiar beat on r/StableDiffusion) - this is the packaged version.
How it works
The node is a dropdown loader plus a file-upload button, both backed by a small JS extension. The button POSTs the file's raw bytes to ComfyUI's /upload/image endpoint with subfolder=latents - the same route image uploads use, which is why it works without any server-side changes - and files land in input/latents/.
Under the hood it reads with safetensors, and it handles both latent formats you'll actually meet: the newer latent_format_version_0 files that stock Save Latent writes, and older SD1.5-era files that need the 1/0.18215 scaling multiplier. So whatever saved the .latent - core Save Latent, this pack's Save Latent (Atomic), or most other savers - it comes back looking right.
The inputs that matter
latent_file(required, dropdown): every.latentfound inoutput/latents,input/latents, andinput/. If there are none, it shows a message instead of a list - literally "no .latent files found - run Save Latent first (or upload / put files in input/latents or output/latents)". That message is the fix, written out for you.path(optional, default""): an override for when the dropdown isn't enough. Absolute path, or relative tooutput//input//latents/- e.g.latents/zimage_01_00001_.latent. The tooltip is the author's own description and it's accurate.
One output, samples (LATENT). That's it - wire it straight into VAE Decode and out to Save Image. It's compatible with the files this pack's Save Latent (Atomic) writes, which is the intended pairing.
Install
This ships in the Model Phase Sync pack. In ComfyUI Manager search "Model Phase Sync" (or model-phase-sync) and hit install, or use the CLI:
comfy node install model-phase-sync
Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/josetseph/ComfyUI-ModelPhaseSync.git
Restart ComfyUI and it appears under the model_phase_sync category. There are no extra dependencies and nothing to download - the pack is pure Python plus a little JS, MIT licensed.
Gotchas
- The dropdown is a snapshot. If you save latents and this node doesn't show them, refresh the node (or re-add it) - the file-list cache is invalidated on save, but an already-open widget won't always repopulate live.
- When you use the upload button, it lands in
input/latents/; the dropdown also scansoutput/latents/, so don't go hunting for your upload in the output folder. - The
pathoverride bypasses the dropdown entirely - good for automation, easy to typo. The error message tells you exactly which file it couldn't resolve.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| latent_file | COMBO | 1 options: no .latent files found — run Save Latent first (or upload / put files in input/latents or output/latents) | |
| pathopt | STRING | Optional path override. Absolute, or relative to output/ / input/ / latents/ (e.g. latents/zimage_01_00001_.latent). |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| samples | LATENT | — |