First of all, thanks a lot for this module! I don't know if you check this page anymore, but I've been having trouble running some of your code, specifically example_transpose_octave.py . It fails because it can't find the files you refer to, but when I change it in order to use my files, it fails with the following message:
Traceback (most recent call last):
File "example_transpose_octave.py", line 39, in <module>
midi_in.read()
File "/home/anthony/Software/python/midi/midi/MidiInFile.py", line 48, in read
p.parseMTrkChunks()
File "/home/anthony/Software/python/midi/midi/MidiFileParser.py", line 169, in parseMTrkChunks
self.parseMTrkChunk() # this is where it's at!
File "/home/anthony/Software/python/midi/midi/MidiFileParser.py", line 118, in parseMTrkChunk
dispatch.meta_event(meta_type, meta_data)
File "/home/anthony/Software/python/midi/midi/EventDispatcher.py", line 269, in meta_event
stream.sequencer_specific(meta_data)
File "/home/anthony/Software/python/midi/midi/MidiOutFile.py", line 390, in sequencer_specific
self.meta_slice(SEQUENCER_SPECIFIC, data)
NameError: global name 'SEQUENCER_SPECIFIC' is not defined
I have no idea about the purpose of MidiOutFile.sequencer_specific(...), but commenting the code it contains fixes that problem. Hope this is useful to someone.
First of all, thanks a lot for this module! I don't know if you check this page anymore, but I've been having trouble running some of your code, specifically example_transpose_octave.py . It fails because it can't find the files you refer to, but when I change it in order to use my files, it fails with the following message:
Traceback (most recent call last):
File "example_transpose_octave.py", line 39, in <module>
midi_in.read()
File "/home/anthony/Software/python/midi/midi/MidiInFile.py", line 48, in read
p.parseMTrkChunks()
File "/home/anthony/Software/python/midi/midi/MidiFileParser.py", line 169, in parseMTrkChunks
self.parseMTrkChunk() # this is where it's at!
File "/home/anthony/Software/python/midi/midi/MidiFileParser.py", line 118, in parseMTrkChunk
dispatch.meta_event(meta_type, meta_data)
File "/home/anthony/Software/python/midi/midi/EventDispatcher.py", line 269, in meta_event
stream.sequencer_specific(meta_data)
File "/home/anthony/Software/python/midi/midi/MidiOutFile.py", line 390, in sequencer_specific
self.meta_slice(SEQUENCER_SPECIFIC, data)
NameError: global name 'SEQUENCER_SPECIFIC' is not defined
I have no idea about the purpose of MidiOutFile.sequencer_specific(...), but commenting the code it contains fixes that problem. Hope this is useful to someone.