kk90ujhun commited on
Commit
5dfd770
1 Parent(s): 22b4b78

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -4,14 +4,14 @@ import gradio as gr
4
 
5
  pipe = pipeline(model="kk90ujhun/whisper-small-hi") # change to "your-username/the-name-you-picked"
6
 
7
- def transcribe(audio):
8
- text = pipe(audio)["text"]
 
9
  return text
10
 
11
  iface = gr.Interface(
12
  fn=transcribe,
13
  inputs=gr.Video(),
14
- inputs=inputs.audio,
15
  outputs="text",
16
  title="Whisper Small Hindi",
17
  description="Realtime demo for Hindi speech recognition using a fine-tuned Whisper small model.",
 
4
 
5
  pipe = pipeline(model="kk90ujhun/whisper-small-hi") # change to "your-username/the-name-you-picked"
6
 
7
+ def transcribe(my_video):
8
+ my_audio = my_video.audio,
9
+ text = pipe(my_audio)["text"]
10
  return text
11
 
12
  iface = gr.Interface(
13
  fn=transcribe,
14
  inputs=gr.Video(),
 
15
  outputs="text",
16
  title="Whisper Small Hindi",
17
  description="Realtime demo for Hindi speech recognition using a fine-tuned Whisper small model.",