This really improves the loudness of the output with multiple notes while being a nice simple algorithm to implement.
MidiTrack.error_location