-
Hi! I'm trying to use pyannote with an ASR API to get diarized transcriptions and I'm having trouble when dealing with speech that overlaps. The ASR solution I use gives word-level timestamps, so I do the STT and the diarization in parallel. Then, I group the transcribed words into segments that follow the diarization result. The results have been reasonably good, but I can't quite solve the overlapping problem. Consider the diarization result below: 4.19 --> 45.55: SPEAKER_01 As you can see, pyannote gives overlapping timestamps. The best solution I found so far is to prioritize the speaker that comes first. My script reads each line in the order pyannote creates them and assigns all the words that are in that interval to the first speaker. Then, it goes to the following line and does the same, but it starts from the first word that does not have a speaker yet. In the case above, the final transcript would be something like this: 4.19 --> 45.55: SPEAKER_01 - words words words words words words words words words words words words words words The problem is that this approach often results in imprecision — for example, SPEAKER 01 gets words that were spoken by SPEAKER 00. Does anyone have a better idea of what would be the best way to deal with the problem of overlapping speech? Sorry for the long post! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
I have a solution that works 95% of the time with some post-processing of the diarization with pandas. My goal is to have zero overlaps in the final dataframe.
|
Beta Was this translation helpful? Give feedback.
-
Hello, I tried to run the sample overlapping audio, the transcription is okay, but the speaker segmentation is not working, May I know, how can i improve the spekaer_overlapping. Attached are the speaker transcription and link to the audio: https://www.youtube.com/watch?v=k4rOv7EAxRc |
Beta Was this translation helpful? Give feedback.
I have a solution that works 95% of the time with some post-processing of the diarization with pandas. My goal is to have zero overlaps in the final dataframe.