浏览代码

Give dimension as keyword arg

Is this going to fix errors with different versions of networkx? I don't
know -- I'm on a plane mate.
master
Pete Shadbolt 8 年前
父节点
当前提交
ae65d09e7f
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      abp/fancy.py

+ 1
- 1
abp/fancy.py 查看文件

@@ -50,7 +50,7 @@ class GraphState(graphstate.GraphState, networkx.Graph):

def layout(self):
""" Automatically lay out the graph """
pos = networkx.spring_layout(self, 3, scale=np.sqrt(self.order()))
pos = networkx.spring_layout(self, dim=3, scale=np.sqrt(self.order()))
middle = np.average(pos.values(), axis=0)
pos = {key: value - middle for key, value in pos.items()}
for key, (x, y, z) in pos.items():


正在加载...
取消
保存