Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -39,7 +39,8 @@ def transcribe_and_translate(audio_file, selected_language, model_type="base"):
|
|
39 |
:param model_type: Whisper model type (default is 'base')
|
40 |
:return: Transcription and translation
|
41 |
"""
|
42 |
-
temp_audio_path = os.path.join(BASE_DIR, audio_file.name)
|
|
|
43 |
|
44 |
# Save the uploaded file to a temporary location
|
45 |
with open(temp_audio_path, "wb") as f:
|
|
|
39 |
:param model_type: Whisper model type (default is 'base')
|
40 |
:return: Transcription and translation
|
41 |
"""
|
42 |
+
#temp_audio_path = os.path.join(BASE_DIR, audio_file.name)
|
43 |
+
temp_audio_path = os.path.join(BASE_DIR, os.path.basename(audio_file))
|
44 |
|
45 |
# Save the uploaded file to a temporary location
|
46 |
with open(temp_audio_path, "wb") as f:
|