Reputation: 1558
I recently upgraded Ubuntu from 14.04 to 16.04 and I have strange issues with using python igraph (on anaconda). I didn't have any issues in the 14.04.
Specifically - pip install python-igraph seems to work:
Collecting python-igraph
Installing collected packages: python-igraph
Successfully installed python-igraph-0.7.1.post6
However,trying to import igraph (in ipython on Python 2.7.12 |Anaconda 4.2.0 (64-bit) I get the following:
ImportError Traceback (most recent call last)
<ipython-input-3-8e950eb5d8d8> in <module>()
----> 1 import igraph
/home/scifric/anaconda2/lib/python2.7/site-packages/igraph/__init__.py in <module>()
32 # pylint: disable-msg=W0401
33 # W0401: wildcard import
---> 34 from igraph._igraph import *
35 from igraph._igraph import __version__, __build_date__
36 from igraph.clustering import *
ImportError: /home/scifric/anaconda2/lib/python2.7/site- ackages/igraph/_igraph.so: undefined symbol: _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev
I saw some threads with similar problems on Linux Arch or OSX and none of the solutions seem to fit. Any idea what is missing?
Thanks!
Upvotes: 1
Views: 801
Reputation: 1558
After installing/reinstalling/uninstalling/recompiling of the python igraph and the c core libraries yielding frustrations, here is what worked: I uninstalled python-igraph both with pip and conda I deleted ALL igraph directories after searching for all traces from root (cd / then sudo find -name igraph). Now here is the magic thanks to Tamás Nepusz (@ntamas): Simply install the precompiled binary package for Anaconda Python:
conda install -c marufr python-igraph=0.7.1.post6
taken from here: https://anaconda.org/marufr/python-igraph
It's that's simple. (But I'm still puzzled by the conflict between the python igraph and the c libraries I experienced before. At least noe I have it working).
Upvotes: 3