Nodes/MBM's Music Visualizer/Prompt Sequence Renderer
ComfyUI Node

Prompt Sequence Renderer

The renderer that's secretly a KSampler running a whole music video

By Sorcerio·Created 2 years ago·Updated 2 years ago· 32
Prompt Sequence Renderer
  • prompts
  • latent_mods
  • latent_image
  • model
  • LATENTS
  • CHARTS
seed0
seed_mode
latent_mode
image_limit-1
latent_mod_limit5.00
steps20
cfg8.0
sampler_name
scheduler
denoise1.00

This is where MBM's Music Visualizer actually earns the name. The Feature Calculator extracts the audio, the Interpolator builds a prompt for every frame - and the Prompt Sequence Renderer is the node that runs diffusion on all of it. Don't be fooled by the modest name: underneath it's a full KSampler wrapped in a loop. One frame at a time, it takes the current latent, mutates it based on the frame's audio feature modifier, runs a complete sampling pass with the current interpolated prompt, and moves on. A 60-second song at 6 fps is 360 full diffusion generations. Budget your GPU time accordingly.

The inputs that shape the motion. The first few are what make this different from a normal sampler:

  • latent_mods - the calculator's FEAT_MODS, one modifier per frame. This is the audio talking to the renderer.
  • latent_image - your starting latent, usually from EmptyLatentImage. This is the canvas.
  • seed plus seed_mode - fixed (same seed every frame), random, increase, or decrease (step the seed by one each frame). fixed keeps character consistent; random gives the chaotic, flickery look.
  • latent_mode - how the latent changes between frames. bounce swings the latent's mean up to latent_mod_limit and back, like a sine driven by the beat. flow randomly picks increase or decrease per hop, so the latent drifts with the music. static ignores the audio entirely - the same latent every frame, which is your debugging friend. increase/decrease are the raw directional options, and guassian - yes, spelled that way in the source - regenerates the latent from noise each frame. "Bounce" and "flow" are the ones that look like a music visualizer.
  • image_limit - cap the number of frames rendered (-1 means all of them). This is your emergency brake.
  • latent_mod_limit - how far the latent's mean is allowed to drift, default 5. Requires a value > 0 in bounce mode or the node refuses to run; <= 0 means "no limit" everywhere else.

Then the sampler settings you already know from any KSampler: model, steps, cfg, sampler_name, scheduler, and denoise. All of ComfyUI's samplers and schedulers are offered. denoise at 1.0 with an empty latent is a clean text-to-image pass per frame; lower it and you're getting into img2img-variation territory on top of the previous latent.

The outputs. LATENTS is a batched latent - one per rendered frame - that you decode with ComfyUI's standard VAEDecode. Then it's on you to assemble the video: the pack's example workflow feeds the calculator's FPS output into SaveAnimatedWEBP, and the same idea works with any frame-assembly or video node. CHARTS is a single chart of the latent's mean across frames, which tells you at a glance whether the motion did what you expected - flat line means the audio never moved the latent.

The one piece of advice in the README, taken seriously: bypass this node (or set image_limit to something small) while you tune. The calculator, interpolator, and renderer all emit charts, so you can preview the entire flow - audio features, prompt distribution, and only then a few test frames - before committing to a full render. The pack's own documentation insists on this, and it's right: a full song at 6 fps can mean hundreds of slow generations, and discovering at frame 350 that latent_mod_limit was too low is a rough way to spend an afternoon.

Two more real-world notes. The tqdm progress bar in your console shows the modifier, prompt mean, and latent mean per frame, so it doubles as a live health check. And because the CHARTS outputs feed straight into the Image Concatenator, you can save all your diagnostic panels in one shot.

Same install as the pack: git clone https://github.com/Sorcerio/MBM-Music-Visualizer.git MBM_MusicVisualizer into custom_nodes, pip install -r requirements.txt, restart. It sits in MBMnodes/Prompts.

CategoryMBMnodes/Prompts

Inputs (14)

NameTypeDefaultDescription
promptsPROMPT_SEQ
latent_modsTENSOR_1D
seedINT00–18446744073709550000
latent_imageLATENT
seed_modeCOMBO4 options: fixed, random, increase, decrease
latent_modeCOMBO6 options: bounce, flow, static, increase, decrease, guassian
image_limitINT-1-1–18446744073709550000
latent_mod_limitFLOAT5.00-1–10000
modelMODEL
stepsINT201–10000
cfgFLOAT8.00–100
sampler_nameCOMBO34 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +28
schedulerCOMBO9 options: normal, karras, exponential, sgm_uniform, simple, ddim_uniform, +3
denoiseFLOAT1.000–1

Outputs (2)

NameTypeDescription
LATENTSLATENT
CHARTSIMAGE