Skip to content

Commit 5115a06

Browse files
fix #2587: Resolve VAD multithreading issue (#2613)
* Fix crash in ASR tasks when lm is set to none in #2237 * fix #2587: Resolve VAD multithreading issue * Update funasr/models/fsmn_vad_streaming/model.py ok Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> --------- Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent 82a07e2 commit 5115a06

File tree

1 file changed

+3
-2
lines changed
  • funasr/models/fsmn_vad_streaming

1 file changed

+3
-2
lines changed

funasr/models/fsmn_vad_streaming/model.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -652,10 +652,11 @@ def inference(
652652
key: list = None,
653653
tokenizer=None,
654654
frontend=None,
655-
cache: dict = {},
655+
cache: dict = None,
656656
**kwargs,
657657
):
658-
658+
if cache is None:
659+
cache = {}
659660
if len(cache) == 0:
660661
self.init_cache(cache, **kwargs)
661662

0 commit comments

Comments
 (0)