【ERROR】Could not build wheels for tokenizers, which is required to install pyproject.toml-based proj

配置环境

Platform: MACOS m1 / Virtual Env
Python version: python 3.6 
Tensorflow version: 2.6.2
Torch version: 1.2.0

安装transformers时,使用下面的命令出现报错:

pip install transformers

出现以下错误:
【ERROR】Could not build wheels for tokenizers, which is required to install pyproject.toml-based proj_第1张图片


解决办法
参考网站:

https://github.com/huggingface/transformers/issues/2831

使用下面的命令:

pip install transformers==2.4.1

【ERROR】Could not build wheels for tokenizers, which is required to install pyproject.toml-based proj_第2张图片
成功了!但是我也不是很明白为什么指定版本就成功了。

你可能感兴趣的:(bug,Python,python,深度学习,开发语言,transformer)