CentOS安装gensim出现ERROR: Command errored out with exit status 1:

CentOS安装gensim出现ERROR: Command errored out with exit status 1:


最近在使用安装gensim包时出现下面的问题:

Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
Collecting gensim
  Using cached https://pypi.tuna.tsinghua.edu.cn/packages/24/97/2197f018ee9f8ce2f071b2d9c6711c76159aead710f8d24a2bf006082a28/gensim-4.2.0.tar.gz (23.2 MB)
Requirement already satisfied: numpy>=1.17.0 in /home/***/anaconda3/envs/***/lib/python3.6/site-packages (from gensim) (1.19.5)
Requirement already satisfied: scipy>=0.18.1 in /home/***/anaconda3/envs***/lib/python3.6/site-packages (from gensim) (1.5.4)
Requirement already satisfied: smart_open>=1.8.1 in /home/***/anaconda3/envs/***/lib/python3.6/site-packages (from gensim) (6.2.0)
Building wheels for collected packages: gensim
  Building wheel for gensim (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /home/***/anaconda3/envs/***/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-gfccadf1/gensim_da932b459cde4dd98dadfb32c9c9b2a2/setup.py'"'"'; __file__='"'"'/tmp/pip-install-gfccadf1/gensim_da932b459cde4dd98dadfb32c9c9b2a2/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-5zhb6n_2
       cwd: /tmp/pip-install-gfccadf1/gensim_da932b459cde4dd98dadfb32c9c9b2a2/
  Complete output (464 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.linux-x86_64-3.6
  creating build/lib.linux-x86_64-3.6/gensim
  copying gensim/__init__.py -> build/lib.linux-x86_64-3.6/gensim
  copying gensim/downloader.py -> build/lib.linux-x86_64-3.6/gensim
  copying gensim/interfaces.py -> build/lib.linux-x86_64-3.6/gensim
 
 中间省略非常非常长的一段

    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/***/anaconda3/envs***/bin/python -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-gfccadf1/gensim_da932b459cde4dd98dadfb32c9c9b2a2/setup.py'"'"'; __file__='"'"'/tmp/pip-install-gfccadf1/gensim_da932b459cde4dd98dadfb32c9c9b2a2/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-yb04cdrt/install-record.txt --single-version-externally-managed --compile --install-headers /home/***/anaconda3/envs/***/include/python3.6m/gensim Check the logs for full command output.

试了无数种网上查到的方法后还是不行,尝试过安装c++环境等方法,都没有用,最后使用

conda install gensim

之前安装过了,写的时候重新截图了
显示安装成功,安装成功后可以再使用

pip install gebsim=3.4

进行指定版本更新。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值