Downloads · 30 days
0
Rreitsma/minimax-music3-ensemble-blocks
minimax-music3-ensemble-blocks is a text-to-audio model from Rreitsma. Use it for the text-to-audio task on the model card, and read the license before you ship it in a product. It is set up for diffusers. The card lists the license as apache-2.0.
Render K variations of one prompt in a single batched pass — the marginal variation is nearly free.
Downloads · 30 days
0
Access
Public
Updated Aug 18, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py18.6 KB · 78%
From the Hugging Face model README
Render K variations of one prompt in a single batched pass — the marginal variation is nearly free.
The MiniMax Music 3 autoregressive stage reads the full 8B language model plus seven 0.6B depth-decoder passes (~23GB of weights) for every audio frame at 25fps: it is memory-bandwidth bound, and that read costs the same whether it serves one variation or four. These blocks decode K variations in lockstep (batch 2K rows), sharing the dominant cost. The flow-matching stage batches across variations too (grouped by exact frame count — no padding).
Measured with THIS block on an RTX 4090 (24GB, bf16, diffusers main, warm, 15s songs, same prompt/seeds):
| variations | total | per variation |
|---|---|---|
| 1 | 28.9s | 28.9s |
| 2 | 34.9s | 17.5s (1.65x) |
| 3 | 41.5s | 13.8s (2.1x) |
Each additional variation costs ~6s on a ~29s base — the marginal take is ~21% of a solo render. Discussion: diffusers#14486.
import torch
from diffusers.modular_pipelines import ModularPipelineBlocks, ComponentsManager
blocks = ModularPipelineBlocks.from_pretrained(
"Rreitsma/minimax-music3-ensemble-blocks", trust_remote_code=True
)
manager = ComponentsManager()
manager.enable_auto_cpu_offload(device="cuda")
pipe = blocks.init_pipeline("MiniMaxAI/MiniMax-Music3", components_manager=manager)
pipe.load_components(dtype=torch.bfloat16)
out = pipe(
prompt="Genre: acoustic pop. BPM: 96. Key: C major. Warm female vocals, fingerpicked guitar.",
lyrics="[verse]\nMorning light filtering through the pine\n[chorus]\nSoftly the world begins to breathe",
audio_duration=60.0,
num_variations=3,
seed=7, # variation i uses seed + i; omit for random seeds
output="audios",
)
# out: list of float32 stereo waveforms, one per variation, 44.1kHz, (channels, samples)
duration x num_variations (KV cache). On 24GB:
3 variations up to ~1 minute is comfortable; use fewer variations for longer
songs. An early EOS in one variation freezes its rows at no cost.Apache-2.0 (portions derived from the diffusers MiniMax Music 3 modular pipeline, Copyright 2026 The MiniMax Team and The HuggingFace Team). Model weights are MiniMax's, CC BY 4.0, fetched separately from MiniMaxAI/MiniMax-Music3.
Built with Claude (Fable 5 Max) following a request from the diffusers maintainers in #14486.