Nodes/RyanOnTheInside/Beat Wave Feature Extractor βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜
ComfyUI Node

Beat Wave Feature Extractor βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜

Turn a song's beat into an LFO you can drive anything with

By ryanontheinsideΒ·Created 2 years agoΒ·Updated 5 months agoΒ· 852
Beat Wave Feature Extractor βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜
  • audio
  • feature
  • frame_count
β—„extraction_methodβ–Ύβ–Ί
β—„frame_rate30.0β–Ί
β—„frame_count0β–Ί
β—„width512β–Ί
β—„height512β–Ί
β—„beat_divisor1β–Ί
β—„phase0.00β–Ί
β—„duty_cycle0.50β–Ί
β—„time_signature4β–Ί

This is the node behind a lot of the "everything pulses to the beat" look you see in audio-reactive ComfyUI clips. Rather than pulling a raw amplitude curve out of your audio, it locks onto the beat and generates a clean, shaped waveform - sine, square, sawtooth, whatever - synced to that rhythm. Think of it as a synth LFO that tunes itself to your song instead of running at a fixed rate you have to guess.

This whole reactive-audio-to-visual pipeline is a real, if niche, corner of the ComfyUI ecosystem - the community's other well-known example is Yvann's audio-reactive node set, which separates stems and drives keyframe transitions, ControlNet strength, and motion amount from the resulting weights. RyanOnTheInside's FEATURE system (this node is one of several "Sources" that produce a FEATURE) is built for the same job: a driveable numeric signal you can plug into other nodes' parameters instead of a fixed value.

How it works

It analyzes the audio input to find the beat, then generates a periodic waveform locked to that beat grid using whichever shape you pick in extraction_method. beat_divisor subdivides or multiplies the beat rate you're syncing to (a value of 2 fires twice as often, a negative value slows it to once every couple of beats), time_signature tells it how many beats make up a bar for anything that needs bar-level shaping, phase offsets where in the cycle the wave starts, and duty_cycle controls the on/off ratio for the square wave shape specifically. The result comes out as a per-frame FEATURE curve at your chosen frame_rate, ready to drive another node's parameter.

The inputs and outputs that matter

  • audio (AUDIO, required) - the track to extract the beat from.
  • extraction_method - the waveform shape: sine, sawtooth, triangle, square, exponential_decay, or ramp.
  • beat_divisor (default 1, range -8 to 16) - subdivide or multiply the detected beat rate.
  • phase (default 0, range 0–1) and duty_cycle (default 0.5, range 0.01–0.99) - standard oscillator controls: where the cycle starts, and (for square) how much of each cycle is "on."
  • time_signature (default 4, range 1–12) - beats per bar, for anything shape-wise that resets on the bar.
  • frame_rate, frame_count, width, height - the usual Feature-source plumbing: output frame rate, how many frames to generate (0 typically means derive it from the audio length), and dimensions carried along for compatibility with the rest of the Feature pipeline.

Outputs: a FEATURE (the wave itself) and an INT (frame_count, useful for wiring the same length into other nodes downstream).

How to install it

Via ComfyUI Manager: search "RyanOnTheInside," install, restart. By hand:

cd ComfyUI/custom_nodes
git clone https://github.com/ryanontheinside/ComfyUI_RyanOnTheInside.git
cd ComfyUI_RyanOnTheInside
pip install -r requirements.txt

then restart. Audio processing here leans on the requirements.txt's scipy/scikit-image stack rather than a downloaded model, so there's no weight file to fetch for this specific node.

Common issues & troubleshooting

The wave doesn't line up with the actual beat. Beat detection on messy or heavily processed mixes isn't perfect - if the sync feels off, try beat_divisor at 1 first to confirm baseline detection before layering subdivisions on top, and sanity-check on a track with a very clear, steady beat if you're unsure whether it's your settings or the detector struggling with the source.

Output feels choppy or stepped. Check frame_rate matches what the rest of your pipeline is actually running at - a mismatch here means the wave gets sampled at the wrong granularity relative to your video frames.

Square wave doesn't look like a clean 50/50 pulse. That's duty_cycle - it defaults to 0.5 but is very easy to nudge accidentally; reset it if the on/off ratio looks skewed.

CategoryRyanOnTheInside/FlexFeatures/Sources/Audio

Inputs (10)

NameTypeDefaultDescription
extraction_methodCOMBO6 options: sine, sawtooth, triangle, square, exponential_decay, ramp
frame_rateFLOAT30.01–120β€”
frame_countINT0β€”
widthINT51264–4096β€”
heightINT51264–4096β€”
audioAUDIOβ€”
beat_divisorINT1-8–16β€”
phaseFLOAT0.000–1β€”
duty_cycleFLOAT0.500.01–0.99β€”
time_signatureINT41–12β€”

Outputs (2)

NameTypeDescription
featureFEATUREβ€”
frame_countINTβ€”