asigalov61 commited on
Commit
b67a428
1 Parent(s): 6401273

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -7
app.py CHANGED
@@ -212,8 +212,8 @@ def render_midi(input_midi,
212
  f.write(fdata)
213
  f.close()
214
 
215
- if soundfont_bank in ["General MIDI", "Nice strings plus orchestra", "Real choir", "Orpheus", "Super Game Boy", "Proto Square"]:
216
- sf2bank = ["General MIDI", "Nice strings plus orchestra", "Real choir", "Orpheus", "Super Game Boy", "Proto Square"].index(soundfont_bank)
217
 
218
  else:
219
  sf2bank = 0
@@ -273,10 +273,11 @@ if __name__ == "__main__":
273
  print('App start time: {:%Y-%m-%d %H:%M:%S}'.format(datetime.datetime.now(PDT)))
274
  print('=' * 70)
275
 
276
- soundfonts = ["SGM-v2.01-YamahaGrand-Guit-Bass-v2.7.sf2",
 
 
277
  "Nice-Strings-PlusOrchestra-v1.6.sf2",
278
  "KBH-Real-Choir-V2.5.sf2",
279
- "Orpheus_18.06.2020.sf2",
280
  "SuperGameBoy.sf2",
281
  "ProtoSquare.sf2"
282
  ]
@@ -299,15 +300,16 @@ if __name__ == "__main__":
299
 
300
  gr.Markdown("## Select desired Sound Font bank and render sample rate")
301
 
302
- soundfont_bank = gr.Radio(["General MIDI",
 
 
303
  "Nice strings plus orchestra",
304
  "Real choir",
305
- "Orpheus",
306
  "Super Game Boy",
307
  "Proto Square"
308
  ],
309
  label="SoundFont bank",
310
- value="General MIDI"
311
  )
312
 
313
  render_sample_rate = gr.Radio(["16000",
 
212
  f.write(fdata)
213
  f.close()
214
 
215
+ if soundfont_bank in ["Super GM", "Orpheus GM", "Live HQ GM" "Nice strings plus orchestra", "Real choir", "Super Game Boy", "Proto Square"]:
216
+ sf2bank = ["Super GM", "Orpheus GM", "Live HQ GM", "Nice strings plus orchestra", "Real choir", "Super Game Boy", "Proto Square"].index(soundfont_bank)
217
 
218
  else:
219
  sf2bank = 0
 
273
  print('App start time: {:%Y-%m-%d %H:%M:%S}'.format(datetime.datetime.now(PDT)))
274
  print('=' * 70)
275
 
276
+ soundfonts = ["SGM-v2.01-YamahaGrand-Guit-Bass-v2.7.sf2",
277
+ "Orpheus_18.06.2020.sf2",
278
+ "Live HQ Natural SoundFont GM.sf2",
279
  "Nice-Strings-PlusOrchestra-v1.6.sf2",
280
  "KBH-Real-Choir-V2.5.sf2",
 
281
  "SuperGameBoy.sf2",
282
  "ProtoSquare.sf2"
283
  ]
 
300
 
301
  gr.Markdown("## Select desired Sound Font bank and render sample rate")
302
 
303
+ soundfont_bank = gr.Radio(["Super GM",
304
+ "Orpheus GM",
305
+ "Live HQ GM"
306
  "Nice strings plus orchestra",
307
  "Real choir",
 
308
  "Super Game Boy",
309
  "Proto Square"
310
  ],
311
  label="SoundFont bank",
312
+ value="Super GM"
313
  )
314
 
315
  render_sample_rate = gr.Radio(["16000",