Stable Cascade Latent Ratio
The purple Empty Latent for Stable Cascade — with aspect-ratio locks built in
- stage_c
- stage_b
Stable Cascade is the model the community loved and then quietly left for Flux - a Würstchen-style three-stage pipeline (stage C → stage B → stage A) that compresses the latent space far more aggressively than SDXL. That aggressive compression is exactly why its "empty latent" step is fiddlier than the one you're used to. The core Empty Latent Image node gives you a 4-channel latent; Cascade wants a 16-channel stage C latent at ~42× compression and a separate 4-channel stage B latent at 4×. Do that math by hand every workflow and you'll mess it up eventually.
StableCascadeLatentRatio is the shortcut: one node that makes both latents, at the right sizes, with the resolution math hidden and a few conveniences the stock node doesn't have. It renders purple on the canvas so you can tell it apart from the regular empty latent at a glance - a small thing until you've wired the wrong LATENT into the wrong stage and watched the sampler silently do something dumb.
How it works
The mechanism is deliberately dumb, which is the point. Under the hood the node just allocates zero-filled tensors:
stage_c:[batch_c, 16, height // compression, width // compression]stage_b:[batch_b, 4, height // 4, width // 4]
compression defaults to 42, which is the standard Würstchen stage-C compression for the official Stable Cascade checkpoints - leave it alone unless you know your checkpoint expects something else. The zeros are the starting point for denoising, same as any empty latent; they only become an image after the sampler runs through all three stages.
The inputs that matter
Most of the fields are self-explanatory, and width/height step in 64s to keep everything divisible. The two worth understanding:
compression(default 42) - the stage-C downscale factor. Keep 42 for stock checkpoints.lock_aspect_ratio_to- a dropdown of 13 presets (1:1,4:3,16:9,2.39:1,9:16,3:1panorama, and so on). Pick one and changingwidthauto-updatesheightto match, snapping to the 64px grid. Theswitch_width_heighttoggle flips the dimensions at execution time (handy for portrait/landscape swaps without editing the workflow). And the two batch sizes are separate -batch_size_candbatch_size_b- specifically so you can feed one through a Latent From Batch node without dragging the other stage along.
The two outputs are stage_c and stage_b, both LATENT. In the standard text-to-image flow you wire stage_c into StableCascade_StageC and let the pipeline generate the B-stage latent itself. The stage_b output earns its keep when you want to drive Stage B directly - image-to-image-style or latent-editing workflows. If you don't need it, just leave it unconnected.
Installing it
No dependencies, no model downloads, no API key - the whole pack is one Python file and a snippet of frontend JS. The node itself needs nothing; the Stable Cascade checkpoints (stage_a, stage_b, stage_c, and the VAE) are a separate download. Install via ComfyUI Manager by searching "Stable Cascade Latent Ratio", or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/Guillaume-Fgt/ComfyUI_StableCascadeLatentRatio.git
Restart ComfyUI and you'll find it under latent/ as Stable Cascade Latent Ratio.
Where people get burned
- Decoding the zero latent directly gives garbage. That's expected - it's a start state, not a finished image. If you're debugging, remember the pipeline is StageC → StageB → StageA/VAE decode, not a single pass.
- Aspect-ratio locking seems "broken"? The lock only enforces when you actually drag
widthorheightafter selecting a preset, and only when it's notNone. Select the ratio, then nudge a dimension and the other follows. - Wrong stage wired to wrong input is the classic Cascade mistake. The purple background is there precisely because both
stage_cand the regular empty latent are justLATENTtensors and nothing will stop you from swapping them.
It's a small utility node, but it's the one you want at the start of a Cascade graph - less mental math, one less place to typo a division.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 1024256–16384 | — |
| height | INT | 1024256–16384 | — |
| compression | INT | 424–128 | — |
| batch_size_c | INT | 11–4096 | — |
| batch_size_b | INT | 11–4096 | — |
| lock_aspect_ratio_to | COMBO | 13 options: None, 1:1|Social apps, 4:3|Traditional television & computer monitor standard; classic 35 mm film standard, 14:9|Used as a middle ground between 4:3 and 16:9, 16:10|Mostly used for computer displays and tablet computers, 16:9|HD video standard; American & British digital broadcast TV standard, +7 | |
| switch_width_height | BOOLEAN | false | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| stage_c | LATENT | — |
| stage_b | LATENT | — |