Nodes/ComfyUI Extra Samplers/WarmupDecayCFGGuider
ComfyUI Node

WarmupDecayCFGGuider

A CFG that eases off the gas as sampling progresses

By Clybius·Created 3 years ago·Updated 2 years ago· 104
WarmupDecayCFGGuider
  • model
  • positive
  • negative
  • GUIDER
cfg_max12.0
cfg_min1.0
warmup_percent0.50

WarmupDecayCFGGuider is the plainest member of the guider family in ComfyUI Extra Samplers - and sometimes plain is what you want. It outputs a GUIDER that runs a high CFG early in sampling and eases it down to a low CFG by the end, using a cosine curve. That's the whole job, and it's a good one.

Why does dynamic CFG help? Flat, high CFG is the classic cause of "burned" images - oversaturated, contrasty, artifacted output. But CFG matters most early, when the image is still a noisy blob and the prompt needs to actually take hold. Cranking it down in the late steps, when the image is nearly formed, is a standard way to get strong prompt adherence without the late-step overcooking. WarmupDecayCFGGuider automates that envelope instead of making you build it out of multiple KSamplers or patch nodes.

You control the envelope with three inputs: cfg_max (default 12) is the strong value it starts from, cfg_min (default 1) is where it ends, and warmup_percent (default 0.5) is the fraction of the schedule spent at the high end. The code converts warmup_percent to a sigma threshold and then blends the two CFG values with a cosine curve above and below it, so you get a smooth ramp rather than a step change. Raise warmup_percent to stay aggressive longer; lower it to back off sooner.

The inputs, all of which you'll actually touch:

  • cfg_max - CFG at the start of sampling. 12 is the default; the knowledge-base rule of thumb is that SD 1.5/SDXL lives at 5–9, so don't be shy about lowering this.
  • cfg_min - the floor it settles toward. Default 1.
  • warmup_percent - how much of the run stays at the high end. Default 0.5 is a decent starting point.

Output: one GUIDER, wired into the guider input of a custom sampler node (SamplerCustom, SamplerCustomNoise, etc.) that also takes your positive / negative conditionings - this node doesn't invent conditionings, it shapes the guidance they'd get.

A note on distilled models, since this is where dynamic CFG usually goes wrong: guidance-distilled checkpoints (LCM, Lightning/Turbo/Hyper, and most 2026 flow models) have their guidance baked in and want CFG 1–2 the whole way. Ramping down from 12 toward 1 still means running the early steps at a CFG the model was never trained for, and you'll get the same oversaturation the flat version gives you. This guider shines on SD 1.5/SDXL-style CFG-hungry models, not on distilled ones - if you're on a distilled checkpoint, the honest advice is leave CFG alone entirely.

Install is the shared pack routine: ComfyUI Manager → search "ComfyUI Extra Samplers", or clone + restart:

cd ComfyUI/custom_nodes
git clone https://github.com/Clybius/ComfyUI-Extra-Samplers

No model downloads; the only dependency is kornia. If your goal is dynamic CFG plus reference-image steering, grab MegaCFGGuider from the same pack instead - this one is the focused version.

Categorysampling/custom_sampling/guiders

Inputs (6)

NameTypeDefaultDescription
modelMODEL
positiveCONDITIONING
negativeCONDITIONING
cfg_maxFLOAT12.00–100
cfg_minFLOAT1.00–100
warmup_percentFLOAT0.500.01–1

Outputs (1)

NameTypeDescription
GUIDERGUIDER