Ratioscores are designed to explore and test tunings for music composition. This website allows online editing and rendering of the scores into MIDI and MP3 files, but you can also use the command-line converter for batch processing on your own computer.

The structure of a ratioscore is based on the Humdrum file format: time progresses downwards in the file, and columns (called spines in Humdrum terminology) are used to encode multiple streams of time-sequenced data in parallel, with each row representing a simultaneity across all spines. All pitch data is stored in up to 15 **ratio spines, while the timeline can be expressed in multiple formats depending on the best one for your application. Percussion can also be added to the score using one or more **drum spines. Other spine types will be ignored, and can be used for general comments for example.

To get started, read the pitch and time pages to observe how to represent time and pitch. Visit the score generator page to create an empty score to fill in with your own notes and timings.


Ratioscore was designed as a composition prototyping system for The Answers by Julie Zhu. Here is a performance of it by the JACK Quartet in December 2020:

Below is the prototype for the final score (first minute of the piece before dynamics, glissandos and articulations were added). A clarinet sound is used below since it has less vibratio than the string instruments in the MIDI player used to create the synthetic performance.

The Ratioscore was first converted into MIDI and then loaded into Sibelius to quantize note durations into notatable rhythms and to add HEJI accidentals.


Ratioscores was presented at the TENOR 2021 conference.

Software and website

Ratioscores on this website are converted into MIDI files using this software. After converting into MIDI files, MP3s are generated for this website using timidity, although any MIDI syntheizer should work.

The software adjusts the tuning of each note with pitch-bend message to allow for non-equal temperament pitches. Glissandos up to one octave are also possible, with the convert automatically adjusting the pitch-bend depth to accomodate the widest glissando in a part.

This website is hosted on Github and uses Jekyll for page templating. Here are the source files for the website. The Ratioscore to MIDI/MP3 conversion occurs on the server side using this CGI script.

In the CGI script, the command ratioscore -r converts a Ratioscore into a MIDI file, with the -r option outputting the MIDI file to standard output (so that the CGI script does not need to store any intermediate files).

To convert to MIDI, the command is:

ratioscore -r -x630 | timidity - -m60000 --preserve-silence -Ow -o - | lame - -b64 -

This command first converts a Ratioscore to MID, then converts the MIDI into a WAVE audio file, then the WAVE file is converted into an MP3. Options:

ratioscore -r print MIDI file to standard output
    -x603 limit output to 630 seconds.
timidity -m60000
    --preserve-silence keep any starting silence from the MIDI file.
    -Ow output as WAVE file.
    -o - output WAVE file to standard output.
lame - Read from standard input
    -b64 64 kbits/second
    - print to standard output

Bug reports and feature requests

Bug reports and feature requests can be submitted to the Ratioscore repository on Github.