-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* avoid reductions with custom operators for MPI * avoid MultiScalar reduction only on non-intel * move changes to mapreduce * small tweak * fix mpi errors * clean up * use MPI logical operator directly * Remove MultiScalar from sort_into_targets! fciqmc_col! may now return stats as a vector * Revert "Remove MultiScalar from sort_into_targets!" This reverts commit b54868f. --------- Co-authored-by: Joachim Brand <[email protected]>
- Loading branch information
1 parent
8819209
commit 053c5ec
Showing
7 changed files
with
52 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Make MPI reduction of a `MultiScalar` work on non-Intel processors. | ||
# The `MultiScalar` is converted into a vector before sending through MPI.Allreduce. | ||
# Testing shows that this is about the same speed or even a bit faster on Intel processors | ||
# than reducing the MultiScalar directly via a custom reduction operator. | ||
# Defining the method in RMPI is strictly type piracy as MultiScalar belongs to Rimu and | ||
# not to RMPI. Might clean this up later. | ||
function MPI.Allreduce(ms::Rimu.MultiScalar{T}, op, comm::MPI.Comm) where {T<:Tuple} | ||
result_vector = MPI.Allreduce([ms...], op, comm) | ||
return Rimu.MultiScalar(T(result_vector)) | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters