Closed yocontra closed 5 months ago
Found this paper from this year https://www.nature.com/articles/s41597-023-02410-w
They actually built out converters to support a bunch of notations and convert them all to Harte - https://github.com/smashub/choco/tree/main/choco/converters
It would be really cool and make this easier to use if more common notations were supported, even if they were just converted to Harte. At least one more common one like ABC would make this more interoperable with other tools.
MusicGen Chord supports a subset of Harte grammar. Since the model converts chords into 12-pitch-bin-chromas, notations like C/G(C/5) will not reflected, because there is no 'root' idea in chromagram.
Found this paper from this year https://www.nature.com/articles/s41597-023-02410-w
They actually built out converters to support a bunch of notations and convert them all to Harte - https://github.com/smashub/choco/tree/main/choco/converters
It would be really cool and make this easier to use if more common notations were supported, even if they were just converted to Harte. At least one more common one like ABC would make this more interoperable with other tools.
Thanks for sharing it. If this converter is implemented, it would be more nice to use the model. It's not on priority right now, but I will work on it!
Thanks, I think this is the correct BNF for the text_chords field if helpful to anyone reading this:
<progression> ::= <bar> " " <bar>
<bar> ::= <chord> "," <chord>
<chord> ::= <note> ":" <shorthand>
<note> ::= <natural> | <note> <modifier>
<natural> ::= "A" | "B" | "C" | "D" | "E" | "F" | "G"
<modifier> ::= "b" | "#"
<shorthand> ::= "maj" | "min" | "dim" | "aug" | "maj7" | "min7" | "7" | "dim7" | "hdim7"
| "minmaj7" | "maj6" | "min6" | "9" | "maj9" | "min9" | "sus4"
Might be useful to put in the README or something, or could be used to validate input which leads to better error messages.
Sorry for the late reflection! Now the grammar sheet is added in the README!
Referencing the paper the notation is: https://ismir2005.ismir.net/proceedings/1080.pdf
And looking at the code, the implementation is: https://github.com/sakemin/cog-musicgen-chord/blob/master/audiocraft/modules/btc/utils/chords.py
Does the implementation fully support everything defined in the grammar from the paper? Writing something that generates the text_chords param and want to understand the implementation here better.
Also not sure if you looked at this but a library I found for parsing the Harte grammar: https://jams.readthedocs.io/en/stable/namespaces/chord.html#chord-harte