I have this piece of code:
comm = MPI.COMM_WORLD temp = np.zeros(blockSize*blockSize) PrintNB("Communicate A to", get_left_rank()) comm.Sendrecv(sendbuf=np.ascontiguousarray(lA), dest=get_left_rank(), recvbuf=temp) lA = np.reshape(temp, (blockSize, blockSize)) PrintNB("Finished sending")
lA being a numpy array. Output is:
 Communicate A to 1  Communicate A to 3  Communicate A to 2  Communicate A to 0  Finished sending # here it blocks
[n] is the rank. I have a circular send. 0>1, 1>0 and 2>3, 3>2. I understood Sendrec so that it is made specifically for these cases, but still it blocks.
What is the problem here?