Spaces:
Runtime error
Runtime error
Update video_processing.py
Browse files- video_processing.py +2 -2
video_processing.py
CHANGED
|
@@ -156,8 +156,8 @@ def process_video(video_path, anomaly_threshold, desired_fps, progress=None):
|
|
| 156 |
progress(0.8, "Extracting audio and performing voice analysis")
|
| 157 |
|
| 158 |
audio_path = extract_audio_from_video(video_path)
|
| 159 |
-
diarization = diarize_speakers(audio_path)
|
| 160 |
-
voice_embeddings, audio_duration = get_speaker_embeddings(audio_path, diarization,
|
| 161 |
|
| 162 |
aligned_voice_embeddings = align_voice_embeddings(voice_embeddings, frame_count, original_fps, audio_duration)
|
| 163 |
|
|
|
|
| 156 |
progress(0.8, "Extracting audio and performing voice analysis")
|
| 157 |
|
| 158 |
audio_path = extract_audio_from_video(video_path)
|
| 159 |
+
diarization, most_frequent_speaker = diarize_speakers(audio_path)
|
| 160 |
+
voice_embeddings, audio_duration = get_speaker_embeddings(audio_path, diarization, most_frequent_speaker)
|
| 161 |
|
| 162 |
aligned_voice_embeddings = align_voice_embeddings(voice_embeddings, frame_count, original_fps, audio_duration)
|
| 163 |
|