data_parser.py 文件源码

python
阅读 25 收藏 0 点赞 0 评论 0

项目:visa_free 作者: BBischof 项目源码 文件源码
def make_graph(list_of_edges):
  G = nx.Graph()
  for x in list_of_edges:
    pair = tuple(x.split("-", 1))
    G.add_edge(pair[0], pair[1])
  print len(G.edges())
  pos=nx.fruchterman_reingold_layout(G)
  nx.draw(G,pos)
  plt.show()
  return len(list_of_edges)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号