【发布时间】:2018-09-21 02:53:51
【问题描述】:
我正在尝试运行这个脚本 https://github.com/dennybritz/nn-theano/blob/master/nn-theano.ipynb,它使用 theano 实现了一个神经网络。
一切顺利,直到我到达牢房:
theano.printing.pydotprint(forward_prop, var_with_name_simple=True, compact=True, outfile='img/nn-theano-forward_prop.png', format='png')
SVG(theano.printing.pydotprint(forward_prop, var_with_name_simple=True, compact=True, return_image=True, format='svg'))
然后我得到这个错误:
RuntimeError Traceback (most recent call last) <ipython-input-11-db44e43f05ee> in <module>() ----> 1 theano.printing.pydotprint(forward_prop, var_with_name_simple=True, compact=True, outfile='img/nn-theano-forward_prop.png', format='png') 2 SVG(theano.printing.pydotprint(forward_prop, var_with_name_simple=True, compact=True, return_image=True, format='svg'))~\Anaconda3\lib\site-packages\theano\printing.py in pydotprint(fct, outfile, compact, format, with_ids, high_contrast, cond_highlight, colorCodes, max_label_size, scan_graphs, var_with_name_simple, print_output_file, return_image) 781 "和 pydot 或 pydot-ng for " 第782章 --> 783 pydot_imported_msg) 784 785 g = pd.Dot()
RuntimeError: ('Failed to import pydot. You must install graphviz and either pydot or pydot-ng for `pydotprint` to work.', 'An error happened while importing/trying pydot: (2, \'"dot.exe" not found in path.\', None, 2, None)')
我已阅读有关 Stack 的其他问题,并尝试通过 https://graphviz.gitlab.io/ 安装 graphviz
我安装了 pydot、pydotplus、graphviz (2.38.0) 和 python-graphviz (0.8.2)。 我正在使用我最近更新的 Anaconda Navigator。 Python 3.6.4 Windows 10 32 位。
【问题讨论】:
标签: python anaconda theano pydot