Open-source speech recognition toolkit for training, inference, streaming ASR, VAD, punctuation, speaker diarization pipelines, and OpenAI-compatible/MCP serving.
Python asraudiochineseemotion-recognitionfunasrmcp-servermultilingual-asropenai-compatible-apiparaformerpunctuationpytorchreal-time-asrspeaker-diarizationspeech-recognitionspeech-to-textstreaming-asrtranscriptionvllmvoice-activity-detectionwhisper-alternative
update vad_inference.py
凌匀41b1d3504860
diff --git a/funasr/bin/vad_inference.py b/funasr/bin/vad_inference.pyindex 0d9659401..1cdb582e5 100644--- a/funasr/bin/vad_inference.py+++ b/funasr/bin/vad_inference.py@@ -111,6 +111,7 @@ class Speech2VadSegment:# b. Forward Encoder sreamingsegments = []+ segments_tmp = []step = 6000t_offset = 0for t_offset in range(0, feats_len, min(step, feats_len - t_offset)):@@ -128,9 +129,8 @@ class Speech2VadSegment:batch = to_device(batch, device=self.device)segments_part = self.vad_model(**batch)if segments_part:- segments += segments_part- #print(segments)-+ segments_tmp += segments_part[0]+ segments.append(segments_tmp)return segments