yt

lundi 14 juillet 2025

PYTHON ET MIDI

 

MIDI Mania

  • mido - MIDI Objects for Python. A library for working with MIDI 1.0 ports, messages and files.

  • pygame.midi - is a portmidi wrapper orginally based on the pyportmidi wrapper. Also pygame.music can play midi files. Can get input from midi devices and can output to midi devices. For osx, linux and windows. New with pygame 1.9.0. python -m pygame.examples.midi --output

  • pyMIDI - Provides object oriented programmatic manipulation of MIDI streams. Using this framework, you can read MIDI files from disk, build new MIDI streams, process, or filter preexisting streams, and write your changes back to disk. If you install this package on a Linux platform with alsalib, you can take advantage of the ALSA kernel sequencer, which provides low latency scheduling and receiving of MIDI events. SWIG is required to compile the ALSA extension sequencer extension. Although OS-X and Windows provide similar sequencer facilities, the current version of the API does not yet support them. Some buggs are remaining in this package (for example when trying to delete a track), it has not been updated since 2006. This package is by Giles Hall. A sourceforge download.

  • midi.py - (DEAD LINK) - Python MIDI classes: meaningful data structures that represent MIDI events and other objects. You can read MIDI files to create such objects, or generate a collection of objects and use them to write a MIDI file.

  • MIDI.py - This module offers functions: concatenate_scores(), grep(), merge_scores(), mix_scores(), midi2opus(), midi2score(), opus2midi(), opus2score(), play_score(), score2midi(), score2opus(), score2stats(), score_type(), segment(), timeshift() and to_millisecs(). Uses Python3. There is a call-compatible Lua module.

  • PMIDI - The PMIDI library allows the generation of short MIDI sequences in Python code.The interface allows a programmer to specify songs, instruments, measures, and notes. Playback is handled by the Windows MIDI stream API so proper playback timing is handled by the OS rather than by client code. The library is especially useful for generating earcons.

  • portmidizero - portmidizero is a simple ctypes wrapper for PortMidi in pure Python.

  • PyChoReLib - Python Chord Recognition Library. This is a library that implements the transformation from a list of notenames to a chord name. The system can be taught new chords by example: tell it that ['c', 'e', 'g'] is called a 'C' chord, and using its built-in music knowledge it immediately recognizes all major triads in all keys and all inversions/permutations. Comes with a real-time midi-input demo program (needs PyPortMidi).

  • PyMIDI - The MIDI module provides MIDI input parsers for Python. Package not updated since 2000.

  • PyPortMidi - PyPortMidi is a Python wrapper for PortMidiPortMidi is a cross-platform C library for realtime MIDI control. Using PyPortMidi, you can send and receive MIDI data in realtime from Python. Besides using PyPortMidi to communicate to synthesizers and the like, it is possible to use PyPortMidi as a way to send MIDI messages between software packages on the same computer. PyPortMidi is now maintained at http://bitbucket.org/aalex/pyportmidi/

  • PythonMIDI - The Python Midi package is a collection of classes handling Midi in and output in the Python programming language.

  • PySeq - Python bindings for ALSA using ctypes

  • milk - Superceding the older Nam, milk provides Python with classes representing key MIDI sequencer components: MIDI I/O, EventLists, Plugins and a realtime Flow class. The components can be freely interconnected in a fashion very similar to physical MIDI cabling, however the milk event system is not limited to MIDI events alone; you can define your own extensions should the need arise. Website says it is unpolished and unfinished.

  • Numula - a Python library for making computer-rendered music with nuance: variations in dynamics, timing, and articulation as are typical of human performance. Numula can be used for algorithmic composition or to render human compositions.

  • pyrtmidi - rtmidi provides realtime MIDI input/output across Linux (ALSA), Macintosh OS X, SGI, and Windows (Multimedia Library) operating systems. It is very fast, has a clean and pythonic interface, and supports virtual ports, according to author Patrick Kidd. In fact it is a wrapper for Gary Scavone's rtmidi from here, rather than the address on this website:

  • rtmidi-python - Another RtMidi wrapper.

  • winmidi.pyd - A demo? of a Python extension interfacing to the native windows midi libs that developed from earlier attempts.

  • win32midi - Some Python samples to demonstrate how to output MIDI stream on MS windows platform. Unlike previous links, these samples playback MIDI by directly calling the Win32 MIDI APIs without an intermediate portable library. It provides a simple player class for playing with MIDI sound using the synthesizer on the soundcard/onboard soundchip. A sample script is provided for testing it out. As it is still a work in progress, bugs are expected.

  • midiutil - A pure Python library for generating Midi files

  • Pyknon - Pyknon is a simple music library for Python hackers. With Pyknon you can generate Midi files quickly and reason about musical proprieties.

  • Desfonema Sequencer - A tracker minded MIDI sequencer for Linux (ALSA) written in Python/PyGTK

  • python-music-gen - Simple library to generate midi patterns from numbers. Useful for building generative music tools.

  • fluidsynth-gui - Graphical User Interface for FluidSynth, and an alternative to Qsynth.

  • Partitura - Partitura (see also Music Notation, Music Analysis) supports reading and writing MIDI. It supports distinct representations of MIDI data that encodes musical scores (and has e.g. meaningful key/time signatures, and metrical times/durations), and MIDI data that encodes a performance.

Aucun commentaire:

Enregistrer un commentaire