Closed paulsbrookes closed 4 years ago
Hey Paul, mmm not sure! These things are quite hard for me to debug. But just to check, what version of these are you using:
On Ubuntu, with gcc, openmpi 4.0.0 or 1.10.7, and the latest versions of slepc
and petsc
(and mpi4py
, slepc4py
and petsc4py
) your snippet works fine for me.
Hey Johnie. Here's the info:
--download-openmpi
when configuring petsc
, but I don't know which version was downloaded.petsc 3.12
slepc 3.12.1
mpi4py 3.0.3
petsc4py 3.12.0
slepc4py 3.12.0
I found a couple of other questions (linked below) which mention this kind of error. One possibility is related to having multiple versions of MPI. petsc
is presumably using the version of OpenMPI it downloaded, but I do have other versions of MPI on my computer, which may be interfering later on. But I don't really understand it.
Ah yes, I suspect multiple MPIs + which mpi4py is pointing at vs which slepc4py is pointing at is the issue. MPI is the one bit of slepc that's probably best installed separately. Some stuff to try:
If you are using a cluster, use their MPI for sure. Else I generally compile a local version of openmpi v1.10.7 and use that.
Thanks Johnnie! I installed mpi4py
using env MPICC=/path/to/mpicc pip install mpi4py
as detailed in https://mpi4py.readthedocs.io/en/stable/install.html and that seems to have fixed the problem.
Hi. I have been trying to build
petsc
andslepc
to use theslepc
andslepc-nompi
backends foreigh
. Bothpetsc
andslepc
pass their tests but when I try to useslepc-nompi
I receive an error message which I don't understand. Here is the code:The error message is:
Do you know what might be causing this error?