它看起来像是' bert-base-uncased'不是有效的JSON文件吗?

发布于 2025-01-28 15:55:42 字数 311 浏览 2 评论 0原文

几个月正常工作,然后我中断了“ bert-large canced”下载,以下代码返回标题中的错误:

from transformers import BertModel
BertModel.from_pretrained('bert-base-uncased')

我尝试过:

  1. 删除.cache/trransformers/
  2. ...卸载/重新安装变压器
  3. CONDA删除/安装变压器
  4. 完全重新安装Anaconda和我的环境

Working fine for months, then I interrupted a "bert-large-cased" download and the following code returns the error in the title:

from transformers import BertModel
BertModel.from_pretrained('bert-base-uncased')

I've tried:

  1. deleting .cache/transformers/...
  2. pip uninstall/reinstall transformers
  3. conda remove/install transformers
  4. completely reinstalling anaconda and my environment from scratch

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

若有似无的小暗淡 2025-02-04 15:55:42

您需要编写automodel.from_pretrataining('bert-base-cased')

You need to write AutoModel.from_pretrained('bert-base-cased').

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文