parcels
parcels copied to clipboard
numpy random randint
I'm trying to use MPI to speed up a simulation. I'm using Python 3.12 and Parcels 3.0
The simulations halts with the error: File ".../envs/parcels/lib/python3.12/site-packages/parcels/particledata.py", line 40, in partitionParticlesMPI_default mpiProcs = np.randint(0, mpi_size, size=coords.shape[0]) ^^^^^^^^^^ AttributeError: module 'numpy' has no attribute 'randint'. Did you mean: 'gradient'?
In particledata.py, I replaced np.randint(...) with np.random.randint(...), which made it work