Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -35,7 +35,8 @@ def audio_extraction(video_file, output_format):
|
|
35 |
# temp_filename = video_file.name
|
36 |
# video_path = f"{temp_filename}"
|
37 |
audio = extract_audio(
|
38 |
-
input_path=os.
|
|
|
39 |
)
|
40 |
return audio
|
41 |
|
@@ -57,7 +58,7 @@ def transcribe_video(processed_audio):
|
|
57 |
transcriber_model = load_asr_model()
|
58 |
text_extract = transcriber_model(processed_audio)
|
59 |
et = time.time()
|
60 |
-
run_time = et - st
|
61 |
return text_extract['text'], run_time
|
62 |
|
63 |
def generate_ai_summary(transcript):
|
|
|
35 |
# temp_filename = video_file.name
|
36 |
# video_path = f"{temp_filename}"
|
37 |
audio = extract_audio(
|
38 |
+
input_path=os.
|
39 |
+
fspath(video_file), output_path=f"{str(video_file)[:-4]}.mp3", output_format=f"{output_format}"
|
40 |
)
|
41 |
return audio
|
42 |
|
|
|
58 |
transcriber_model = load_asr_model()
|
59 |
text_extract = transcriber_model(processed_audio)
|
60 |
et = time.time()
|
61 |
+
run_time = et - st
|
62 |
return text_extract['text'], run_time
|
63 |
|
64 |
def generate_ai_summary(transcript):
|