Сашко Лихенко Сашко Лихенко - 6 months ago 49
Python Question

Python does not see pygraphviz

I have installed pygraphviz using easy_install
But when i launch python i have an error:

>>>import pygraphviz as pgv
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named pygraphviz

Using Ubuntu 12.04 and gnome-terminal.


Assuming that you're on Ubuntu please look at following steps

  1. sudo apt-get install graphviz libgraphviz-dev pkg-config
  2. Create and activate virtualenv if needed. The commands looks something like sudo apt-get install python-pip python-virtualenv
  3. Run pip install pygraphviz
  4. Run terminal and check by importing and see if it works