Skip to main content

Demonstrations and tools for music21.

Project description

music21-tools

Tools and demonstrations for music21 created by Cuthbert and his lab (cuthbertLab)

Copyright © 2004-2026 Michael Scott Asato Cuthbert, released under a BSD (3-clause) license.

Many of these tools and demonstrations were formerly in the music21 package.
They may require external packages to make them work, and some may require editing to make them work with the latest version of music21. I will attempt to update them with each new major release of music21, but there is no guarantee that they will work with any development versions along the way.

Many thanks to Christopher Ariza, Beth Hadley, Jordi Bartolomé, Daniel Manesh, Hugh Zabriskie, Jackie Rogoff, Lars Johnson, Varun Ramaswamy, Nina C. Young, Thomas Carr, Jose Cabal-Ugaz, Lisa D. Friedland, Norman Schmidt, and many others who contributed to this project.

Historical notes

Older versions of this repo included bhadley/mrjobaws/, a demonstration of using mrjob to run music21 feature extraction as a Hadoop MapReduce job on Amazon EMR. mrjob has been unmaintained since 2020 and the EMR workflow is no longer practical, so the code has been removed. It can still be found in git history at commit 311cbff under bhadley/mrjobaws/.

Older versions also included webapps/ (formerly music21.webapps), a demonstration of building webserver-based music21 tools. It depended on a version of NoteFlight that has not been available for over ten years, so the code has been removed. It can still be found in git history at commit 311cbff under webapps/. The project is described in:

Cuthbert, Michael Scott, Beth Hadley, Lars Johnson, and Christopher Reyes. "Interoperable Digital Musicology Research via music21 Web Applications," Proceedings of the Joint CLARIN-D/DARIAH Workshop, Service-oriented Architectures (SOAs) for the Humanities: Solutions and Impacts at the Digital Humanities Conference, Hamburg, Germany, July 2012.

PDF available at trecento.com.

Running the tests

uv sync           # one-time: install music21 >= 10 + dev deps
uv run pytest     # full sweep (doctests + Test classes)

A single module:

uv run pytest music21_tools/theoryAnalysis/theoryAnalyzer.py

TestExternal (interactive / display) and TestSlow (full-corpus) classes are skipped by default. Run them one method at a time via unittest:

uv run python -m unittest music21_tools.chant.chant.TestExternal.testSimpleFile

Releasing new versions

Bump the version in pyproject.toml to the new version and then:

trash dist
uv sync
uv build
uv run --with twine twine upload dist/*
git tag vXX.X
git push --tags

Contact

Michael Scott Asato Cuthbert — michael.asato.cuthbert@gmail.comtrecento.com — GitHub: @mscuthbert / cuthbertLab.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

music21_tools-10.2.0.tar.gz (1.7 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

music21_tools-10.2.0-py3-none-any.whl (978.2 kB view details)

Uploaded Python 3

File details

Details for the file music21_tools-10.2.0.tar.gz.

File metadata

  • Download URL: music21_tools-10.2.0.tar.gz
  • Upload date:
  • Size: 1.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for music21_tools-10.2.0.tar.gz
Algorithm Hash digest
SHA256 dd30ec0662f9c7a81c7ccb326272ed848a0884bfecac1836acf7e758e21e17c7
MD5 81198144354e41ffcab8d68641e9c000
BLAKE2b-256 23b18a62a90d75fc53ef5afd7ca5f0800505051223a9c48ae28398a952aeefbb

See more details on using hashes here.

File details

Details for the file music21_tools-10.2.0-py3-none-any.whl.

File metadata

  • Download URL: music21_tools-10.2.0-py3-none-any.whl
  • Upload date:
  • Size: 978.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for music21_tools-10.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2a62e94c379a57501b84f983f85f288bce0dc5f409733900260457630cd3e02c
MD5 5e9ff8bca02e1eefa0987ee00988704e
BLAKE2b-256 4bc3dcefb261c3eea59e1cae3e5844daf46a4b78805c4f24357bcc3bdadf8c20

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page