daihui.zhang
commited on
Commit
·
07f9733
1
Parent(s):
98c9c23
remove unused codes
Browse files
transcribe/whisper_llm_serve.py
CHANGED
|
@@ -12,8 +12,7 @@ from api_model import TransResult, Message, DebugResult
|
|
| 12 |
|
| 13 |
from .utils import log_block, save_to_wave, TestDataWriter, filter_words
|
| 14 |
from .translatepipes import TranslatePipes
|
| 15 |
-
|
| 16 |
-
TranscriptStabilityAnalyzer, TranscriptToken)
|
| 17 |
from transcribe.helpers.vadprocessor import VadProcessor
|
| 18 |
# from transcribe.helpers.vad_dynamic import VadProcessor
|
| 19 |
# from transcribe.helpers.vadprocessor import VadProcessor
|
|
@@ -156,6 +155,7 @@ class WhisperTranscriptionService:
|
|
| 156 |
seg_text = self._temp_string + seg_text
|
| 157 |
|
| 158 |
if partial == False:
|
|
|
|
| 159 |
if len(seg_text) < config.TEXT_THREHOLD:
|
| 160 |
partial = True
|
| 161 |
self._temp_string = seg_text
|
|
|
|
| 12 |
|
| 13 |
from .utils import log_block, save_to_wave, TestDataWriter, filter_words
|
| 14 |
from .translatepipes import TranslatePipes
|
| 15 |
+
|
|
|
|
| 16 |
from transcribe.helpers.vadprocessor import VadProcessor
|
| 17 |
# from transcribe.helpers.vad_dynamic import VadProcessor
|
| 18 |
# from transcribe.helpers.vadprocessor import VadProcessor
|
|
|
|
| 155 |
seg_text = self._temp_string + seg_text
|
| 156 |
|
| 157 |
if partial == False:
|
| 158 |
+
# segment_length = len(seg_text.split(self.text_separator)) if self.text_separator else len(seg_text)
|
| 159 |
if len(seg_text) < config.TEXT_THREHOLD:
|
| 160 |
partial = True
|
| 161 |
self._temp_string = seg_text
|