mutagen icon indicating copy to clipboard operation
mutagen copied to clipboard

Slow reading large SMF files

Open riban-bw opened this issue 3 years ago • 1 comments

I accidentally left MIDI recorder running and it created a large file (1200 minutes). The application hosting this (Zynthian) hands for several seconds whilst it parses the file (for its duration).

Is there any optimisation that could avoid excessively long parsing times?

riban-bw avatar Dec 30 '20 13:12 riban-bw

It's slow because it has to parse each note for each track to sum up the running time: https://github.com/quodlibet/mutagen/blob/master/mutagen/smf.py

It's slow, but I considered it OK at that time as it scales with the file size.

Feel free to improve it.

lazka avatar Dec 31 '20 17:12 lazka