Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion graphsage/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def run_random_walks(G, nodes, num_walks=N_WALKS):
for i in range(num_walks):
curr_node = node
for j in range(WALK_LEN):
next_node = random.choice(G.neighbors(curr_node))
next_node = random.choice(list(G.neighbors(curr_node)))
# self co-occurrences are useless
if curr_node != node:
pairs.append((node,curr_node))
Expand Down