
music21 Streams, Corpus, and Meter Features
Michael Scott Asato Cuthbert, teaching MIT's 21M.383 Computational Music Theory and Analysis, walks through core components of the music21 Python toolkit for analyzing musical scores. He demonstrates Stream objects, the data structure that holds notes, chords, and other musical elements in sequence, then shows how to pull works from music21's built-in Corpus of encoded scores for analysis. The session closes with Meter features, covering how the toolkit represents time signatures and metrical structure programmatically. Cuthbert works through live code examples, showing how these three pieces fit together as the foundation for computational analysis of musical scores later in the course. It is a focused, hands-on session aimed at students already working in the music21 environment rather than a general introduction to music theory.