Spaces:
Sleeping
Sleeping
Commit
·
1801257
1
Parent(s):
5384a65
Update app.py
Browse files
app.py
CHANGED
|
@@ -106,8 +106,8 @@ def run(search_prompt, mid=None):
|
|
| 106 |
yield mid_seq, None, None, [create_msg("visualizer_append", mid_seq[i]), create_msg("progress", [i + 1, len(mid_seq)])]
|
| 107 |
|
| 108 |
with open(f"output.mid", 'wb') as f:
|
| 109 |
-
f.write(MIDI.score2midi([mid_seq_ticks,
|
| 110 |
-
audio = synthesis(MIDI.score2opus([mid_seq_ticks,
|
| 111 |
yield mid_seq, "output.mid", (44100, audio), [create_msg("visualizer_end", None)]
|
| 112 |
|
| 113 |
|
|
|
|
| 106 |
yield mid_seq, None, None, [create_msg("visualizer_append", mid_seq[i]), create_msg("progress", [i + 1, len(mid_seq)])]
|
| 107 |
|
| 108 |
with open(f"output.mid", 'wb') as f:
|
| 109 |
+
f.write(MIDI.score2midi([mid_seq_ticks, mid_seq]))
|
| 110 |
+
audio = synthesis(MIDI.score2opus([mid_seq_ticks, mid_seq]), soundfont_path)
|
| 111 |
yield mid_seq, "output.mid", (44100, audio), [create_msg("visualizer_end", None)]
|
| 112 |
|
| 113 |
|