home/ atoms/ pitch-tempo-augmentation-separation-training

On-the-fly pitch and tempo shift augmentation improves separation model generalisation across musical keys and tempos

MUSDB-HQ contains 150 songs drawn from specific genres, keys, and tempos. Demucs’s RepitchedWrapper applies random pitch shifts (±2 semitones) and tempo changes (±12%) to each stem during training, using soundstretch (a phase-vocoder-based time-pitch tool). Crucially, the same pitch/tempo change is applied consistently across all stems in a track so the reconstructed mix remains coherent. Vocals get special treatment via the -speech flag in soundstretch, which uses a speech-optimised algorithm that preserves formants better than musical mode.

Examples

From demucs/repitch.py:

def repitch(wav, pitch, tempo, voice=False, ...):
    # pitch in semitones, tempo as % delta
    # voice=True uses soundstretch -speech flag

Assessment

Why is it important to apply the same pitch shift to all stems simultaneously? What would happen if drum and bass stems were shifted by different amounts?

“tempo is a relative delta in percentage, so tempo=10 means tempo at 110%!”
corpus · demucs-music-source-stem-separation · chunk 45