π΅ Granular Sequencer
Granular Synthesis Meets a Drum Machine β Patterned Grains
- audio
- sequenced_audio
GranularProcessor lets grains fall freely. GranularSequencer gives them a rhythm section. It's the same granular engine, but the grains are locked to a step sequencer - so instead of a drifting cloud you get patterns: rhythmic grains, probabilistic triggers, swing, and even Euclidean rhythms. If you're making breakcore textures, glitch beats, or anything with a pulse made of noise, this is the node.
What it is
A step sequencer with steps (1 to 64) and a step_duration (0.01 to 4 seconds per step). Each step can trigger a burst of grains, so the output is a rhythmic, pulsing texture rather than a continuous one. The granular controls mirror the processor: base_grain_size (10β500 ms) and base_density (1β100 grains per second) set the character of each burst, and the sequencing layer decides when bursts happen.
The groove controls are where it gets musical. swing (β0.5 to +0.5) shifts every other step later or earlier - negative swing is the stuttery, off-kilter feel, positive is the classic hip-hop bounce. pattern_variation (0β1) randomizes the pattern each loop so it never quite repeats. And euclidean_rhythm (0β32) is the fun one: pick a number and the node spaces those triggers as evenly as possible across the steps - the same algorithm behind a lot of techno and electronic percussion. 5 triggers across 8 steps gives you that spiky, off-grid pocket. 0 turns it off and every step is even.
How it works
The sequence runs through the steps in a loop; each step evaluates a probability gate and decides whether to fire a grain burst. The optional probability (global trigger chance, 0β1) and velocity_variation (0β1, randomizes loudness per burst) add the human imperfection. Each fired burst is a mini granular event built from base_grain_size and base_density at whatever step you're on.
The one output, sequenced_audio, is the full rhythmic texture. Feed it back into a FeedbackProcessor or push it through MultiDistortion and you've got instant glitch-core material.
The inputs that matter
steps+step_duration- the tempo and length of the pattern.euclidean_rhythm- the secret weapon. Start at 5 across 8 steps and listen to what happens.probability- turn it below 1 and the pattern starts breaking up in a satisfyingly random way.
Install
Standard pack install:
cd ComfyUI/custom_nodes
git clone https://github.com/eg0pr0xy/comfyui_noisegen.git
cd comfyui_noisegen
pip install -r requirements.txt
(Windows embedded Python: ComfyUI\python_embeded\python.exe -m pip install -r requirements.txt.) Or ComfyUI Manager β search "NoiseGen" / eg0pr0xy. No models, no keys.
Gotchas
Remember the pack rule: the pip install is mandatory (scipy at module load - skip it and the whole pack fails to register). Sequencing adds statefulness, so if your pattern sounds identical every loop, that's pattern_variation at 0 doing its job - bump it up if you want evolution. And Euclidean rhythms above the step count (say, 20 over 16 steps) wrap into denser sub-patterns rather than erroring, which is fine, just surprising the first time. Match your input length to a multiple of the pattern length so the whole thing loops cleanly.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| audio | AUDIO | Input audio for sequenced granular processing | |
| steps | INT | 81β64 | Number of sequence steps |
| step_duration | FLOAT | 0.1250.01β4 | Duration per step in seconds |
| base_grain_size | FLOAT | 10010β500 | β |
| base_density | FLOAT | 10.01β100 | β |
| pattern_variation | FLOAT | 0.500β1 | Pattern randomization amount |
| swing | FLOAT | 0.00-0.5β0.5 | Groove timing offset |
| amplitude | FLOAT | 0.800β2 | β |
| probabilityopt | FLOAT | 1.000β1 | Global trigger probability |
| velocity_variationopt | FLOAT | 0.200β1 | β |
| euclidean_rhythmopt | INT | 00β32 | Euclidean rhythm pattern (0 = off) |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| sequenced_audio | AUDIO | β |