To understand how to animate from a MIDI file, it can be useful to visually find the tracks and notes in those tracks. This is the purpose of this article. Here you can find the sample blend file :
https://github.com/Patochun/Samples/blob/main/MIDI-STD-GRID.blend

The Node tree is simple to use. Three nodes are usefull :
Node | Usage |
Read MIDI File | Pickup your own MIDI file |
NoteCount | Number of notes you will see in X axis |
LowerNote | First note (this is the same number for all tracks) |
With NoteCount and LowerNote you have control of a window on the notes on the x axis. Tracks 0 to track n of your MIDI file are in the Y axis. Track 0 is the one at the bottom when viewed from above (7)
So from here you have a view of your MIDI music, tracks and notes used. You also have a model of using MIDI nodes using a loop.
Thank you for your attention and think of me when you create your first animation.
One of my last animation :