Code for the ISMIR 2024 paper "End-to-end Piano Performance-MIDI to Score Conversion with Transformers"
The code is written in Python 3.11 and relies on the following packages
- everything mentioned in
requirements.txt MuseScore: https://github.com/musescore/MuseScore (depending on your platform, please adjust the path inconstants.py)
Due to delays and difficulties merging changes with upstream versions, we currently require installing custom versions of the following packages (will be done automatically with requirements.txt):
music21: https://github.com/TimFelixBeyer/music21 (fixes tie-stripping and contains various other tweaks)score_transformer: https://github.com/TimFelixBeyer/ScoreTransformer (for score_similarity metrics and tokenization comparisons)
In addition, you must manually clone and install this package:
muster: https://github.com/TimFelixBeyer/amtevaluation.github.io (fixes various memory leak issues of the original version)
Please use this version of the ASAP-Dataset as it contains some fixes.
ASAPDataset: https://github.com/TimFelixBeyer/ASAPDataset (contains a few fixes for the ASAP dataset, make sure you select the correct commit for reproducibility and place theasap-datasetfolder into thedatafolder).ACPAS: https://cheriell.github.io/research/ACPAS_dataset/ (only downloadmetadata_R.csvandmetadata_S.csv, place them into a folder calledACPAS-datasetand put it into thedatafolder)
Afterwards, your data folder should look like this:
data
├── ACPAS-dataset
│ ├── metadata_R.csv
│ └── metadata_S.csv
└── asap-dataset
- Download the
MIDI2ScoreTF.ckptfrom GitHub ('Releases' section) and place it where you like.
- Run
dataset.pyto preprocess the datasets and populate the cache. - Run
chunker.pyto create the beat-aligned chunks. - More instructions to follow