Samples should be an integer, not seconds
Browse files- Merge pull request #49 from skripnik/patch-1
- tested performance -- ESIC dev2, 27 docs, on En, De, Cs ASR, Nvidia A40, min chunk 1s, VAD => it has lower WER and latency with "segment" buffer trimming with various thresholds
- whisper_online.py +1 -1
whisper_online.py
CHANGED
@@ -355,7 +355,7 @@ class OnlineASRProcessor:
|
|
355 |
"""
|
356 |
self.transcript_buffer.pop_commited(time)
|
357 |
cut_seconds = time - self.buffer_time_offset
|
358 |
-
self.audio_buffer = self.audio_buffer[int(cut_seconds
|
359 |
self.buffer_time_offset = time
|
360 |
self.last_chunked_at = time
|
361 |
|
|
|
355 |
"""
|
356 |
self.transcript_buffer.pop_commited(time)
|
357 |
cut_seconds = time - self.buffer_time_offset
|
358 |
+
self.audio_buffer = self.audio_buffer[int(cut_seconds*self.SAMPLING_RATE):]
|
359 |
self.buffer_time_offset = time
|
360 |
self.last_chunked_at = time
|
361 |
|