Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix accumulator bug in network pairwise parallel mode #422

Merged
merged 3 commits into from
Aug 25, 2024
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions src/network/pairwise.jl
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ function network_pairwise(T, V, cfg)::Matrix{T}
cum_node_curr = collect(graphdata.cum.cum_node_curr[1])
cum_branch_curr = collect(graphdata.cum.cum_branch_curr[1])
for i = 2:nprocs()
cum_node_curr .+= graphdata.cum_node_curr[i][:,2]
cum_branch_curr .+= graphdata.cum_branch_curr[i][:,3]
cum_node_curr .+= graphdata.cum.cum_node_curr[i]
cum_branch_curr .+= graphdata.cum.cum_branch_curr[i]
end
cum_node_curr = hcat(1:length(cum_node_curr), cum_node_curr)
coords = graphdata.cum.coords
Expand Down
2 changes: 2 additions & 0 deletions test/input/network/sgNetworkVerify1.ini
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ use_direct_grounds = False
low_memory_mode = False
solver = cg+amg
print_timings = False
parallelize = true
max_parallel = 2

[Options for pairwise and one-to-all and all-to-one modes]
included_pairs_file = None
Expand Down