Discussion:
[OMPI users] communicator with MPI_Reduce
Marlborough, Rick
2016-10-19 21:50:18 UTC
Permalink
Designation: Non-Export Controlled Content
Folks;
My MPI_COMM_WORLD size is 2000. I have created a communicator based on a small subset. I have used this communicator in MPI_Barrier calls and it seems to work fine. Now I want to use this in MPI_Reduce. When I do this I get errors like "invalid root" or more mysteriously "on communicator MPI communicator 7 group from 0... invalid argument of some kind.". can someone specify how to use a communicator (that is not COMM_WORLD) with MPI_Reduce and specify rank properly.

Thanx
Rick

3.1.1001
George Bosilca
2016-10-21 06:36:13 UTC
Permalink
Rick,

There are few requirements to use any communicator in a collective
operation (including MPI_Reduce), and most of them are common sense. All
ranks in the communicator must call the collective, and the different ranks
should all reach the collective together (no unmatched blocking
communications should exists before the collective on some ranks). To focus
on the MPI_Reduce, all participants should also provide the same root rank,
which should be bounded by 0 and by the communicator size, the same MPI_Op,
and the same amount of data.

If I might I would suggest a good MPI-related book, "Using MPI ..." by
Gropp, Lusk and Skjellum (ISBN 978-0262527392). The examples are freely
available online at http://www.mcs.anl.gov/research/projects/mpi/usingmpi/.

George.
Post by Marlborough, Rick
Designation: Non-Export Controlled Content
Folks;
My MPI_COMM_WORLD size is 2000. I have created a
communicator based on a small subset. I have used this communicator in
MPI_Barrier calls and it seems to work fine. Now I want to use this in
MPI_Reduce. When I do this I get errors like “invalid root” or more
mysteriously “on communicator MPI communicator 7 group from 0
 invalid
argument of some kind.”. can someone specify how to use a communicator
(that is not COMM_WORLD) with MPI_Reduce and specify rank properly.
Thanx
Rick
3.1.1001
_______________________________________________
users mailing list
https://rfd.newmexicoconsortium.org/mailman/listinfo/users
Gilles Gouaillardet
2016-10-21 08:27:55 UTC
Permalink
Rick,


if you are using an inter communicator, please refer to the man page (a
group has to use MPI_ROOT as the root argument)


Cheers,


Gilles
Post by George Bosilca
Rick,
There are few requirements to use any communicator in a collective
operation (including MPI_Reduce), and most of them are common sense.
All ranks in the communicator must call the collective, and the
different ranks should all reach the collective together (no unmatched
blocking communications should exists before the collective on some
ranks). To focus on the MPI_Reduce, all participants should also
provide the same root rank, which should be bounded by 0 and by the
communicator size, the same MPI_Op, and the same amount of data.
If I might I would suggest a good MPI-related book, "Using MPI ..." by
Gropp, Lusk and Skjellum (ISBN 978-0262527392). The examples are
freely available online at
http://www.mcs.anl.gov/research/projects/mpi/usingmpi/.
George.
On Wed, Oct 19, 2016 at 5:50 PM, Marlborough, Rick
Designation: Non-Export Controlled Content
Folks;
My MPI_COMM_WORLD size is 2000. I have created a
communicator based on a small subset. I have used this
communicator in MPI_Barrier calls and it seems to work fine. Now I
want to use this in MPI_Reduce. When I do this I get errors like
“invalid root” or more mysteriously “on communicator MPI
communicator 7 group from 0… invalid argument of some kind.”. can
someone specify how to use a communicator (that is not COMM_WORLD)
with MPI_Reduce and specify rank properly.
Thanx
Rick
_3.1.1001
_______________________________________________
users mailing list
https://rfd.newmexicoconsortium.org/mailman/listinfo/users
<https://rfd.newmexicoconsortium.org/mailman/listinfo/users>
_______________________________________________
users mailing list
https://rfd.newmexicoconsortium.org/mailman/listinfo/users
Loading...