未安装spacy

2024-09-30 16:21:34 发布

您现在位置:Python中文网/ 问答频道 /正文

当我用pip安装spacy时,它下载了一堆文件,但是最后这个错误出现了,spacy没有安装,尽管安装了setuptools。在

命令"/usr/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-jugolqe4/murmurhash/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-fwk4l5m8/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-jugolqe4/murmurhash/


Tags: installpip文件spacycodeopenrecordsetuptools
1条回答
网友
1楼 · 发布于 2024-09-30 16:21:34

为了提高性能,spaCy的许多部分都是用Cython编写的。因此,为了使用spaCy库,您需要一个C编译器来编译Cython代码。在

您可以尝试在终端中运行以下命令,然后重试安装spacy。在

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install build-essential
gcc -v
make -v

相关问题 更多 >