Exploring Sampling Techniques for Generating Melodies with a Transformer Language Model
Mathias Rose Bjare, Stefan Lattner, Gerhard Widmer

TL;DR
This paper investigates how different sampling techniques affect the musical qualities of melodies generated by a transformer model trained on Irish folk music, revealing trade-offs between diversity and structure under various conditions.
Contribution
The study compares multiple sampling strategies for music generation with transformers, highlighting their effects on musical diversity and structure in different performance scenarios.
Findings
Probability truncation can limit diversity in optimal conditions.
Truncation techniques may yield more musical samples when the model performs poorly.
Different sampling methods impact the balance between musical variety and structural coherence.
Abstract
Research in natural language processing has demonstrated that the quality of generations from trained autoregressive language models is significantly influenced by the used sampling strategy. In this study, we investigate the impact of different sampling techniques on musical qualities such as diversity and structure. To accomplish this, we train a high-capacity transformer model on a vast collection of highly-structured Irish folk melodies and analyze the musical qualities of the samples generated using distribution truncation sampling techniques. Specifically, we use nucleus sampling, the recently proposed "typical sampling", and conventional ancestral sampling. We evaluate the effect of these sampling strategies in two scenarios: optimal circumstances with a well-calibrated model and suboptimal circumstances where we systematically degrade the model's performance. We assess the…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsMusic and Audio Processing · Hydrological Forecasting Using AI
