modelscope-funasr跑官方示例的时候,报错,怎么解决?报错如下python3.10,furasr==1.0.0
KeyError Traceback (most recent call last)
Cell In[3], line 4
1 from funasr import AutoModel
2 # paraformer-zh is a multi-functional asr model
3 # use vad, punc, spk or not as you need
----> 4 model = AutoModel(model="paraformer-zh", model_revision="v2.0.2",
5 vad_model="fsmn-vad", vad_model_revision="v2.0.2",
6 punc_model="ct-punc-c", punc_model_revision="v2.0.3",
7 # spk_model="cam++", spk_model_revision="v2.0.2",
8 )
9 res = model.generate(input=f"{model.model_path}/example/asr_example.wav",
10 batch_size_s=300,
11 hotword='魔搭')
12 print(res)
File e:\envs\py310\lib\site-packages\funasr\auto\auto_model.py:100, in AutoModel.init(self, kwargs)
98 logging.info("Building VAD model.")
99 vad_kwargs = {"model": vad_model, "model_revision": vad_kwargs}
--> 100 vad_model, vad_kwargs = self.build_model(vad_kwargs)
102 # if punc_model is not None, build punc model else None
103 punc_model = kwargs.get("punc_model", None)
File e:\envs\py310\lib\site-packages\funasr\auto\auto_model.py:143, in AutoModel.build_model(self, kwargs)
141 if "model_conf" not in kwargs:
142 logging.info("download models from model hub: {}".format(kwargs.get("model_hub", "ms")))
--> 143 kwargs = download_model(kwargs)
145 set_all_random_seed(kwargs.get("seed", 0))
147 device = kwargs.get("device", "cuda")
File e:\envs\py310\lib\site-packages\funasr\download\download_from_hub.py:11, in download_model(kwargs)
9 model_hub = kwargs.get("model_hub", "ms")
10 if model_hub == "ms":
---> 11 kwargs = download_from_ms(kwargs)
13 return kwargs
File e:\envs\py310\lib\site-packages\funasr\download\download_from_hub.py:48, in download_from_ms(**kwargs)
46 conf_json = json.load(f)
47 cfg = {}
---> 48 add_file_root_path(model_or_path, conf_json["file_path_metas"], cfg)
49 cfg.update(kwargs)
50 config = OmegaConf.load(cfg["config"])
KeyError: 'file_path_metas'