Clara: A Neural Net Music Generator

Using an AWD-LSTM network from the FastAI library as the generator model then input music sheet and generate music.

Clara: A Neural Net Music Generator

Clara is an LSTM that composes piano music and chamber music. It has some parallels to Google’s Magenta project, although it’s an entirely separate project, and uses PyTorch, MIT’s music21, and the FastAI library. I use a 62 note range (instead of the full 88-key piano), and I allow any number of notes to play at each musical time step (in contrast with many generation models which insist on having always exactly 4 notes at a time, or in having much smaller note ranges). I trained my models using midi samples from Classical Archives, although the code should work for any piano midi files, as well as for many chamber music files.The code is available here. In particular, take a look at BasicIntro.ipynb, a Jupyter Notebook where you can create your own musical generations with my pretrained model.A more detailed write-up of this project is available here. Try guessing which samples are human and which are AI here.

  • Author:
    Open AI, Christine Payne
  • Tags:
TOP