szili2011 commited on
Commit
c75b241
·
verified ·
1 Parent(s): e1216b8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -5
app.py CHANGED
@@ -22,11 +22,13 @@ def predict_sound_text(audio):
22
  return label[0]
23
 
24
  # Define Gradio interface
25
- interface = gr.Interface(fn=predict_sound_text,
26
- inputs=gr.Audio(source="upload", type="filepath"),
27
- outputs="text",
28
- title="Audio to Text Converter",
29
- description="Upload an audio file (MP3 format) and get the textual representation.")
 
 
30
 
31
  # Launch the interface
32
  if __name__ == "__main__":
 
22
  return label[0]
23
 
24
  # Define Gradio interface
25
+ interface = gr.Interface(
26
+ fn=predict_sound_text,
27
+ inputs=gr.Audio(type="filepath"), # Removed source parameter
28
+ outputs="text",
29
+ title="Audio to Text Converter",
30
+ description="Upload an audio file (MP3 format) and get the textual representation."
31
+ )
32
 
33
  # Launch the interface
34
  if __name__ == "__main__":