-
Notifications
You must be signed in to change notification settings - Fork 119
Description
In the current implementation of chord.encode, the bass note is forced to be added into the chord bitmap, resulting in A:maj/2 encoded equivalently as A:maj(2)/2. As a result, A:maj/2 will be considered as 'X' chord in majmin and sevenths, and under triads metric, it is considered different from A:maj, which is a bit counter-intuitive because both of them are major chords - just the bass notes are different. And it is even different from A:maj(9), because the ninth-note is always reduced. The "correct" answer is A:maj(2)
In[1]: mir_eval.chord.triads(['A:maj/2'], ['A:maj'])
Out[1]: array([0.])
In[2]: mir_eval.chord.triads(['A:maj/2'], ['A:maj(9)'])
Out[2]: array([0.])
In[3]: mir_eval.chord.triads(['A:maj/2'], ['A:maj(2)'])
Out[3]: array([1.])
The counter argument will be that bass note plays such an important role that it should never be ignored, which I guess is why it is forced to be added into the bitmap. But this then conflicts with the idea of having inversion and no-inversion as two separate metrics.
I am open to discussion since changing that basically requires changing the encoding logic of chords and will make many published results not comparable anymore. My opinion is that the bass note is independent from the bitmap of the chord encoding, and therefore, A:maj/2, A:maj/4, ... should all be equivalent to A:maj, when not considering inversion.