mpi4py.MPI.Pickle — MPI for Python 3.1.4 documentation

# mpi4py.MPI.Pickle

class mpi4py.MPI.Pickle(dumps=None, loads=None, protocol=None)

  Bases: `object`

  Pickle/unpickle Python objects

  Parameters:

    - dumps (Optional[Callable[[Any, int], bytes]]) –

    - loads (Optional[Callable[[Buffer], Any]]) –

    - protocol (Optional[int]) –

  __init__(dumps=None, loads=None, protocol=None)
    Parameters:

      - dumps (Optional[Callable[[Any, int], bytes]]) –

      - loads (Optional[Callable[[Buffer], Any]]) –

      - protocol (Optional[int]) –

    Return type:

      None

  Methods Summary

  `dumps`(obj[, buffer_callback]) | Serialize object to pickle data stream.
  `loads`(data[, buffers]) | Deserialize object from pickle data stream.

  Attributes Summary

  `PROTOCOL` | pickle protocol

  Methods Documentation

  dumps(obj, buffer_callback=None)

    Serialize object to pickle data stream.

    Parameters:

      - obj (Any) –

      - buffer_callback (Optional[Callable[[Buffer], Any]]) –

    Return type:

      bytes

  loads(data, buffers=None)

    Deserialize object from pickle data stream.

    Parameters:

      - data (Buffer) –

      - buffers (Optional[Iterable[Buffer]]) –

    Return type:

      Any

  Attributes Documentation

  PROTOCOL

    pickle protocol