I am gathering a list of nested dictionaries. This worked as expected via:comm.gather(nested_dicts, root=0) (*)But, as I have scaled, I encountered the error:SystemError: Negative size passed to PyBytes_FromStringAndSize
Thus, I instead tried to use comm.Gather(sendbuf, recvbuf, root=0). Now I am receiving the error:TypeError: a bytes-like object is required, not 'dict'
Where I replaced (*) with:recvbuf = None
if rank == 0:
recvbuf = np.empty([size, len(nested_dicts)])
comm.Gather(nested_dicts, recvbuf, root=0)I would appreciate any help.
Hi Lisandro,> Up to today, only MPICH v4.x supports MPI-4.I am working on a cluster that only provides Open MPI. Any idea if Open MPI will support MPI-4 in the near future?
Hi Lisandro,
> Unfortunately, the only solution to this is to use an MPI-4 implementation with support for large-count (64bit) messages. Up to today, only MPICH v4.x supports MPI-4. And to take advantage of the new large-count support, you should use mpi4py from git master branch.With the above implementation, is it still possible that the total size of the incoming data at the root is too large?
I will be gathering several million pairs of floats. Is there a way to know whether this will be a problem ex-ante?
I suppose I could use a numpy array of object datatype, but I prefer the simplicity of lower case gather().