安装graphtool python时出错

Posted

技术标签:

【中文标题】安装graphtool python时出错【英文标题】:error installing graphtool python 【发布时间】:2017-04-29 18:27:14 【问题描述】:

我正试图在 centos 上安装 graphtool,但收到错误消息。

这是我尝试过的:

(python_2.7_numerical) [lpuggini@machinelearn-1 ~]$ pip install git+https://github.com/count0/graph-tool
Collecting git+https://github.com/count0/graph-tool
  Cloning https://github.com/count0/graph-tool to /tmp/pip-dU9eDe-build
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
    IOError: [Errno 2] No such file or directory: '/tmp/pip-dU9eDe-build/setup.py'

    ----------------------------------------

(python_2.7_numerical) [lpuggini@machinelearn-1 ~]$ pip install graphtool
Collecting graphtool
  Using cached graphtool-0.5.2.tar.gz
Collecting CherryPy<=3.1 (from graphtool)
  Using cached CherryPy-3.1.0.tar.gz
Collecting matplotlib<=0.90.1 (from graphtool)
  Using cached matplotlib-0.86.2.tar.gz
    Complete output from command python setup.py egg_info:
    installing data to ./matplotlib/mpl-data
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-16Qbh5/matplotlib/setup.py", line 201, in <module>
        build_transforms(ext_modules, packages, NUMERIX)
      File "setupext.py", line 760, in build_transforms
        add_numpy_flags(module)
      File "setupext.py", line 119, in add_numpy_flags
        module.include_dirs.append(numpy.get_numpy_include())
    AttributeError: 'module' object has no attribute 'get_numpy_include'

我也试过手动安装,但是依赖太多,太复杂了

【问题讨论】:

【参考方案1】:

您使用的是哪个图形工具?如果你使用 matplotlib %matplotlib 内联

当我在 Azureml 中开发时,这通常对我有用

in Ipython notebook, Pandas is not displying the graph I try to plot

【讨论】:

【参考方案2】:

由于图形工具在后台使用 C,因此安装有点棘手。

在此处查看安装说明https://git.skewed.de/count0/graph-tool/-/wikis/installation-instructions

【讨论】:

以上是关于安装graphtool python时出错的主要内容,如果未能解决你的问题,请参考以下文章

安装 python 模块时出错

python安装pymongo时出错

为 python 安装 Dlib 库时出错

python 安装pypoppler时出错

为 Python 2.7 构建/安装 C 模块时出错

安装 mysql-python 时出错:找不到 -lssl 的库