首页 > 解决方案 > Predictor.from_path('coref-spanbert-large-2021.03.10.tar.gz') 将模型下载到缓存中,尽管我提供了模型的本地副本

问题描述

我正在尝试使用加载coref-spanbert模型的本地副本,Predictor.from_path但它开始再次将模型下载到缓存/拥抱面中。谁能帮我解决这个问题。

>>> from allennlp.predictors import Predictor
>>> coref_model = Predictor.from_path('coref-spanbert-large-2021.03.10.tar.gz')
Downloading: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 414/414 [00:00<00:00, 436kB/s]
Downloading: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 213k/213k [00:00<00:00, 239kB/s]
Downloading:  34%|███████████████████████████████████████████████████

标签: huggingface-transformersallennlpcoref-spanbert

解决方案


推荐阅读