Spaces:
Runtime error
Runtime error
Update voice_analysis.py
Browse files- voice_analysis.py +2 -2
voice_analysis.py
CHANGED
|
@@ -45,7 +45,7 @@ def get_speaker_embeddings(audio_path, diarization, model_name="pyannote/embeddi
|
|
| 45 |
|
| 46 |
return embeddings, duration
|
| 47 |
|
| 48 |
-
def align_voice_embeddings(voice_embeddings, frame_count, fps):
|
| 49 |
aligned_embeddings = []
|
| 50 |
current_embedding_index = 0
|
| 51 |
|
|
@@ -58,4 +58,4 @@ def align_voice_embeddings(voice_embeddings, frame_count, fps):
|
|
| 58 |
|
| 59 |
aligned_embeddings.append(voice_embeddings[current_embedding_index]["embedding"])
|
| 60 |
|
| 61 |
-
return
|
|
|
|
| 45 |
|
| 46 |
return embeddings, duration
|
| 47 |
|
| 48 |
+
def align_voice_embeddings(voice_embeddings, frame_count, fps, audio_duration):
|
| 49 |
aligned_embeddings = []
|
| 50 |
current_embedding_index = 0
|
| 51 |
|
|
|
|
| 58 |
|
| 59 |
aligned_embeddings.append(voice_embeddings[current_embedding_index]["embedding"])
|
| 60 |
|
| 61 |
+
return aligned_embeddings
|