Quantum ESPRESSO¶
https://www.quantum-espresso.org
An environment that provides the latest version of Quantum ESPRESSO, along with the libraries and tools required to build a different or custom version of Quantum ESPRESSO. At the moment a GPU-build environment is provided without a ScaLAPACK.
The following environment views are provided:
- default : QuantumESPRESSO/7.3.1 itself + dependencies
- develop : only dependencies
The following modules are provided:
- cmake/3.27.7
- nvhpc/24.1
- quantum-espresso/7.3.1
- cray-mpich/8.1.29
- fftw/3.3.10
- git/2.42.0
- nvpl-lapack/0.2.0
- gcc/12.3.0
- libxc/6.2.2
- nvpl-blas/0.1.0
- default : QuantumESPRESSO/7.1 itself + dependencies
- develop : only dependencies
The following modules are provided:
- cmake/3.26.3
- cray-mpich/8.1.25-nvhpc
- cuda/11.8.0
- fftw/3.3.10
- gcc/11.3.0
- libxc/5.2.3
- nvhpc/22.11
- openblas/0.3.23
- patchelf/0.17.2
- quantum-espresso/7.1
Building a custom version¶
Using modules¶
uenv start quantumespresso/v7.3.1
uenv modules use
module load cmake \
fftw \
nvhpc \
nvpl-lapack \
nvpl-blas \
cray-mpich \
netlib-scalapack \
libxc
mkdir build && cd build
FC=mpif90 CXX=mpic++ CC=mpicc cmake .. \
-DQE_ENABLE_MPI=ON \
-DQE_ENABLE_OPENMP=ON \
-DQE_ENABLE_SCALAPACK:BOOL=OFF \
-DQE_ENABLE_LIBXC=ON \
-DQE_ENABLE_CUDA=ON \
-DQE_ENABLE_PROFILE_NVTX=ON \
-DQE_CLOCK_SECONDS:BOOL=OFF \
-DQE_ENABLE_MPI_GPU_AWARE:BOOL=OFF \
-DQE_ENABLE_OPENACC=ON
make -j20
uenv start quantumespresso/v7.1
uenv modules use
module load cmake \
cray-mpich
cuda \
fftw \
gcc \
libxc \
nvhpc \
openblas
mkdir build && cd build
FC=mpif90 CXX=mpic++ CC=mpicc cmake .. \
-DQE_ENABLE_MPI=ON \
-DQE_ENABLE_OPENMP=ON \
-DQE_ENABLE_SCALAPACK:BOOL=OFF \
-DQE_ENABLE_LIBXC=ON \
-DQE_ENABLE_CUDA=ON \
-DQE_CLOCK_SECONDS:BOOL=OFF \
-DQE_ENABLE_MPI_GPU_AWARE:BOOL=OFF \
-DQE_ENABLE_OPENACC=ON
make -j20
Using spack¶
-
Clone spack using the same version that has been used to build the uenv.
-
Activate spack with the uenv configured as upstream
-
Create an anonymous environment for QE
Check the output ofspack env create -d $SCRATCH/qe-env spack -e $SCRATCH/qe-env add quantum-espresso%nvhpc +cuda spack -e $SCRATCH/qe-env config add packages:all:prefer:cuda_arch=90 spack -e $SCRATCH/qe-env develop -p /path/to/your/QE-src quantum-espresso@=develop spack -e $SCRATCH/qe-env concretize -f
spack concretize -f
. All dependencies should have been picked up from spack upstream, marked eiter by a green[^]
or[e]
. Next we create a local filesystem view, this instructs spack to create symlinks for binaries and libraries in a local directoryview
. To recompile QE after editing the source code re-runspack -e $SCRATCH/qe-env install
. -
Run
pw.x
using the filesystem view generated in 3.Note: Theuenv start quantumespresso/v7.3.1 MPICH_GPU_SUPPORT_ENABLED=1 srun [...] $SCRATCH/qe-env/view/bin/pw.x < pw.in
pw.x
is linked to the uenv, it won't work without activating the uenv, also it will only work with the exact same version of the uenv. The physical installation path is in$SCRATCH/spack
, deleting this directory will leave the anonymous spack environment created in 3. with dangling symlinks.