LibraryHandle#
-
class cuquantum.
pauliprop. experimental. LibraryHandle(
)[source]#
Methods
- get_communicator()[source]#
Return the communicator previously passed to
set_communicator().
- set_communicator(
- comm: mpi4py.MPI.Comm | NcclCommunicator | DistributedContext | tuple[int, int] | int | None = None,
- provider: Literal['MPI', 'NCCL'] | DistributedProvider | None = None,
Register a communicator with this library handle.
provideris inferred frommpi4py.MPI.Comm,nccl.core.Communicator, andnvmath.distributed.DistributedContext(which supplies its NCCL communicator and therefore requires initialization with the"nccl"backend). Rawint/(ptr, size)inputs require an explicit provider. Before replacing or clearing a communicator, destroy all objects created from this handle.- Parameters:
comm – Communicator object,
nvmath.distributedcontext, raw pointer,(ptr, size)pair, orNone.provider –
"MPI"or"NCCL"(uppercase), or aDistributedProvider. Optional when inferable. Pass no arguments, or passcomm=None, to restore single-process execution.
Attributes
- device_id#