asigalov61 commited on
Commit
516d23a
1 Parent(s): efa809c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -1
app.py CHANGED
@@ -152,7 +152,21 @@ def GenerateMIDI(progress=gr.Progress()):
152
 
153
  audio = synthesis([500, output1], 'SGM-v2.01-YamahaGrand-Guit-Bass-v2.7.sf2')
154
 
155
- yield [500, output1], "Allegro-Music-Transformer-Music-Composition.mid", (44100, audio)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
156
 
157
  #=================================================================================================
158
 
 
152
 
153
  audio = synthesis([500, output1], 'SGM-v2.01-YamahaGrand-Guit-Bass-v2.7.sf2')
154
 
155
+
156
+ x = []
157
+ y =[]
158
+ c = []
159
+
160
+ colors = ['red', 'yellow', 'green', 'cyan', 'blue', 'pink', 'orange', 'purple', 'gray', 'white', 'gold', 'silver']
161
+
162
+ for s in song_f:
163
+ x.append(s[1] / 1000)
164
+ y.append(s[4])
165
+ c.append(colors[s[3]])
166
+
167
+ midi_plot.append([x, y, c])
168
+
169
+ yield [500, output1], midi_plot, "Allegro-Music-Transformer-Music-Composition.mid", (44100, audio)
170
 
171
  #=================================================================================================
172