zjunlp / DeepKE

[EMNLP 2022] An Open Toolkit for Knowledge Graph Extraction and Construction
http://deepke.zjukg.cn/
MIT License
3.52k stars 682 forks source link

I downloaded the pre-trained model and it still reports errors #464

Closed jiangshanghe closed 6 months ago

jiangshanghe commented 6 months ago

Describe the bug

A clear and concise description of what the bug is.

OSError: We couldn't connect to 'https://hf-mirror.com/' to load this file, couldn't find it in the cached files and it looks like bert-base-chinese is not the path to a directory containing a file named config.json.

Environment (please complete the following information):

Screenshots

If applicable, add screenshots to help explain your problem.

image

Additional context

Add any other context about the problem here.

jiangshanghe commented 6 months ago

我连不上huggigface的外网,然后找了一个镜像站,代码通过镜像站也还是下载不了模型,然后我自己手动去下载了一个,放到了pretrianed文件夹下面,运行的时候还是无法load显示报错。请问如何解决?万分感谢!

xxupiano commented 6 months ago

请问您运行的哪个代码?是否修改对应的模型名为模型路径?

jiangshanghe commented 6 months ago

这个是deepke的re中standard的run.py。我在preprocess.py里面修改了tokenixer,填了绝对路径

xxupiano commented 6 months ago
  1. 可能是修改之后没有再次python setup.py develop;
  2. 其实无需修改src里的文件,修改 https://github.com/zjunlp/DeepKE/blob/main/example/re/standard/conf/model/lm.yaml#L6 即可
zxlzr commented 6 months ago

请问您的问题解决了吗?

jiangshanghe commented 6 months ago

问题解决了,但是又有一个新的问题。不过好在现在可以运行起来。 image

xxupiano commented 6 months ago

“wandb:Network error”网络无法连接到wandb,可以注释掉包含wandb的几行代码,不使用wandb即可

jiangshanghe commented 6 months ago

好的,谢谢!

zxlzr commented 6 months ago

请问您的问题解决了吗?