Numuse Documentation

numuse.converters.parse_music_measures

numuse.converters.parse_music_measures

numuse.converters.parse_music_measures(music_shorthand: List[List[Tuple[str, List[fractions.Fraction]]]], harmonic_information_shorthand_parser: Callable[[str], List[Type[numuse.notation.NoteCollection]]] = <function generate_NCs_from_harmonic_shorthand>)[source]

Converts hand-written music into Music (see `Abbrs`_)

Parameters

music_shorthand (List[List[Tuple[str, List[Fraction]]]]) – Music written in shorthand

Returns

Music which can be easily analyzed

Return type

Music

Example

>>> idea = [
...     [("0' 4' 7' 11' R", [tt, t, tt, t+b, b])], [("R 7' 4' 7' 7'", [tt, t, tt, t + b, b])],
...     [("9' 6' R", [b + tt, t + b, b])], [("6' 2' 9' 6' 0'' 9' R",[tt, t, tt, t, tt, t, b])],
...     ["(4 | 0 3 7 10) (9 | 0 3 7 10)",[2*b, 2*b])], [("(2 | 0 4 7 10)",[4*b])], [("(7 | 0 4 7 11)", [4*b])],
...     ["(4 7 11 2) (9 0 4 7)",[2*b, 2*b])], [("(2 6 9 0)",[4*b])], [("(7 11 2 6)", [4*b])],
...     ["<9 | 0 3 7 10> <2 | 0 3 7 10>",[2*b, 2*b])], [("<7 | 0 4 7 10>",[4*b])], [("<0 | 0 4 7 11>", [4*b])],
...     ["<9 0 4 7> <2 5 9 0>",[2*b, 2*b])], [("<7 11 2 5>",[4*b])], [("<0 4 7 11>", [4*b])]
... ]
>>> parse_music(idea)
Free document hosting provided by Read the Docs.