yzhangcs / parser

:rocket: State-of-the-art parsers for natural language.
https://parser.yzhang.site/
MIT License
825 stars 138 forks source link

TypeError: code expected at most 16 arguments, got 19 #139

Closed xiaoAugenstern closed 2 months ago

xiaoAugenstern commented 4 months ago

parser = Parser.load('dep-biaffine-xlmr',reload=True)

Downloading https://github.com/yzhangcs/parser/releases/download/v1.1.0/ud.biaffine.dep.xlmr.zip to /home/xiaoman/.cache/supar/ud.biaffine.dep.xlmr.zip 100%|████████████████████████████████████████████████████████████████████████████████████████| 1.75G/1.75G [02:37<00:00, 11.9MB/s] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/xiaoman/anaconda3/envs/supar/lib/python3.10/site-packages/supar/parser.py", line 565, in load state = torch.load(path, map_location='cpu') File "/home/xiaoman/anaconda3/envs/supar/lib/python3.10/site-packages/torch/serialization.py", line 1014, in load return _load(opened_zipfile, File "/home/xiaoman/anaconda3/envs/supar/lib/python3.10/site-packages/torch/serialization.py", line 1422, in _load result = unpickler.load() File "/home/xiaoman/anaconda3/envs/supar/lib/python3.10/site-packages/dill/_dill.py", line 805, in _create_code return CodeType(args[0], 0, 0, *args[1:]) TypeError: code expected at most 16 arguments, got 19

请问这个错误是什么原因,TypeError: code expected at most 16 arguments, got 19 (1)已经从源代码下载了 pip install -U git+https://github.com/yzhangcs/parser

(2)升级python版本为3.10

(3)pytorch和transformers版本 Successfully installed huggingface-hub-0.21.4 supar-1.1.4 tokenizers-0.15.2 transformers-4.38.2 pytorch版本也是 2.1.2+cu121

github-actions[bot] commented 2 months ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 2 months ago

This issue was closed because it has been inactive for 7 days since being marked as stale.