Closed ostrosablin closed 8 years ago
Looks like xm format has embedded soundfont information, which my network can't really handle. My network is only designed to take in a raw note stream, so I don't think it would easily work with this network.
Perhaps some other, more complex network architecture would work well with xm files.
Yes, all samples used in track are embedded into xm file. But actually, only note stream is necessary to train the network. Those samples could be just considered to be separate insruments. Pretty much like instrument ID in MIDI, xm insrument ID is just a digit - reference to particular instrument slot. You can swap, for example, a piano sample with a violin sample and track will still sound the same, because notes don't change. So it should be still possible to train network on xm files. Embedded sample data could be ignored completely and instrument ID could be used to split track into separate note streams for each instrument.
In any case, note stream is the most interesting part of the song and it could be later reproduced using similar sounding or completely different instruments.
I've drawn what I mean over the screenshot of MilkyTracker - one of tracker music editors. xm tracks have several channels. In each channel, any number of different xm instruments could be playing. In note slots, there could be either note, note off, or empty space. For note record, there's a note, instrument number, and (optionally) volume and effect.
While training from MIDI files is good, there's a vast tracker music library, with absolute majority being xm format files. It might be interesting to experiment with creation of tracker-style music with neural network.
There's a xm to midi converter on the net, but it isn't any good. However, it's possible to read xm files directly and there's even ready solution for that in python:
https://sourceforge.net/p/xmp/libxmp-python/ci/master/tree/examples/
Not only it allows to read xm files with python, but it also support several dozens of tracker music formats. Entire modarchive is about 50 GB of music and most of it will be readable with libxmp-python.