Skip to content

AttributeError: module 'pydot' has no attribute 'find_graphviz' #3210

@ghost

Description

My os is Ubuntu 14.04 and python version is 3.5. I just simply did what the document said:

from keras.utils.visualize_util import plot

And what I got is:

   ---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-90-65016ddab3cd> in <module>()
----> 1 from keras.utils.visualize_util import plot

/home/lcc/anaconda3/envs/sensequant/lib/python3.5/site-packages/keras/utils/visualize_util.py in <module>()
      5     # fall back on pydot if necessary
      6     import pydot
----> 7 if not pydot.find_graphviz():
      8     raise RuntimeError('Failed to import pydot. You must install pydot'
      9                        ' and graphviz for `pydotprint` to work.')

AttributeError: module 'pydot' has no attribute 'find_graphviz'

Indeed I have ensured that pydot, pydotplus, graphviz have been installed as I could import them properly. Do you know how to fix it? Thank you in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions