2.2.2. Compiling Amber#
Amber + QMhub + Torchmd-net
Compile Amber for QM/MM simulations with QMhub and Torchmd-net.
Using Amber22 and AmberTools23 on Pete.
Includes
sander.MPI
SINR thermostat
adaptive string method
2.2.2.1. Create Conda Environment#
Create a
torchmd-netconda environment, and load modules.
conda create -f torchmd-net.yml
conda activate torchmd-net
module load intel/2021.2.0
module load impi/2021.2.0
export MKLROOT=/opt/intel/oneapi/mkl/2021.2.0
export LD_PRELOAD=$MKLROOT/lib/intel64/libmkl_core.so:$MKLROOT/lib/intel64/libmkl_sequential.so
Clone repository to
Programs/and change branch to torchnet-ext
git clone
cd torchmd-net
pip install .
git clone
git clone
cd qmhub
pip install .
cd ../helpme
CXX=icpc PKG_CONFIG_PATH=~/miniforge3/lib/pkgconfig cmake .. -DFFTW_INCLUDES=$MKLROOT/include/fftw -DFFTW_LIBRARIES=$MKLROOT/lib/intel64
make helpmelib
Copy the
python/helpme***file tominforge3/envs/torchmd-net/lib/python3.10/site-packages/qmhub/
2.2.2.2. Amber#
In
Programs/sources, decompress AmberTools then Amber
tar xvjf AmberTools
tar xvjf Amber
Apply patches in
amber22_src/, qmhub, sinr, sqm, and then asm.
patch -p 1 < patch_file
Go to the
build/directory
cd build/
Change the
run_cmakeand run it./run_cmake:
cmake $AMBER_PREFIX/amber22_src \
-DCMAKE_INSTALL_PREFIX=/scratch/van/.Programs/amber22 \
-DCOMPILER=INTEL \
-DMPI=FALSE -DCUDA=FALSE -DINSTALL_TESTS=FALSE \
-DFORCE_EXTERNAL_LIB=mkl \
-DDOWNLOAD_MINICONDA=FALSE -DBUILD_PYTHON=FALSE \
2>&1 | tee cmake.log
Check if everything is properly linked.
Before we run
make install -j 8, we’ll build sander first, and test it.
make sander -j 8
Test sander using the source in the AmberTools directory.
If the test went well, go back to the build/ and compile the MPI version.
make sander.MPI -j 8