mpi4py.MPI.memory
- class mpi4py.MPI.memory
Bases:
object
Memory buffer.
Methods Summary
allocate
(nbytes[, clear])Memory allocation.
fromaddress
(address, nbytes[, readonly])Memory from address and size in bytes.
frombuffer
(obj[, readonly])Memory from buffer-like object.
release
()Release the underlying buffer exposed by the memory object.
tobytes
([order])Return the data in the buffer as a byte string.
Return a readonly version of the memory object.
Attributes Summary
Memory address.
Format of each element.
Size (in bytes) of each element.
Memory size (in bytes).
Object exposing the memory.
Memory is read-only.
Methods Documentation
- static allocate(nbytes, clear=False)
Memory allocation.
- static fromaddress(address, nbytes, readonly=False)
Memory from address and size in bytes.
- static frombuffer(obj, readonly=False)
Memory from buffer-like object.
- tobytes(order=None)
Return the data in the buffer as a byte string.
Attributes Documentation
- address
Memory address.
- format
Format of each element.
- itemsize
Size (in bytes) of each element.
- nbytes
Memory size (in bytes).
- obj
Object exposing the memory.
- readonly
Memory is read-only.