correct silences handling when language not auto
This commit is contained in:
parent
870141298c
commit
4e9f951551
1 changed files with 5 additions and 1 deletions
|
|
@ -111,7 +111,11 @@ class SimulStreamingOnlineProcessor:
|
|||
"""
|
||||
try:
|
||||
timestamped_words = self.model.infer(is_last=is_last)
|
||||
if self.model.cfg.language == "auto" and timestamped_words and timestamped_words[0].detected_language == None:
|
||||
|
||||
if not timestamped_words:
|
||||
return [], self.end
|
||||
|
||||
if self.model.cfg.language == "auto" and timestamped_words[0].detected_language is None:
|
||||
self.buffer.extend(timestamped_words)
|
||||
return [], self.end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue