FarhadMadadzade commited on
Commit
270a894
1 Parent(s): 262c6d5
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -96,7 +96,8 @@ def process_video(date):
96
  # audio = audio_file.read()
97
  # transcription += pipe(audio)["text"] + " "
98
  # os.remove(f"chunk{i}.wav")
99
-
 
100
  transcription = pipe(audio)["text"]
101
  # Remove the audio file
102
  os.remove(audio_path)
 
96
  # audio = audio_file.read()
97
  # transcription += pipe(audio)["text"] + " "
98
  # os.remove(f"chunk{i}.wav")
99
+ with open(audio_path, "rb") as audio_file:
100
+ audio = audio_file.read()
101
  transcription = pipe(audio)["text"]
102
  # Remove the audio file
103
  os.remove(audio_path)