blob: 976e2143472bd9e3a11dbdb33ddc9475a18101ed (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
from diagram import *
from grammar import *
from spec import *
'''
modules:
cadence.py define musical morphemes
projection.py dependencies and agreement
antecedent or consequent cadence bundled with prolongation rules for each feature - (dominates) or (dominates, agrees) or (dominates, agrees, submits)
(1)==Head; (0)==Complement; (1,0)==XP; (1,1)==XBar; (0,1)==X; (0,0)==None;
diagram.py define binary tree structures
phonology.py distribution of cadential features for given grammar
lexicon.py repository of lexemes: (cadence, dependencies, prolongation)
passage.py lexemes unified over tree diagram
spellout() sequence of unified cadences in passage (for each voice)
score.py list of n passages rendered to music21 score object
export() to xml, midi, ly
'''
# lexicon.addCategory()
phonology.print()
morphology.print()
lexeme = phonology.makeCadence()
lexeme.print()
syntax = Diagram()
syntax.print()
|