Skip to content

Instantly share code, notes, and snippets.

@deeptir18
Created April 26, 2017 00:32
Show Gist options
  • Save deeptir18/f97110462e62c23c59a97595a3909acc to your computer and use it in GitHub Desktop.
Save deeptir18/f97110462e62c23c59a97595a3909acc to your computer and use it in GitHub Desktop.
c_maj = Key(60, major)
x = ChordPredictor(kSomewhere, 480, c_maj)
chords = x.get_one_option()
voicings = []
for i in range(len(chords)):
chord = chords[i]
if i == 0:
v = VoicePredictor(chord, c_maj)
voicings.append(v.get_initial_voicing())
else:
v = VoicePredictor(chord, c_maj, voicings[i-1])
voicings.append(v.get_best_voicing())
for voicing in voicings:
print voicing
for chord in chords:
print chord
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment