dcf8c1f9cef00b2d961a80689a5fc772dabeea8f,torch_geometric/utils/convert.py,,to_networkx,#Any#Any#Any#,47
Before Change
copied. (default: :obj:`None`)
G = nx.DiGraph()
G.add_nodes_from(range(data.num_nodes))
values = {key: data[key].squeeze().tolist() for key in data.keys}
After Change
copied. (default: :obj:`None`)
G = nx.Graph() if data.is_undirected() else nx.DiGraph()
G.add_nodes_from(range(data.num_nodes))
values = {key: data[key].squeeze().tolist() for key in data.keys}
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: rusty1s/pytorch_geometric
Commit Name: dcf8c1f9cef00b2d961a80689a5fc772dabeea8f
Time: 2019-06-25
Author: yutai.20m5@gmail.com
File Name: torch_geometric/utils/convert.py
Class Name:
Method Name: to_networkx
Project Name: dmlc/dgl
Commit Name: bc3f852dab30cb2b920fddd7455a623d82ca3a6a
Time: 2018-10-17
Author: coin2028@hotmail.com
File Name: python/dgl/graph_index.py
Class Name: GraphIndex
Method Name: from_networkx
Project Name: dmlc/dgl
Commit Name: bc3f852dab30cb2b920fddd7455a623d82ca3a6a
Time: 2018-10-17
Author: coin2028@hotmail.com
File Name: python/dgl/graph_index.py
Class Name: GraphIndex
Method Name: to_networkx