akshansh36 commited on
Commit
9cfc17b
1 Parent(s): e3cc5cd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -262,7 +262,7 @@ def process_audio(audio_file, uploaded_files, file_m, file_index):
262
 
263
  # Return the list of processed audio file paths for the dropdown,
264
  # update the dropdown, and return only the first file for the audio player
265
- return result, gr.update(choices=result, value=result[0], visible=True), result[0]
266
 
267
  def update_audio_selection(selected_file):
268
  return gr.update(value=selected_file, visible=True)
@@ -328,13 +328,14 @@ def get_gui(theme):
328
 
329
  dropdown = gr.Dropdown(choices=[], label="Select Processed Audio", visible=False)
330
  output_audio = gr.Audio(label="Play Selected Audio", visible=False,show_share_button=False)
 
331
 
332
  # output_file, output_audio = output_conf()
333
 
334
  button_base.click(
335
  process_audio,
336
  inputs=[audio, files, model, indx],
337
- outputs=[dropdown, dropdown, output_audio],
338
  )
339
 
340
  dropdown.change(
 
262
 
263
  # Return the list of processed audio file paths for the dropdown,
264
  # update the dropdown, and return only the first file for the audio player
265
+ return result, gr.update(choices=result, value=result[0], visible=True), result[0],result
266
 
267
  def update_audio_selection(selected_file):
268
  return gr.update(value=selected_file, visible=True)
 
328
 
329
  dropdown = gr.Dropdown(choices=[], label="Select Processed Audio", visible=False)
330
  output_audio = gr.Audio(label="Play Selected Audio", visible=False,show_share_button=False)
331
+ output_files = gr.File(label="Download Processed Audio", file_count="multiple", interactive=False)
332
 
333
  # output_file, output_audio = output_conf()
334
 
335
  button_base.click(
336
  process_audio,
337
  inputs=[audio, files, model, indx],
338
+ outputs=[dropdown, dropdown, output_audio, output_files],
339
  )
340
 
341
  dropdown.change(