This repository includes the core of Legatofy interface. It was developed for the master thesis at Universitat Pompeu Fabra in 2018.
- Ableton Live with Max for Live (tested on 10)
- IRCAM R-IoT (Bitalino), or any 3D acceleration sensors that can send data over UDP in OSC protocol.
- MuBu library for Max (available with a Max/MSP package manager).
- The MIDI keyboard that can communicate with Ableton
- Wireless Router
legato_player.amxd
: this file is a Max for Live patch which will be loaded by Ableton Livelinear_regression.js
: the legato_player patch will load this javascript for linear regression. The javascript is written specifically for Max/MSP, and thus it is not compatible with a general web browser.trained_model.json
: The legato detection model trained with the HHMM (hierarchical hidden Markov model) from the MuBu library. It was trained with author's hand motions.
legato_player.amxd
andlinear_regression.js
must be placed in a directory:Ableton/User Library/Presets/MIDI Effects
. The location of the Ableton folder may differ for users.- Max for Live should have the MuBu library installed through a package manager.
- Start Ableton Live and connect it with the MIDI keyboard.
- Ableton Live requires one track of Grand Piano. Add a legato_player MIDI effect onto the Grand Piano track.
- Connect all IRCAM R-IoT sensors through a router, and check if the histogram on the MIDI effect panel shows any movements. (Refer to the IRCAM R-IoT website about the set up of a router and UDP connection)
- The trained model has to be imported. Press the button
import_model
and loadtrained_model.json
. - Everything is set up. Press toggle
enable_legatofy
to use the system.
The information panel of Max for Live shows what's happening while using the interface. The histogram shows jerky movements of a hand in three dimensions. The legato message shows whether the current motion is considered legato or not. The legatofy is only active when the legato is true. The reset
button serves to wipe out the "legatofied" trend, and calculates it again from the blank.
The legatofy uses linear regression to determine whether a played MIDI velocity is a mistake or not. This might not be flexible enough when changing a velocity in a large scale suddenly. As a workaround, reset
button will discontinue this behavior. This issue will be improved in a next version
Please open a new issue, and I'll answer you as much as I can.