firagne commited on
Commit
ff28df8
·
1 Parent(s): b114745
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -85,7 +85,7 @@ def process(file_name, embed_html_all):
85
  print("search time :", time.time() - timestart)
86
 
87
  tops = get_topN(I, ind_filenames, url_dict, catalog, max_results)
88
- formated = []
89
  output_csv = f"{file_name}_results.csv"
90
  with open(output_csv, "w") as w:
91
  writer = csv.writer(w)
@@ -150,9 +150,8 @@ with gr.Blocks() as demo:
150
  # )
151
  # tops.append(gr.Audio(label=f"top{i}", show_label=False))
152
 
153
- select_results.select(
154
- fn=change_audio, inputs=audio_input_file, outputs=audio_player
155
- )
156
  analyze_url_btn.click(
157
  process_url, inputs=[audio_url_input], outputs=[html, results, select_results]
158
  )
 
85
  print("search time :", time.time() - timestart)
86
 
87
  tops = get_topN(I, ind_filenames, url_dict, catalog, max_results)
88
+ formated = [("Choose a result to play", "")]
89
  output_csv = f"{file_name}_results.csv"
90
  with open(output_csv, "w") as w:
91
  writer = csv.writer(w)
 
150
  # )
151
  # tops.append(gr.Audio(label=f"top{i}", show_label=False))
152
 
153
+ select_results.select(fn=change_audio, inputs=select_results, outputs=audio_player)
154
+
 
155
  analyze_url_btn.click(
156
  process_url, inputs=[audio_url_input], outputs=[html, results, select_results]
157
  )