Refactored list operation to use product

Evaluated pitches are now stored to evaluated_valued variable
This commit is contained in:
2023-02-12 22:05:48 +02:00
parent 70b56dbc52
commit 4f019bfda4
4 changed files with 69 additions and 59 deletions

View File

@ -43,6 +43,15 @@ DEFAULT_OCTAVE = 4
DEFAULT_OPTIONS = {"octave": 0, "duration": 0.25}
OPERATORS = {
"+": operator.add,
"-": operator.sub,
"*": operator.mul,
"/": operator.truediv,
"%": operator.mod,
}
NOTES_TO_INTERVALS = {
'C': 0,
'Cs': 1,
@ -83,14 +92,6 @@ MODIFIERS = {
ROMANS = {"i": 1, "v": 5, "x": 10, "l": 50, "c": 100, "d": 500, "m": 1000}
OPERATORS = {
"+": operator.add,
"-": operator.sub,
"*": operator.mul,
"/": operator.truediv,
"%": operator.mod,
}
# pylint: disable=locally-disabled, too-many-lines
SCALES = {