Rewrite cello practice script

master
trémeur 5 years ago
parent d87b03d164
commit 22e4c81e36

1
.gitignore vendored

@ -2,3 +2,4 @@
nohup.out nohup.out
*~ *~
*# *#
*/__pycache__

@ -1,196 +1,66 @@
import random import random
import datetime import datetime
print("") warms = ["Warm-up bowing technique 1 (page 5)","Warm-up bowing technique 2 (page 5)","Adjusting tuning (page 6)","Warm up: fingers (page 7)","Position changes (page 8)", "Bow changes at the heel (page 8)", "Warm-up bowing technique 3 (page 9)", "String crossing (page 14)", "Rapid scales (page 15)", "Rudiments of bow distribution 1 (page 16)", "Rudiments of bow distribution 2 (page 17)", "Positions 14 (page 18)", "Transitional positions (page 19)"]
today = datetime.date.today() def warm(x):
todaystr = (today.strftime("%d %B %Y")) return warms[x]
print("Cello exercises for " + todaystr + ":")
def randwarm():
warm1 = random.randint(1,13) thewarm = random.randint(0, (len(warms) - 1))
warm2 = random.randint(1,13) return warm(thewarm)
while warm2 == warm1:
warm2 = random.randint(1,13) weiters = ["First thumb position (page 20)", "Chromatic scales (page 22)", "Playing arpeggios with various fingerings (page 23)", "Rudiments of bow distribution 3 (page 24)", "Rapid changes in bow speed (page 25)", "Playing thirds (page 26)", "Playing sixths (page 27)", "Playing octaves (page 28)", "Playing staccato notes on one bow (page 29)", "Playing dotted notes (page 30)", "Position changes over an octave (page 31)"]
# print(warm1) def weiter(x):
# print(warm2) return weiters[x]
warm3 = random.randint(1,13) def randweiter():
theweiter = random.randint(0, (len(weiters) - 1))
while warm3 == warm1: return weiter(theweiter)
warm3 = random.randint(1,13)
tongues = ["Dynamics (page 32)", "Crescendo (page 33)", "Coordinating left and right hands (page 34)", "Bowing technique (page 35)", "Matching tone on the A string (page 36)", "Focus on bowing at the heel (page 37)", "Playing harmonics (page 38)", "Playing glissando (page 39)", "Basic practice techniques for right-left coordination (page 40)", "Left hand (page 41)", "Variable vibrato (page 42)", "Bow control (page 42)", "Balancing force between right and left arms (page 43)", "Developing tone on the C string (page 33)"]
while warm3 == warm2:
warm3 = random.randint(1,13) def tongue(x):
return tongues[x]
# print(warm3)
def randtongue():
warms = [warm1, warm2, warm3] thetongue = random.randint(0, (len(tongues) - 1))
return tongue(thetongue)
if 1 in warms:
print("Warm-up bowing technique 1 (page 5)") scales = ["C major scale (page 10)", "D flat major scale (page 10)", "D major scale (page 11)", "E flat major scale (page 11)", "E major scale (page 11)", "F major scale (page 11)", "F sharp major scale (page 11)", "G major scale (page 12)", "A flat major scale (page 12)", "A major scale (page 12)", "B flat major scale (page 12)", "B major scale (page 12)", "C minor scale (page 13)", "D minor scale (page 13)", "G minor scale (page 13)"]
if 2 in warms: def scale(x):
print("Warm-up bowing technique 2 (page 5)") return scales[x]
if 3 in warms: def randscale():
print("Adjusting tuning (page 6)") thescale = random.randint(0, (len(scales) - 1))
return scale(thescale)
if 4 in warms:
print("Warm up: fingers (page 7)") if __name__ == "__main__":
today = datetime.date.today()
if 5 in warms: todaystr = (today.strftime("%d %B %Y"))
print("Position changes (page 8)") print("\nCello exercises for " + todaystr + ":")
"""
if 6 in warms: The book recommends:
print("Bow changes at the heel (page 8)") a. three basic warm-ups;
b. one further intermediate warm-up;
if 7 in warms: c. one more advanced exercise;
print("Warm-up bowing technique 3 (page 9)") d. one scale.
"""
if 8 in warms: warm1 = random.randint(0, (len(warms) - 1))
print("String crossing (page 14)") warm2 = random.randint(0, (len(warms) - 1))
while warm2 == warm1:
if 9 in warms: warm2 = random.randint(0, (len(warms) - 1))
print("Rapid scales (page 15)") warm3 = random.randint(0, (len(warms) - 1))
while warm3 == warm1 or warm3 == warm2:
if 10 in warms: warm3 = random.randint(0, (len(warms) - 1))
print("Rudiments of bow distribution 1 (page 16)") listwarms = [warm1, warm2, warm3]
sortwarms = sorted(listwarms)
if 11 in warms: print(warm(sortwarms[0]))
print("Rudiments of bow distribution 2 (page 17)") print(warm(sortwarms[1]))
print(warm(sortwarms[2]))
if 12 in warms: print(randweiter())
print("Positions 14 (page 18)") print(randtongue())
print(randscale())
if 13 in warms:
print("Transitional positions (page 19)")
weiter = random.randint(1,11)
if weiter == 1:
print("First thumb position (page 20)")
if weiter == 2:
print("Chromatic scales (page 22)")
if weiter == 3:
print("Playing arpeggios with various fingerings (page 23)")
if weiter == 4:
print("Rudiments of bow distribution 3 (page 24)")
if weiter == 5:
print("Rapid changes in bow speed (page 25)")
if weiter == 6:
print("Playing thirds (page 26)")
if weiter == 7:
print("Playing sixths (page 27)")
if weiter == 8:
print("Playing octaves (page 28)")
if weiter == 9:
print("Playing staccato notes on one bow (page 29)")
if weiter == 10:
print("Playing dotted notes (page 30)")
if weiter == 11:
print("Position changes over an octave (page 31)")
tongue = random.randint(1,14)
if tongue == 1:
print("Dynamics (page 32)")
if tongue == 2:
print("Crescendo (page 33)")
if tongue == 3:
print("Coordinating left and right hands (page 34)")
if tongue == 4:
print("Bowing technique (page 35)")
if tongue == 5:
print("Matching tone on the A string (page 36)")
if tongue == 6:
print("Focus on bowing at the heel (page 37)")
if tongue == 7:
print("Playing harmonics (page 38)")
if tongue == 8:
print("Playing glissando (page 39)")
if tongue == 9:
print("Basic practice techniques for right-left coordination (page 40)")
if tongue == 10:
print("Left hand (page 41)")
if tongue == 11:
print("Variable vibrato (page 42)")
if tongue == 12:
print("Bow control (page 42)")
if tongue == 13:
print("Balancing force between right and left arms (page 43)")
if tongue == 14:
print("Developing tone on the C string (page 33)")
scale = random.randint(1,15)
if scale == 1:
print("C major scale (page 10)")
if scale == 2:
print("D flat major scale (page 10)")
if scale == 3:
print("D major scale (page 11)")
if scale == 4:
print("E flat major scale (page 11)")
if scale == 5:
print("E major scale (page 11)")
if scale == 6:
print("F major scale (page 11)")
if scale == 7:
print("F sharp major scale (page 11)")
if scale == 8:
print("G major scale (page 12)")
if scale == 9:
print("A flat major scale (page 12)")
if scale == 10:
print("A major scale (page 12)")
if scale == 11:
print("B flat major scale (page 12)")
if scale == 12:
print("B major scale (page 12)")
if scale == 13:
print("C minor scale (page 13)")
if scale == 14:
print("D minor scale (page 13)")
if scale == 15:
print("G minor scale (page 13)")
print("")

Loading…
Cancel
Save