NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Learning Separated Representations for Instrument-based Music Similarity

Yuka Hashizume, Li Li, Atsushi Miyashita, Tomoki Toda · DOI

Abstract

A flexible recommendation and retrieval system requires music similarity in terms of multiple partial elements of musical pieces to allow users to select the element they want to focus on. A method for music similarity learning using multiple networks with individual instrumental signals is effective but faces the problem that using each clean instrumental signal as a query is impractical for retrieval systems and using separated instrumental signals reduces accuracy owing to artifacts. In this paper, we present instrumental-part-based music similarity learning with a single network that takes mixed signals as input instead of individual instrumental signals. Specifically, we designed a single similarity embedding space with separated subspaces for each instrument, extracted by Conditional Similarity Networks, which are trained using the triplet loss with masks. Experimental results showed that (1) the proposed method can obtain more accurate embedding representation than using individual networks using separated signals as input in the evaluation of an instrument that had low accuracy, (2) each sub-embedding space can hold the characteristics of the corresponding instrument, and (3) the selection of similar musical pieces focusing on each instrumental sound by the proposed method can obtain human acceptance, especially when focusing on timbre.

Introduction

Music similarity is inherently subjective. While one listener might find two tracks similar due to their tempo, another might focus on specific instrumental textures, such as a "crunchy" guitar tone or a particular drum pattern. Most Music Information Retrieval (MIR) systems provide a single global similarity score, which often fails to capture these nuanced, instrument-specific preferences.

Previous attempts to address this involved training separate models for each instrument. However, this approach relies on clean instrumental "stems," which are rarely available for commercial music. The alternative—using AI-based source separation to unmix tracks—introduces digital artifacts that degrade the performance of similarity models, particularly for instruments with complex harmonic structures like the piano.

Methodology: Disentangled Embeddings from Mixed Audio

The researchers propose a single-network architecture that processes mixed audio signals but maps them into a disentangled embedding space. This approach bypasses the need for explicit source separation and avoids the quality degradation typical of artifact-heavy unmixing.

Comparison of the proposed method with conventional approaches, highlighting the shift from multiple models and source separation to a single model with multiple embeddings.

Conditional Similarity Networks (CSNs)

Instead of a monolithic vector, the model generates a 640-dimensional embedding divided into five 128-dimensional subspaces corresponding to Drums, Bass, Piano, Guitar, and "Others." To train these subspaces, the authors utilized Conditional Similarity Networks (CSNs). During training, a binary mask is applied to the embedding, forcing the network to focus on a specific instrument's subspace.

The training process using triplet loss and instrument-specific masks to define notions of similarity for different instrumental parts.

Pseudo-Mixed Training Strategy

A key innovation is the use of "pseudo-mixed" tracks. By mixing the drums from Song A with the bass and guitar from Song B, the researchers created training samples where similarity cues are only present for a single instrument. This forces the network to ignore "distractor" instruments and specialize each subspace. Additionally, a Norm Loss constraint was added to force a subspace to near-zero if that specific instrument is absent from the mix, preventing feature leakage.

Key Results

The study utilized the Slakh2100 dataset to evaluate the model against ground-truth clean signals.

  • Accuracy Gains: The proposed method significantly outperformed the baseline (source-separated signals) for difficult instruments. For instance, piano similarity accuracy reached 82.0%, nearly doubling the 43.3% achieved using conventional source separation methods.
  • Subspace Integrity: t-SNE visualizations confirmed that the model successfully clustered segments of the same song within the correct instrument subspace, even when mixed with different background instruments.
  • Human Perception: Listening tests indicated that human subjects agreed with the model's similarity rankings, particularly when focusing on timbre (the "texture" of the sound) rather than complex melodic or rhythmic patterns.

Conclusion

This research demonstrates that it is possible to learn instrument-specific music similarity directly from mixed audio by using disentangled embedding spaces. By avoiding the artifacts of source separation, the system provides a more robust and flexible tool for music discovery. Future work will aim to extend the temporal window of the model beyond the current 3-10 second segments to better capture long-term musical structures like evolving melodies and rhythmic shifts.

Summary updated

BibTeX
@inproceedings{hashizume2025learning,
  author = {Yuka Hashizume and Li Li and Atsushi Miyashita and Tomoki Toda},
  title = {{Learning Separated Representations for Instrument-based Music Similarity}},
  booktitle = {APSIPA},
  year = {2025},
  doi = {10.1561/116.20250013},
}
Figure