YUE_Stage_B_Sampler
The node that finally gives you an mp3
- stage1_set
- model
- audio
- string
Four nodes into the YuE graph, this is where you actually hear something. YUE_Stage_B_Sampler is the finish line: it runs the Stage B upsampler over your scratch track, decodes it through the xcodec vocoder, mixes the vocal and instrumental stems, and hands you an audio waveform plus a path to a saved file. If you've been waiting to hear your lyrics sung, this is the moment.
How it works
Stage A's output (stage1_set) holds the interleaved vocal/instrumental codec tokens. Stage B - loaded by YUE_Stage_B_Loader - upsamples those into a much richer representation, then this node decodes each stem through the xcodec vocoder decoders. That's what vocal_decoder_ckpt and inst_decoder_ckpt are for: the decoder_131000.pth and decoder_151000.pth files from ComfyUI/models/yue. The node first writes a 16kHz reconstruction and mixes the stems, then runs the upsampler vocoder for a 44.1kHz mix, and finishes with a low-frequency energy-match pass to clean up the seams. That final step is why rescale exists - leave it on unless you have a reason not to.
Inputs that matter
stage1_set- from YUE_Stage_A_Sampler'sstage1_setoutput. Nothing happens without it.model- from YUE_Stage_B_Loader.vocal_decoder_ckpt/inst_decoder_ckpt- dropdowns that only listmodels/yuefiles containing "131" / "151". If they show only "none", the decoder files aren't where the code looks and the vocoder will fail.rescale- on by default; normalizes loudness on the final mix.
Outputs
audio(AUDIO) - a 44.1kHz waveform you can wire straight into a PreviewAudio node or any audio playback node. The bundled example workflow feeds exactly this, and it's the fun part: hit run and your song comes out the other end.string- the full path to the final saved mp3 inComfyUI/output, for when you want the actual file.
Install and models
Same shared pack install as the rest of the chain - clone, requirements, restart:
cd ComfyUI/custom_nodes
git clone https://github.com/smthemex/ComfyUI_YuE
cd ComfyUI_YuE
pip install -r requirements.txt
(ComfyUI Manager → "ComfyUI_YuE" also works.) This node is the reason decoder_131000.pth and decoder_151000.pth must be in ComfyUI/models/yue - without them there's no vocoder. ckpt_00360000.pth and the semantic model are needed too, and the Stage B repo downloads itself on first load. Total model footprint is roughly 15GB, so budget disk before you start.
Gotchas
- Decoder dropdowns stuck on "none". It's the "131"/"151" filename filter again - put both
.pthfiles inmodels/yuebefore you go looking for them. - OOM in Stage B. If the upsampler runs out of VRAM, lower
stage2_batch_sizeon the Stage B Loader rather than fighting this node. - Missing stage1 files.
stage1_setis a real object wire, but the underlying tokens live on disk. If you re-run this node against a stale graph, make sure YUE_Stage_A_Sampler actually ran in this session or the.npyfiles won't exist. - It's slow, and that's normal. Stage B is a second full model pass, and the mix/vocoder steps add real time on top of Stage A's. A 30-second song on a modest GPU is a minutes-long operation; don't mistake it for a hang.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| stage1_set | STAGE_SET | — | |
| model | MODEL_YUE_B | — | |
| vocal_decoder_ckpt | COMBO | 1 options: none | |
| inst_decoder_ckpt | COMBO | 1 options: none | |
| rescale | BOOLEAN | true | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| audio | AUDIO | — |
| string | STRING | — |