bamboost.mpi.mock
Mock module for mpi4py.MPI
to be used when MPI is not available or usage not desired.
Not importing MPI increases launch speed significantly, which is important for CLI
applications.
Attributes
- SUM=
lambda a, b: a + b
Mock object for
mpi4py.MPI.COMM_WORLD
Mock object for
mpi4py.MPI.COMM_SELF
Mock object for
mpi4py.MPI.COMM_NULL
Classes
Comm
Comm
(self)
Attributes:
- size=
1
- rank=
0
- comm=
None
- is_mpi=
False
- is_master=
True
Comm.barrier
(self)
Comm.finalize
(self)
Comm.bcast
(self, data, root=0)
Arguments:
- data
- root=
0
Comm.scatter
(self, data, root=0)
Arguments:
- data
- root=
0
Comm.gather
(self, data, root=0)
Arguments:
- data
- root=
0
Comm.allgather
(self, data)
Arguments:
- data
Comm.allreduce
(self, data, op)
Arguments:
- data
- op
Comm.reduce
(self, data, op, root=0)
Arguments:
- data
- op
- root=
0
Comm.send
(self, data, dest, tag=0)
Arguments:
- data
- dest
- tag=
0
Comm.recv
(self, source, tag=0)
Arguments:
- source
- tag=
0
Comm.recv_any_source
(self, tag=0)
Arguments:
- tag=
0
Comm.sendrecv
(self, send_data, dest, tag=0)
Arguments:
- send_data
- dest
- tag=
0
Comm.sendrecv_replace
(self, data, dest, tag=0)
Arguments:
- data
- dest
- tag=
0
Comm.get_processor_name
(self)
Comm.get_version
(self)
Comm.get_library_version
(self)
Comm.get_error_string
(self, errorcode)
Arguments:
- errorcode
Comm.get_exception_class
(self)
Comm.get_exception_string
(self, errorcode)
Arguments:
- errorcode
Comm.get_count
(self, status, datatype)
Arguments:
- status
- datatype
Comm.get_status
(self, request)
Arguments:
- request
Comm.get_source
(self, status)
Arguments:
- status
Comm.get_tag
(self, status)
Arguments:
- status
Comm.get_elements
(self, status)
Arguments:
- status
Comm.get_bytes
(self, status)
Arguments:
- status
Comm.get_cancelled
(self, status)
Arguments:
- status
Comm.get_topo
(self)
Comm.get_cart
(self)
Comm.get_dims
(self)
Comm.get_coords
(self)
Comm.get_rank
(self)
Comm.get_size
(self)
Comm.Get_size
(self)