Error
(cosyvoice) root@dsw-759611-5cfc59b894-ckcnz:/mnt/workspace/CosyVoice# python test.py
2024-12-03 22:51:37,879 - modelscope - INFO - PyTorch version 2.0.1+cu118 Found.
2024-12-03 22:51:37,888 - modelscope - INFO - Loading ast index from /mnt/workspace/.cache/modelscope/ast_indexer
2024-12-03 22:51:37,964 - modelscope - INFO - Updating the files for the changes of local files, first time updating will take longer time! Please wait till updating done!
2024-12-03 22:51:37,975 - modelscope - INFO - AST-Scanning the path "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope" with the following sub folders ['models', 'metrics', 'pipelines', 'preprocessors', 'trainers', 'msdatasets', 'exporters']
Traceback (most recent call last):
File "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope/utils/ast_utils.py", line 467, in _get_single_file_scan_result
output = self.astScaner.generate_ast(file)
File "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope/utils/ast_utils.py", line 366, in generate_ast
output = self.scan_import(node, show_offsets=False)
File "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope/utils/ast_utils.py", line 165, in scan_import
local_out = _scan_import(el, type(el).__name__)
File "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope/utils/ast_utils.py", line 134, in _scan_import
return self.scan_import(
File "/root/miniconda3/envs/cosyvoice/lib/python3.8/site-packages/modelscope/utils/ast_utils.py", line 152, in scan_import
attr = getattr(node, field)
AttributeError: 'ClassDef' object has no attribute 'type_params'
Solution
Resintall modelscope