Switch Early/Middle/Late Predictions
Different strategies for early, middle, and late denoising
- sigmas
- early_prediction
- middle_prediction
- late_prediction
- prediction
Denoising isn't one uniform process. The first steps are where composition and layout get locked in; the last steps are where fine detail gets painted; everything in between is the long middle. Early/Middle/Late Prediction (display name "Switch Early/Middle/Late Predictions") is a three-way switch that lets you run a different prediction strategy during each phase - without hand-picking sigmas yourself.
What it does
It takes three predictions plus a count of how many steps belong to the early and late phases, and slices your whole sigma schedule into three regions. It's the convenience version of chaining two Switch Predictions nodes, which is exactly how the README frames it: "a three-way Switch Predictions node, where the number of early_steps and late_steps can be specified directly."
Inputs:
- sigmas (SIGMAS) - the whole schedule you're sampling with.
- early_prediction, middle_prediction, late_prediction (PREDICTION) - three strategies.
- early_steps (INT, default 1) - how many steps use the early prediction.
- late_steps (INT, default 5) - how many steps at the end use the late prediction.
Output: one prediction.
The classic use
The README's own recommendation for Characteristic Guidance Prediction is to wrap it like this. CHG is absurdly expensive and rarely converges on the first timestep, and it has marginal effect late in sampling - so the sane setup is:
- early (first step): a cheap prediction, maybe plain CFG
- middle: the expensive Characteristic Guidance node
- late (last few steps): plain CFG again
You'd do the same thing with any strategy that's only worth its cost in a specific phase - a heavy guidance vector in the middle, a lighter one at the ends.
How it works (and one sharp edge)
The node slices the sigmas list into three value-ranges: the first early_steps entries, the last late_steps entries (skipping the trailing 0.0), and everything between. Then at each step it dispatches each latent to the right prediction by matching sigma values.
The sharp edge is in the constructor: the schedule must split unambiguously. The source raises ValueError: Sigma schedule is ambiguous. if any sigma value lands in more than one range - and the README warns that restart schedules (which repeat sigmas) often are ambiguous. So feed it the plain, monotonic schedule you got from BasicScheduler, not a hand-twisted one. And give it the whole schedule, not a filtered subset; it needs to see everything to do the slicing.
Installing it
Ships in the ComfyUI-Prediction pack by @RedHotTensors (Project RedRocket). ComfyUI Manager → search "ComfyUI-Prediction", or:
cd ComfyUI/custom_nodes
git clone https://github.com/redhottensors/ComfyUI-Prediction
Restart ComfyUI. No extra dependencies or model files. It's under Add Node > sampling > prediction.
Common issues
- "Sigma schedule is ambiguous" - restart or otherwise repeated sigmas in your schedule. Use a plain scheduler output.
- Phases don't line up. If
early_steps + late_stepsisn't smaller than your step count you'll get a confusing split or a slice that grabs the wrong region; keep it sensible relative to your total steps. - ControlNet unsupported, same as the rest of the pack.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| sigmas | SIGMAS | — | |
| early_prediction | PREDICTION | — | |
| middle_prediction | PREDICTION | — | |
| late_prediction | PREDICTION | — | |
| early_steps | INT | 10–1000 | — |
| late_steps | INT | 50–1000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| prediction | PREDICTION | — |