xlax
xlax

Reputation: 2741

No module named igraph - Error

I am using anaconda on mac-osx and have installed python-igraph. Currently not being able to import igraph.

Below is the error shown:

Python 2.7.12 |Anaconda 4.1.1 (x86_64)|

import igraph ---- ImportError: No module named igraph

It is present in this path - /Users/pc_name/anaconda/lib/python2.7/site-packages and I find only python_igraph-0.7.1.post6-py2.7.egg-info file.

I tried many things possible which are available on the other questions here at stack overflow. How can I solve this problem?

Upvotes: 7

Views: 17167

Answers (3)

Sarwan Ali
Sarwan Ali

Reputation: 169

I used the following command and it worked for me in Python 3.7

pip install python-igraph

The detail about the package and its installation can be found https://igraph.org/python/

Upvotes: 5

George Nwankwo
George Nwankwo

Reputation: 15

1)While in the python-igraph-master directory on my computer run the following:

conda install -c marufr python-igraph 

2)In a new terminal window kick start python:

$python
Python 2.7.13 |Anaconda 4.3.1 (x86_64)| (default, Dec 20 2016, 23:05:08) 
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://anaconda.org
>>> import igraph
>>>

I hope this helps

Upvotes: 0

Tamás
Tamás

Reputation: 48101

You haven't mentioned how you installed python-igraph so it's hard to say anything. But I'm pretty sure that this package works nicely.

Upvotes: 1

Related Questions