Nodes/Difforum/Difforum · Feedback Sampler
ComfyUI Node

Difforum · Feedback Sampler

The Deforum Look, Without the 2022 Baggage

By chillithebillis·Created 4 months ago·Updated 11 days ago· 10
Difforum · Feedback Sampler
  • model
  • positive
  • negative
  • vae
  • init_image
  • direction
  • options
  • params
  • camera
  • strength
  • cfg_curve
  • prompts
  • depth
  • control_net
  • control_image
  • key_images
  • frames
  • depth
  • report
◄steps20►
◄cfg6.0►
◄sampler_nameeuler►
◄schedulernormal►
◄cadence1►
◄control_strength0.60►
◄energy0.50►
◄key_indices—►
◄key_pull0.65►
◄key_approach12►

This is the node the pack was built for. The idea is the oldest one in AI video: take the last frame, move it, re-imagine it slightly, repeat. Deforum did that in 2022 on SD 1.5 and the results had a look nothing else quite reproduces - and also a flicker, a colour drift and a dependency situation that made running it in 2026 genuinely painful.

The Feedback Sampler is the same loop, rebuilt on modern plumbing.

How the loop works

Each frame runs: warp by the camera → symmetry → detail guard → diffuse → colour match. Diffusion is a callback inside a torch-only engine, which is why the preview and the render agree, and why the pack's test suite runs without a GPU.

Three fixes matter more than the rest:

  • Depth follows the image. The depth map is re-projected with every 3D warp, so parallax stays attached to what's on screen rather than to frame 0. Feed a depth map (the tooltip's example is Depth Anything V2 on the first frame; template 03 uses the newer core Depth Anything 3) and set the Director to 3d; without one, 3D moves run as pseudo-3D and the report says so.
  • Cadence without pops. cadence 2 diffs every second frame and crossfades the in-between ones - the previous key warped forward, the next key warped backward, the Deforum trick. Nearly invisible, roughly twice as fast.
  • Revealed edges get repainted. The occlusion mask from the warp gets extra noise, so the sampler invents content where the camera uncovered the unknown instead of smearing edge pixels.

Steps scale with energy, also like Deforum: a frame at denoise 0.5 runs half the steps. With cadence 2 that's around 4x faster than sampling every frame in full.

Inputs worth thinking about

You need model, positive, negative, vae, init_image and - realistically - a direction wire. That's it: any plain ComfyUI MODEL/VAE/CONDITIONING works, so SD 1.5, SDXL, Flux, SD3.5 and turbo/LCM/DMD2 distills are all fair game. Turbo models want cfg 1–2 and sampler_name euler_ancestral or lcm with scheduler sgm_uniform; a regular SDXL run is happier at cfg 4–7 with euler or dpmpp_2m and a karras/normal schedule.

Then the creative dials:

  • energy (default 0.5) - denoise per frame when no Director or strength schedule is plugged in. 0.3 is steady, 0.5 is classic Deforum morph, 0.7+ changes the image every few frames.
  • cadence (default 1) - start at 2.
  • key_images + key_indices with key_pull (0.65) and key_approach (12) - multikeyframing. The travel steers toward each picture quadratically over the approach window and lands on it. key_pull 1.0 arrives exactly, 0.3 is a hint; short approaches give sudden arrivals, long ones let the image slowly become the key.

Outputs

frames goes into your video combine or a post node. depth is the tracked depth per frame - genuinely useful as a video-model guide or a relight pass. report prints what actually happened, including the pseudo-3D warning.

Install

Manager → "Difforum", or:

cd ComfyUI/custom_nodes && git clone https://github.com/chillithebillis/Difforum.git difforum

Restart. There are no Difforum model downloads; you bring your own checkpoint. requirements.txt is numpy alone, and the heavier things (OpenCV for flow/webcam, SpoutGL for Spout output) are optional and imported only by the nodes that need them.

Where people get burned

Long runs at high energy drift and mush - that's cumulative VAE round-trips softening each frame, and the answer is the in-loop detail guard (sharpen + a touch of fresh noise) rather than a bigger model. If your clip flickers, run it through Flow Stabilize before you decide the render is bad. And if you queue a 60-second shot on a 20-step SDXL and then complain, cadence and steps were sitting right there.

CategoryDifforum/4 · Render

Inputs (26)

NameTypeDefaultDescription
modelMODELThe image model (SD1.5 / SDXL / Flux / turbo). MODEL output of your checkpoint or LoRA chain.
positiveCONDITIONINGLook / style prompt. Used for every frame when no scene prompts reach the sampler.
negativeCONDITIONINGNegative conditioning (CLIP Text Encode).
vaeVAEThe VAE that matches the model.
init_imageIMAGEThe first frame. Everything grows from this image.
stepsINT201–200Steps for a full denoise. With step scaling (default) a frame at energy 0.5 runs half of them, like Deforum.
cfgFLOAT6.00–30Prompt strength. Turbo / LCM / DMD2 models want 1-2; regular SDXL 4-7.
sampler_nameCOMBOeulerSampler. euler / dpmpp_2m for regular models, euler_ancestral or lcm for turbo.
schedulerCOMBOnormalNoise schedule. karras / normal for regular models, sgm_uniform for turbo.
cadenceINT11–12Diffuse every Nth frame; the frames in between ride the camera and crossfade. 2 is almost invisible and twice as fast.
directionoptDIFFORUM_DIRECTIONThe Director's wire: camera, energy curve, scene prompts, keys and look in one cable.
optionsoptDIFFORUM_OPTIONSDifforum · Render Options, for manual control.
paramsoptDIFFORUM_PARAMSFrom Setup: frame count, fps, width and height. Plug the same Setup everywhere.
cameraoptDIFFORUM_CAMERAA camera track from Camera (keys), Camera (expressions) or Camera Import. Overrides the Director's camera.
strengthoptDIFFORUM_SCHEDULEA schedule that replaces the Director's energy curve (denoise per frame).
cfg_curveoptDIFFORUM_SCHEDULEA schedule for cfg per frame.
promptsoptDIFFORUM_PROMPTPrompt travel from Prompt Travel (or the Director with CLIP connected).
depthoptIMAGEDepth of the first frame (white = near), or a per-frame batch.
control_netoptCONTROL_NETOptional ControlNet (depth, canny...) applied on every diffused frame.
control_imageoptIMAGEPer-frame control images; empty = the frame itself.
control_strengthoptFLOAT0.600–3ControlNet strength.
energyoptFLOAT0.500–1Denoise per frame when no Director or strength curve is connected. It is how much each frame is re-imagined: 0.3 = steady, 0.5 = classic Deforum morph, 0.7+ = the image changes every few frames.
key_imagesoptIMAGEKeyframe Images: the travel steers toward each picture and lands on it at its frame. This is multikeyframing.
key_indicesoptSTRINGFrame numbers of the key pictures (Keyframe Images 'indices').
key_pulloptFLOAT0.650–1How strongly the frame is pulled toward the next key picture before diffusion. 1 = arrives exactly on it, 0.6 = strong resemblance, 0.3 = a hint.
key_approachoptINT121–240Frames before a key over which the pull ramps up. Short (6-12) = sudden arrival, long (24-48) = the image slowly becomes the key. Long shots want long approaches.

Outputs (3)

NameTypeDescription
framesIMAGE—
depthIMAGE—
reportSTRING—