Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -31,10 +31,10 @@ def handle(chart_path, music_path):
31
 
32
  if __name__ == "__main__":
33
  inputs = [
34
- gr.File(label="太鼓達人譜面/Taiko Chart Json Data"),
35
- gr.File(label="譜面音樂/Chart Music (Optional)")
36
  ]
37
- outputs = [gr.Audio(label=course["label"]) for course in COURSE]
38
 
39
  demo = gr.Interface(fn=handle, inputs=inputs, outputs=outputs, title="程設二作業HW0105 / Taiko Music Generator")
40
- demo.launch()
 
31
 
32
  if __name__ == "__main__":
33
  inputs = [
34
+ gr.File(label="太鼓達人譜面/Taiko Chart Json Data", file_types=[".json"]),
35
+ gr.File(label="譜面音樂/Chart Music (Optional)", file_types=[".ogg"])
36
  ]
37
+ outputs = [gr.Audio(label=course["label"], format="mp3") for course in COURSE]
38
 
39
  demo = gr.Interface(fn=handle, inputs=inputs, outputs=outputs, title="程設二作業HW0105 / Taiko Music Generator")
40
+ demo.launch()