spiffyscore

Check-in [2ae36c6e68]
Login
Overview
SHA1:2ae36c6e683319943f0b14e889bb5aa74f7f7dc0
Date: 2011-10-20 20:01:33
User: brian
Edited Comment: Program no longer cuts out a note from the score each time it adds a new phrase to the score
Original Comment: Program no longer cuts out an note from the score each time it adds a new phrase in.
Timelines: family | ancestors | descendants | both | develop
Downloads: Tarball | ZIP archive
Other Links: files | file ages | folders | manifest
Tags And Properties
Context
2011-11-01
18:52
[eb81d5f9fd] Added a sampled double bass, modified the program to respond to an instrument's specified octave (user: brian, tags: develop)
2011-10-20
20:01
[2ae36c6e68] Program no longer cuts out a note from the score each time it adds a new phrase to the score (user: brian, tags: develop)
19:56
[a9e60898b7] Program now chooses consistent nodes based on what's specified in the grammar. A couple other bugs are still present. (user: brian, tags: develop)
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Modified cfg.py from [9313c52f09] to [3a0a8776ca].

   185    185                   if isinstance(score[item], tree.Tree):  # Also, make this use the find_next_node() function (or whatever I called it)
   186    186                       score_index_to_replace = item
   187    187               if score_index_to_replace is None:
   188    188                   raise ValueError("No more nodes to fill in")
   189    189   
   190    190               time_remaining = max_time - score_len(score)
   191    191               new_phrase, syncs = choose_phrase(instr, syncs, score_len(score), time_remaining, score)
   192         -            score = score[:score_index_to_replace-1] + new_phrase + score[score_index_to_replace+1:]
          192  +            score = score[:score_index_to_replace] + new_phrase + score[score_index_to_replace+1:]
   193    193   
   194    194       except ValueError:
   195    195           return (score, syncs)
   196    196   
   197    197   
   198    198   def choose_phrase(instr, syncs, current_time, time_remaining, score):
   199    199       '''Filters grammars for ones that match the sync option, and phrases that fit the time remaining in the score'''