JPMadsen commited on
Commit
858f2f3
·
1 Parent(s): f0f8d32

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -13
app.py CHANGED
@@ -17,10 +17,10 @@ def inference(audio):
17
  )
18
 
19
  # Check if files exist before returning
20
- files = ["out/mdx_extra_q/test/vocals.wav",
21
- "out/mdx_extra_q/test/bass.wav",
22
- "out/mdx_extra_q/test/drums.wav",
23
- "out/mdx_extra_q/test/other.wav"]
24
 
25
  for file in files:
26
  if not os.path.isfile(file):
@@ -35,20 +35,18 @@ description = "Music source separation. To get started, simply upload your audio
35
  article = "Inspired by Demucs:\n<p style='text-align: center'><a href='https://arxiv.org/abs/1911.13254' target='_blank'>Music Source Separation in the Waveform Domain</a> | <a href='https://github.com/facebookresearch/demucs' target='_blank'>Github Repo</a></p>"
36
 
37
  demo = gr.Interface(
38
- fn = inference,
39
- inputs = gr.Audio(type = "numpy", label = "Input"),
40
- outputs = [
41
- gr.Audio(type = "filepath", label = "Vocals"),
42
- gr.outputs.Audio(type = "filepath", label = "Bass"),
43
- gr.outputs.Audio(type = "filepath", label = "Drums"),
44
- gr.outputs.Audio(type = "filepath", label = "Other")
45
  ],
46
  title = title,
47
  description = description,
48
  article = article,
49
  theme = 'nuttea/Softblue',
50
- allow_flagging = "never",
51
-
52
  )
53
 
54
  #demo.queue(concurrency_count = 10)
 
17
  )
18
 
19
  # Check if files exist before returning
20
+ files = ["./out/mdx_extra_q/test/vocals.wav",
21
+ "./out/mdx_extra_q/test/bass.wav",
22
+ "./out/mdx_extra_q/test/drums.wav",
23
+ "./out/mdx_extra_q/test/other.wav"]
24
 
25
  for file in files:
26
  if not os.path.isfile(file):
 
35
  article = "Inspired by Demucs:\n<p style='text-align: center'><a href='https://arxiv.org/abs/1911.13254' target='_blank'>Music Source Separation in the Waveform Domain</a> | <a href='https://github.com/facebookresearch/demucs' target='_blank'>Github Repo</a></p>"
36
 
37
  demo = gr.Interface(
38
+ inference,
39
+ gr.inputs.Audio(type = "numpy", label = "Input"),
40
+ [gr.outputs.Audio(type = "filepath", label = "Vocals"),
41
+ gr.outputs.Audio(type = "filepath", label = "Bass"),
42
+ gr.outputs.Audio(type = "filepath", label = "Drums"),
43
+ gr.outputs.Audio(type = "filepath", label = "Other")
 
44
  ],
45
  title = title,
46
  description = description,
47
  article = article,
48
  theme = 'nuttea/Softblue',
49
+ allow_flagging = "never"
 
50
  )
51
 
52
  #demo.queue(concurrency_count = 10)