Besides the mpi4py
package, conda-forge
is also offering a msmpi
package which is probably intended to be used with the mpi4py
package.
This is probably the reason why installing mpi4py
on the Anaconda Prompt (Anaconda3) on Windows 10 (Microsoft) gives the following error message:
if exist "C:\Windows\System32\msmpi.dll" (
echo "You seem to have a system wide installation of MSMPI. "
echo "Due to the way DLL loading works on windows, system wide installation "
echo "will probably overshadow the conda installation. Uninstalling "
echo "the system wide installation and forced deleting C:\Windows\System32\msmpi*.dll"
echo "will help, but may break other software using the system wide installation."
)
This file is indeed present after the installation of Microsoft MPI and it's path gets appended to the PATH
variable by the installer.
I uninstalled the system-wide Microsoft MPI installation, but it didn't solve the problem (error message).
I followed the instructions and renamed (also tried deleting) C:\Windows\System32\msmpi.dll
(as well as C:\Windows\System32\msmpires.dll
as suggested by another website), but the error message remains.
In addition, my Python script aborts with the error message
MPI_Win_allocate shared (...) failed
What additional diagnostics could I run in order to pin down the problem?
A related question can be found on How to prevent local msmpi installation from loading system wide msmpi.dll, but renaming msmpi.dll
seemed to help in this case.
There is also a C:\Windows\SysWOW64\msmpi.dll
and C:\Windows\SysWOW64\msmpires.dll
which I renamed, but also this didn't help.
What's strange, that How to install mpi4py on Windows 10 with msmpi suggests that MS-MPI actually has to be installed to install mpi4py
.