🎵 Frequency Extractor (S42)
Turn any audio track into bass, mid, and treble curves your whole graph can use
- audio
- bass_curve
- mid_curve
- treble_curve
This is the node that makes the rest of the audio-reactive stuff in S42-CutFlow possible, and it's the one I'd actually reach for out of the whole latent-audio pile. Feed it any AUDIO - a track you loaded, one you generated, whatever - and it hands you back three curves: bass_curve, mid_curve, and treble_curve, each a list of floats from 0 to 1 with one value per video frame.
The mechanism is straightforward and worth knowing because it tells you what the numbers mean. It takes your waveform, mixes it to mono, and splits it into three bands with proper biquad filters from torchaudio: everything below bass_cutoff (default 250 Hz) drives the bass curve, everything above treble_cutoff (default 4000 Hz) drives the treble, and whatever's left in the middle is the mid. Each band is then squared and averaged over frame-sized windows (one window per frame at your fps), and normalized so the loudest moment is 1.0. So these are relative energy envelopes, not absolute loudness - a curve hitting 1.0 just means "this band was the loudest it got during this clip."
The two inputs you'll actually touch:
fps- must match your video's frame rate, because that's what decides how long each curve is. Set it to 24 for a 24fps clip and you get exactly one bass value per frame, which is what makes the curves directly consumable by per-frame schedules.bass_cutoff/treble_cutoff- where the bands split. Defaults are sane for most music. Lowerbass_cutoffto ~150 and the bass curve only tracks the really deep stuff; raisetreble_cutoffand the treble curve starts swallowing the mid.
What do you do with three normalized float lists? That's the whole point of the pack's audio-sync layer: run them into S42_AudioReactiveScheduler to map them onto a value range for driving parameters, feed one straight into S42_AudioLatentWobble to pulse a latent, or wire the values into anything in ComfyUI that consumes a float schedule. Bass is the classic choice for visible pulse - it's where the kick drum lives - but mid curves track vocals and treble tracks hats and cymbals, so picking the right band changes the feel of the reaction entirely.
One practical note: because the curves are normalized per-clip, a quiet acoustic song and a brickwalled EDM drop both produce peaks at 1.0. That's usually what you want for reactivity, but if you're comparing loudness across clips, this isn't your node.
Installing it
S42-CutFlow install, same as every node here: ComfyUI Manager → search "S42 CutFlow" → Install → restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/GeekyGhost/S42-CutFlow.git
pip install -r S42-CutFlow/requirements.txt
The only hard requirement is opencv-python-headless; the filters here run through torchaudio, which ComfyUI already ships. Restart, and the "[S42 CutFlow] Loaded ..." line in the console is your confirmation.
Where you'll actually use it
If you want video that visibly reacts to music, this is the foundation node - everything downstream starts with one of these three curves. It's deterministic, CPU-cheap, and it turns a wall of samples into exactly the shape your graph can consume.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| audio | AUDIO | Audio track to analyze. | |
| fps | FLOAT | 24.001–120 | — |
| bass_cutoff | INT | 25020–1000 | Frequencies below this will drive the bass curve. |
| treble_cutoff | INT | 40001000–10000 | Frequencies above this will drive the treble curve. |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| bass_curve | FLOAT | — |
| mid_curve | FLOAT | — |
| treble_curve | FLOAT | — |