我一直试图从NetworkX库导入必要的模块,但它一直在抛出ImportError或AttributeError。我在最后一年的项目中使用了NetworkX库,我想使用来计算给定图的树宽分解,在其他函数之前我需要它的值。我尝试了以下几点:
from networkx.algorithms import approximation' has no attribute 'treewidth_min_fill_in
,它得到了2.6版本easy_install网络xSearching for networkxProcessing networkx-1.7-py2.6.eggAdding networkx 1.7 to easy-install.pth,但它仍然下载到2.6版本的库中easy_install Downloading h
我尝试使用easy_install和pip在mac上安装python2.7的networkx包。然而,我无法让它发挥作用。当我使用easy_install时,我得到以下消息:Best match: networkx 1.7networkx 1.7 is already the active version in easy-install.pth
Using /Library