Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -306,7 +306,7 @@ def segment_audio_from_video(video_path, frame_duration_ms=30):
|
|
306 |
video = VideoFileClip(video_path)
|
307 |
# Ensure audio is saved in a compatible format for WebRTC VAD (16-bit, 1 channel, 8000/16000/32000 Hz)
|
308 |
# We will resample to 16kHz for VAD as it's a good balance.
|
309 |
-
video.audio.write_audiofile(audio_path
|
310 |
video.close()
|
311 |
logger.info(f"Audio extracted to: {audio_path}")
|
312 |
|
|
|
306 |
video = VideoFileClip(video_path)
|
307 |
# Ensure audio is saved in a compatible format for WebRTC VAD (16-bit, 1 channel, 8000/16000/32000 Hz)
|
308 |
# We will resample to 16kHz for VAD as it's a good balance.
|
309 |
+
video.audio.write_audiofile(audio_path)
|
310 |
video.close()
|
311 |
logger.info(f"Audio extracted to: {audio_path}")
|
312 |
|