增加了自动填充路径的功能,增加了根据显存自动选择ASR精度的功能,也可手动控制

增加了自动填充路径的功能
增加了根据显存自动选择ASR精度的功能,也可手动控制
This commit is contained in:
XXXXRT666
2024-08-01 20:53:52 +08:00
committed by GitHub
parent 7670bc77c3
commit 10e885d9ac
22 changed files with 117 additions and 72 deletions

View File

@@ -4,7 +4,8 @@ import argparse
import os
import traceback
from tqdm import tqdm
# from funasr.utils import version_checker
# version_checker.check_for_update = lambda: None
from funasr import AutoModel
path_asr = 'tools/asr/models/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-pytorch'
@@ -14,6 +15,7 @@ path_asr = path_asr if os.path.exists(path_asr) else "iic/speech_paraformer-l
path_vad = path_vad if os.path.exists(path_vad) else "iic/speech_fsmn_vad_zh-cn-16k-common-pytorch"
path_punc = path_punc if os.path.exists(path_punc) else "iic/punc_ct-transformer_zh-cn-common-vocab272727-pytorch"
model = AutoModel(
model = path_asr,
model_revision = "v2.0.4",