mirror of
https://github.com/modelscope/FunASR
synced 2025-09-15 14:48:36 +08:00
Update asr_inference_paraformer_streaming.py
This commit is contained in:
parent
7584bbd6f3
commit
6abf68388c
@ -202,9 +202,9 @@ class Speech2Text:
|
||||
assert check_argument_types()
|
||||
results = []
|
||||
cache_en = cache["encoder"]
|
||||
if speech.shape[1] < 16 * 60 and cache["is_final"]:
|
||||
cache["last_chunk"] = True
|
||||
feats = cache["feats"]
|
||||
if speech.shape[1] < 16 * 60 and cache_en["is_final"]:
|
||||
cache_en["last_chunk"] = True
|
||||
feats = cache_en["feats"]
|
||||
feats_len = torch.tensor([feats.shape[1]])
|
||||
else:
|
||||
if self.frontend is not None:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user