ferraus midi split-tracks
One file per track or channel
Synopsis
ferraus midi split-tracks <input> [options] [-o <output>]
What it does
Writes one MIDI file per note-bearing track (roles track1..N) or per channel (ch1..16). Tempo, time and key signatures are copied into every part.
Examples
parts/song.track1.mid, parts/song.track2.mid, ...
ferraus midi split-tracks song.mid --outdir parts
One file per channel
ferraus midi split-tracks song.mid --by channel -o song.mid --outdir parts
Split by track and list the written files as JSON
ferraus midi split-tracks band.mid --by track --outdir stems_midi --json
Options
| Flag | Type | Default | Meaning |
|---|---|---|---|
--by | track | channel | track | Split by track or by MIDI channel |
Global options
Every command also accepts the global options (-o, --json, --dry-run, --overwrite, --progress, ...). See Global options.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | Processing failed |
| 2 | Usage or parameter error |
| 3 | Input missing or unreadable |
| 8 | Cancelled |
| 70 | Internal error (bug) |
Common mistakes
- Forgetting that outputs are never overwritten: pass
--overwriteor a new-opath when re-running.
For models
- MCP tool:
ferraus_midi_split_tracks - Schema:
ferraus schema midi split-tracks - Pipeline:
{ op: midi split-tracks, args: { ... } }(flag names with_instead of-) - fx stage: no
{"command": "midi split-tracks", "defaults": {"by": "track"}}