2017-06-04 23 views
0

得到错误在下面的代码调用pydotplus.graph_from_dot_dataInvocationException:找不到的GraphViz的可执行文件(Python)的

from IPython.display import Image 

dot_data = tree.export_graphviz(clf, 
           out_file=None, 
           feature_names=iris.feature_names, 
           class_names=iris.target_names, 
           filled=True, 
           rounded=True, 
           special_characters=True) 
graph = pydotplus.graph_from_dot_data(dot_data) 
Image(graph.create_png()) 

错误输出:

File "C:\Users\ss\Anaconda3\lib\site-packages\pydotplus\graphviz.py", line 1960, in create 'GraphViz\'s executables not found') 
InvocationException: GraphViz's executables not found 
+0

嗨,欢迎来到堆栈溢出。请参考 [stackoverflow.com/help/how-to-ask](https://stackoverflow.com/help/how-to-ask)关于 的更多详细信息,以了解如何提出问题并相应地更新您的问题。 –

+0

[Graphviz的可执行文件找不到(Python 3.4)](https://stackoverflow.com/questions/28312534/graphvizs-executables-are-not-found-python-3-4) – lepsch

回答

相关问题