asigalov61 commited on
Commit
f766d71
·
verified ·
1 Parent(s): 763ade3

Upload TMIDIX.py

Browse files
Files changed (1) hide show
  1. TMIDIX.py +9 -5
TMIDIX.py CHANGED
@@ -3908,7 +3908,7 @@ def chordify_score(score,
3908
  return None
3909
 
3910
  def fix_monophonic_score_durations(monophonic_score,
3911
- min_notes_gap=0,
3912
  min_notes_dur=1,
3913
  extend_durs=False
3914
  ):
@@ -14874,10 +14874,12 @@ def flatten_spikes_advanced(arr, window=1):
14874
 
14875
  def add_smooth_melody_to_enhanced_score_notes(escore_notes,
14876
  melody_channel=3,
 
 
14877
  min_notes_gap=0,
14878
  exclude_durs=[1, 2],
14879
  adv_flattening=True,
14880
- extend_durs=False,
14881
  max_mel_vels=127,
14882
  max_acc_vels=80,
14883
  return_melody=False
@@ -14895,9 +14897,11 @@ def add_smooth_melody_to_enhanced_score_notes(escore_notes,
14895
  ele_vals=exclude_durs
14896
  )
14897
 
14898
- escore_notes5 = add_expressive_melody_to_enhanced_score_notes(escore_notes4,
14899
- return_melody=True,
14900
- melody_channel=melody_channel
 
 
14901
  )
14902
 
14903
  mel_score = remove_events_from_escore_notes(escore_notes5,
 
3908
  return None
3909
 
3910
  def fix_monophonic_score_durations(monophonic_score,
3911
+ min_notes_gap=1,
3912
  min_notes_dur=1,
3913
  extend_durs=False
3914
  ):
 
14874
 
14875
  def add_smooth_melody_to_enhanced_score_notes(escore_notes,
14876
  melody_channel=3,
14877
+ melody_patch=40,
14878
+ melody_start_chord=0,
14879
  min_notes_gap=0,
14880
  exclude_durs=[1, 2],
14881
  adv_flattening=True,
14882
+ extend_durs=True,
14883
  max_mel_vels=127,
14884
  max_acc_vels=80,
14885
  return_melody=False
 
14897
  ele_vals=exclude_durs
14898
  )
14899
 
14900
+ escore_notes5 = add_expressive_melody_to_enhanced_score_notes(escore_notes4,
14901
+ melody_channel=melody_channel,
14902
+ melody_patch=melody_patch,
14903
+ melody_start_chord=melody_start_chord,
14904
+ return_melody=True,
14905
  )
14906
 
14907
  mel_score = remove_events_from_escore_notes(escore_notes5,