再次尝试在本地群集上学习mpi4py。因此我写了一个hello_world程序,它肯定不会运行!我附加了.py代码和错误。有人能指出我做错了什么吗?提前谢谢。
你好世界:
from mpi4py import MPI
comm=MPI.COMM_WORLD
print("Hello, World! My rank is: " + str(comm.rank))
错误消息:
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "./MPI_Hello_World.py", line 1, in <module>
from mpi4py import MPI
ImportError: libmpich.so.3: cannot open shared object file: No such file or directory
答案 0 :(得分:2)
我对MPI4PY并不熟悉,但看起来它需要单独的MPI安装,而不是提供自己的MPI。您是否尝试过安装一个(MPICH,Open MPI等)在大多数Linux系统上,这就像快速做一样简单
apt-get install mpich
或者你的风味套餐经理是什么。如果您想要最新和最好的,您可以从项目的网站获得相对简单的说明:
MPICH:www.mpich.org
打开MPI:wwww.open-mpi.org