Kleber commited on
Commit
8feb0c9
1 Parent(s): c5fd090

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -20,8 +20,8 @@ def transcribe(file):
20
  audio = audio.set_frame_rate(16000)
21
  if audio.channels != 1:
22
  audio = audio.set_channels(1)
23
- new_file_name = file.split(".")[0]+".wav"
24
- audio.export(new_file_name,format)
25
  except Exception as e:
26
  print(e)
27
  transcription= asr_model.transcribe([new_file_name])
 
20
  audio = audio.set_frame_rate(16000)
21
  if audio.channels != 1:
22
  audio = audio.set_channels(1)
23
+ file = file.split(".")[0]+".wav"
24
+ audio.export(file,format="wav")
25
  except Exception as e:
26
  print(e)
27
  transcription= asr_model.transcribe([new_file_name])