关于Keras可视化遇到pydot failed to call GraphViz 的问题

一开始按照下面的顺序安装:

  1. 安装Graphviz:在graphviz的官网(网址:https://graphviz.gitlab.io/_pages/Download/Download_windows.html),选择Windows对应的mis文件进行下载。如graphviz-2.38.msi,下载安装,将bin文件夹对应的路径添加到path环境变量
  2. 安装pygraphviz:pip install graphviz
  3. 安装pydot:pip install pydot

但是还是遇到了错误OSError: pydot failed to call GraphViz.Please install GraphViz (https://www.graphviz.org/) and ensure that its executables are in the $PATH. 

查了很多资料,才知道pydot已经停止开发了,python3.5以上已经用不起来了。对策是:

pip uninstall pydot

pip install pydotplus

然后找到keras里面的utils\vis_utils.py,把里面的pydot的都替换成pydotplus。

 

 

 

 

 

你可能感兴趣的:(关于Keras可视化遇到pydot failed to call GraphViz 的问题)