2016-10-19 4 views
0

어제 나는 pipeline을 통해 pydot 패키지를 설치하여 pydot 패키지를 추가했습니다. 나는 패키지를 가져오고, 심지어 객체를 생성 할 수 있지만, 나는하여 그래프를 생성 할 때Pydot가 그래프를 만들지 않겠습니다.

Exception: "dot.exe" not found in path. 
+1

사용중인 OS는 무엇입니까? –

+0

Windows 7 Enterprise 64 – Westerby

답변

0

수동보십시오 graphviz를 \ bin 폴더를 추가 : 나는 다음과 같은 오류가

graph.write_jpg('example1_graph.jpg') 

을 시스템 PATH에.

>>> import pydot 
>>> pydot.find_graphviz() 
{'dot': 'C:\\Program Files (x86)\\Graphviz 2.28\\bin\\dot.exe'} #... 
>>> print pydot.find_graphviz.__doc__ 
""" 
Locate Graphviz's executables in the system. 

    Tries three methods: 

    First: Windows Registry (Windows only) 
    This requires Mark Hammond's pywin32 is installed. 

    Secondly: Search the path 
    It will look for 'dot', 'twopi' and 'neato' in all the directories 
    specified in the PATH environment variable. 

    Thirdly: Default install location (Windows only) 
    It will look for 'dot', 'twopi' and 'neato' in the default install 
    location under the "Program Files" directory. 

    It will return a dictionary containing the program names as keys 
    and their paths as values. 

    If this fails, it returns None. 
""" 
+0

안녕하세요, 답변 해 주셔서 감사합니다. 그래도 문제가 발생합니다 : – Westerby

+0

pydot.find_graphviz() 오류 : – Westerby

+0

AttributeError : 'pydot'모듈에 'find_graphviz'속성이 없습니다 – Westerby

관련 문제