node2vec_linkprediction icon indicating copy to clipboard operation
node2vec_linkprediction copied to clipboard

KeyError: 'weight

Open zuozijiZHOULI opened this issue 6 years ago • 0 comments

Traceback (most recent call last): File "link_prediction.py", line 548, in test_edge_functions(args) File "link_prediction.py", line 343, in test_edge_functions Gtrain.train_embeddings(p, q, dimensions, num_walks, walk_length, window_size) File "link_prediction.py", line 228, in train_embeddings self.preprocess_transition_probs() File "C:\Users\zhouli\Desktop\论文研究开展资料\experiment\node2vec_linkprediction\node2vec.py", line 85, in preprocess_transition_probs unnormalized_probs = [G[node][nbr]['weight'] for nbr in sorted(G.neighbors(node))] KeyError: 'weight

zuozijiZHOULI avatar Oct 18 '18 02:10 zuozijiZHOULI