PythonMusic is a Python-based software environment for learning and developing algorithmic art projects. It mirrors the JythonMusic API.
Full documentation, tutorials, and examples live at pythonmusic.org. This README covers only the essentials.
Requires Python 3.12+ and a C++ compiler (some dependencies build native code). On Linux, install portaudio first.
# Windows/macOS
pip install PythonMusic
# Linux (Debian/Ubuntu)
sudo apt-get install portaudio19-dev
pip install PythonMusic
If installation fails for lack of a compiler, install the Visual Studio Build Tools (Windows) or Xcode (macOS), then retry. See the site for full setup help.
The first time you import music, PythonMusic offers to download a default soundfont (FluidR3 GM) to a local cache for MIDI playback.
PythonMusic ships with PEM, a customized Python editor (a hard fork of IDLE). After installing, run:
pem <filename.py>
PythonMusic and PEM are free software under the GNU GPL v3 or later (see LICENSE). PythonMusic derives from JythonMusic, which is also GPLv3.
- PEM's IDLE-derived components remain under the Python Software Foundation License v2 (
LICENSE-PSF). - The bundled
nevmusemetrics component is a separate work with its own terms (seesrc/PythonMusic/nevmuse/NOTICE.txt).
For full licensing details, see LICENSE and LICENSE-PSF.