这是一个简短的python脚本:import matplotlib.pyplot as pltimport networkx as nxfrom networkx.drawing.nx_agraph import graphviz_layoutG = nx.DiGraph()当它由普通 python 执行时,它给出了以下堆栈跟踪:Traceback (most recent call last): File "python/spikes/networkx.py", line 17, in <module> import networkx as nx File "/home/peng/git/mxnet-spike/python/spikes/networkx.py", line 18, in <module> from networkx.drawing.nx_agraph import graphviz_layoutModuleNotFoundError: No module named 'networkx.drawing'; 'networkx' is not a package什么可能导致这种情况?python解释器有缺陷吗?
添加回答
举报
0/150
提交
取消