Merge branch 'main' of github.com:alibaba-damo-academy/FunASR

merge
This commit is contained in:
游雁 2024-07-29 11:34:27 +08:00
commit eb86f0fe6a
2 changed files with 3 additions and 3 deletions

View File

@ -14,7 +14,7 @@ workspace=`pwd`
local_path_root=${workspace}/modelscope_models
mkdir -p ${local_path_root}
local_path=${local_path_root}/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-pytorch
git clone https://www.modelscope.cn/damo/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-pytorch.git ${local_path}
git lfs clone https://www.modelscope.cn/damo/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-pytorch.git ${local_path}
device="cuda:0" # "cuda:0" for gpu0, "cuda:1" for gpu1, "cpu"

View File

@ -812,7 +812,7 @@ class LLMASR2(nn.Module):
ibest_writer = self.writer[f"{0 + 1}best_recog"]
results = []
response_clean = re.sub("[^\w\s\u3000\u4e00-\u9fff]+", "", response)
response_clean = re.sub(r"[^\w\s\u3000\u4e00-\u9fff]+", "", response)
result_i = {"key": key[0], "text": response, "text_tn": response_clean, "label": label}
if loss is not None:
result_i["loss"] = loss
@ -1395,7 +1395,7 @@ class LLMASR4(nn.Module):
ibest_writer = self.writer[f"{0 + 1}best_recog"]
results = []
response_clean = re.sub("[^\w\s\u3000\u4e00-\u9fff]+", "", response)
response_clean = re.sub(r"[^\w\s\u3000\u4e00-\u9fff]+", "", response)
result_i = {"key": key[0], "text": response, "text_tn": response_clean, "label": label}
if loss is not None:
result_i["loss"] = loss