Nodes/ComfyUI-Advanced-ControlNet/Timestep Keyframe Interp. πŸ›‚πŸ…πŸ…’πŸ…
ComfyUI Node Runs on cloud

Timestep Keyframe Interp. πŸ›‚πŸ…πŸ…’πŸ…

Ramp ControlNet strength over steps

By KosinkadinkΒ·Created 3 years agoΒ·Updated 12 days agoΒ· 994
Timestep Keyframe Interp. πŸ›‚πŸ…πŸ…’πŸ…
  • prev_timestep_kf
  • cn_weights
  • latent_keyframe
  • mask_optional
  • TIMESTEP_KF
β—„start_percent0.000β–Ί
β—„end_percent1.000β–Ί
β—„strength_start1.000β–Ί
β—„strength_end1.000β–Ί
β—„interpolationβ–Ύβ–Ί
β—„intervals50β–Ί
β—„null_latent_kf_strength0.000β–Ί
β—„inherit_missingtrueβ–Ί
β—„print_keyframesfalseβ–Ί

Say you want a ControlNet that starts strong and fades out as sampling goes on - full grip on the composition early, then hands off to the model for the fine detail. You could hand-build a chain of Timestep Keyframes at 0%, 20%, 40%… and set the strength on each. Or you use this node, give it a start and end percent, a start and end strength, and let it generate the whole ramp for you.

That's the pitch. It builds a schedule of Timestep Keyframes with interpolated strengths across a percentage range of the sampling process, so you get a smooth fade instead of a step function you assembled by hand.

Why this is a real technique, not a gimmick

Timing when a ControlNet applies is one of the highest-leverage knobs in the whole toolkit. The community's standing advice for structure-heavy work is to release the condition once the composition has formed, rather than holding it through the entire sample - end the control around the halfway mark and the later steps become the model's own. This node is how you do that smoothly: ramp strength from 1.0 down to something low across the first half of sampling instead of hard-cutting it. (Reminder that "percent" here is percentage of the sampling process, not steps - 0.5 means halfway through, whatever your step count.)

The inputs that matter

Six required knobs define the ramp:

  • start_percent / end_percent - the sampling-percentage window the generated keyframes span (0.0 to 1.0).
  • strength_start / strength_end - the ControlNet strength at each end. Ramp down (1.0 β†’ 0.2) to fade control out; ramp up to bring it in late.
  • interpolation - the curve between them (linear and eased options).
  • intervals - how many keyframes to generate across the range (default 50). More = smoother. The first one gets guarantee_steps=1, the rest get 0, which just means the first is guaranteed at least one step.

The optionals are the same set every Timestep Keyframe node carries: prev_timestep_kf to chain onto an existing schedule, cn_weights and latent_keyframe and mask_optional to attach per-block weights, latent-strength scheduling, and attention masks; inherit_missing (default true) to reuse the last-set values for anything you leave blank; null_latent_kf_strength; and print_keyframes, which dumps the generated schedule to console - turn it on the first time so you can see what it built.

The output TIMESTEP_KF wires into the timestep_kf input on Apply Advanced ControlNet (or chains into another keyframe node).

Installing the pack

ComfyUI Manager β†’ Install Custom Nodes β†’ search "ComfyUI-Advanced-ControlNet" β†’ restart. Or cd ComfyUI/custom_nodes && git clone https://github.com/Kosinkadink/ComfyUI-Advanced-ControlNet and restart. Pure ComfyUI, no heavy deps. It's Kosinkadink's pack (the AnimateDiff-Evolved dev). Remember it carries no preprocessors - those are in comfyui_controlnet_aux - and no model files.

Common gotchas

The one that catches people: the start_percent on your keyframes is gated by the start_percent and stop_percent on the Apply Advanced ControlNet node. If Apply is set to start at 0.3, none of these interpolated keyframes fire before 30% no matter what window you gave them. So if a ramp isn't taking effect, check the Apply node's percentages first.

Also, intervals at 50 is smooth but a touch wasteful - the ControlNet re-evaluates weights at each keyframe boundary. For a plain linear fade you rarely need more than 10 to 20 to get a visually identical result. And if you just want a flat schedule from a list of numbers rather than an interpolation, reach for Timestep Keyframe From List instead.

CategoryAdv-ControlNet πŸ›‚πŸ…πŸ…’πŸ…/keyframes

Inputs (13)

NameTypeDefaultDescription
start_percentFLOAT0.0000–1β€”
end_percentFLOAT1.0000–1β€”
strength_startFLOAT1.0000–10β€”
strength_endFLOAT1.0000–10β€”
interpolationCOMBO4 options: linear, ease-in, ease-out, ease-in-out
intervalsINT502–100β€”
prev_timestep_kfoptTIMESTEP_KEYFRAMEβ€”
cn_weightsoptCONTROL_NET_WEIGHTSβ€”
latent_keyframeoptLATENT_KEYFRAMEβ€”
null_latent_kf_strengthoptFLOAT0.0000–10β€”
inherit_missingoptBOOLEANtrueβ€”
mask_optionaloptMASKβ€”
print_keyframesoptBOOLEANfalseβ€”

Outputs (1)

NameTypeDescription
TIMESTEP_KFTIMESTEP_KEYFRAMEβ€”