赞
踩
报错:
- error: can't find Rust compiler
-
- If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.
-
- To update pip, run:
-
- pip install --upgrade pip
-
- and then retry package installation.
-
- If you did intend to build this package from source, try installing a Rust compiler from your system package manager and ensure it is on the PATH during installation. Alternatively, rustup (available at https://rustup.rs) is the recommended way to download and update the Rust compiler toolchain.
- [end of output]
-
- note: This error originates from a subprocess, and is likely not a problem with pip.
- ERROR: Failed building wheel for tokenizers
- Failed to build tokenizers
- ERROR: Could not build wheels for tokenizers, which is required to install pyproject.toml-based projects
error: can't find Rust compiler
.......
ERROR: Failed building wheel for tokenizers
Failed to build tokenizers
ERROR: Could not build wheels for tokenizers, which is required to install pyproject.toml-based projects
方法:
- curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
- info: downloading installer
-
- 或者
- curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
然后重新打开终端
最后重新安装transformer
pip install transformers==4.15.0
我是第一种有效。
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。