sisl.mpi.BaseCommunicator
- class sisl.mpi.BaseCommunicator[source]
Bases:
ABCThe communicator contract sisl relies on.
Only what cannot be delegated appears here: which rank this is, how many there are, and who owns MPI. Every actual operation – collectives, point-to-point, communicator management – is reached through
__getattr__on the implementations, so this contract does not have to track mpi4py’s surface.Two classes implement it:
Communicator, wrapping a real mpi4py communicator, and the serial stand-in used when there is no MPI.Methods
on_rank0()True on the rank that should perform single-writer work (IO, printing).
Attributes
The underlying communicator object.
Whether sisl initialized MPI, and must therefore finalize it.
Index of this rank within the communicator.
Number of ranks in the communicator.
- on_rank0()[source]
True on the rank that should perform single-writer work (IO, printing).
- Return type:
- abstract property comm
The underlying communicator object.