Installing pyamgx and cupy on windows - epicf/ef GitHub Wiki
pyamgx and cupy on windows
Step-by-step install guide, works on Windows 10
Requirements
python >=3.6,<=3.7
CUDA
Latest CUDA (1.0.2) works now.
Cmake
Compiler
Use Visual Studio 2017, AMGX does not compile with VS2019: https://github.com/NVIDIA/AMGX/issues/79
scipy and cython
pip install scipy cython
Build/install
cupy
Just pip install cupy-cuda101
AMGX
See also https://github.com/NVIDIA/AMGX#-building
- From empty AMGX build dir (for example AMGX/build):
- in powershell
& "C:\Program Files\CMake\bin\cmake.exe" -G "Visual Studio 15 2017 Win64" ..
- in cmd
"C:\Program Files\CMake\bin\cmake.exe" -G "Visual Studio 15 2017 Win64" ..
- Open build/AMG.sln in VS 2017
- Switch build configuration from Debug to Release (https://github.com/NVIDIA/AMGX/issues/43)
- Build amgx.sh project, it is enough to install pyamgx.
pyamgx
See also https://pyamgx.readthedocs.io/en/latest/install.html
- in setup.py comment out lines 42-44 (
runtime_library_dirs = ...
): https://github.com/shwina/pyamgx/issues/16 - in setup.py add in setup arguments (line 54)
data_files=[('lib\\site-packages\\', [AMGX_BUILD_DIR + "\\amgxsh.dll"])]
- in cmd
- don't forget to activate your ef_python venv
SET AMGX_DIR="your AMGX source dir"
SET AMGX_BUILD_DIR="your AMGX build dir\Release"
- pip install "your pyamgx dir"