From d8c1b46daf4fe19c7cc506b4f605aa519bb0f3ad Mon Sep 17 00:00:00 2001
From: wuhongsheng <664116298@qq.com>
Date: 星期一, 01 七月 2024 13:41:06 +0800
Subject: [PATCH] 修复断句之间时间戳bug (#1863)
---
funasr/utils/timestamp_tools.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/funasr/utils/timestamp_tools.py b/funasr/utils/timestamp_tools.py
index 6abebe1..4fc2d15 100644
--- a/funasr/utils/timestamp_tools.py
+++ b/funasr/utils/timestamp_tools.py
@@ -156,6 +156,7 @@
punc_id = int(punc_id) if punc_id is not None else 1
sentence_end = timestamp[1] if timestamp is not None else sentence_end
+ sentence_start = timestamp[0] if timestamp is not None else sentence_start
sentence_text_seg = (
sentence_text_seg[:-1] if sentence_text_seg[-1] == " " else sentence_text_seg
)
@@ -183,7 +184,6 @@
sentence_text = ""
sentence_text_seg = ""
ts_list = []
- sentence_start = sentence_end
return res
--
Gitblit v1.9.1