-
Notifications
You must be signed in to change notification settings - Fork 46
Build q‐e‐sirius on Daint.Alps
We mostly follow the CSCS guideline for building Quantum ESPRESSO.
- Create and jump into working directory:
mkdir qe-sirius-project && cd qe-sirius-project- Clone source codes:
git clone [email protected]:electronic-structure/SIRIUS.git
git clone [email protected]:electronic-structure/q-e-sirius.git- Clone spack-1.0.2:
git clone --branch v1.0.2 https://github.com/spack/spack.gitThis is a recommended version because UENV for q-e-sirius (after rebase on qe7.5) is also based on this version.
It is also recommended to keep separate versions of Spack for separate development projects to avoid any dependency conflicts. Also, don't forget to remove ~/.spack/ global config folder because it might conflict with the local environment setup.
- Pull the UENV image on Daint.Alps login nodes (this is done only once):
uenv image pull prgenv-gnu/25.6:v2- Start the UENV and point Spack to use it as an upstream:
uenv start prgenv-gnu/25.6:v2
source ~/qe-sirius-project/spack/share/spack/setup-env.sh
export SPACK_USER_CONFIG_PATH=/user-environment/config- (Optionally) check that spack is enabled:
spack find
# this should list you the available packages found in the upstream
spack compiler list
# this should give available compiler:
# -- gcc sles15-aarch64 -------------------------------------------
# [e] [email protected] [^] [email protected]- Create spack environment file
spack.yamlthat describes the specifics of how to buildqe/sirius(substitute USERNAME with your daint username):
# This is a Spack Environment file.
#
# It describes a set of packages to be installed, along with
# configuration settings.
spack:
# add package specs to the `specs` list
specs:
- sirius@develop build_type=Release +apps+cuda+fortran+pugixml+tests %gcc ^openblas
threads=openmp ^cray-mpich ^libxc@7
- q-e-sirius@develop-ristretto build_type=Release ~scalapack +libxc hdf5=serial %gcc ^openblas
threads=openmp ^cray-mpich
view: true
concretizer:
unify: true
reuse: true
packages:
perl:
externals:
- spec: [email protected]~cpanm+opcode+open+shared+threads
prefix: /usr
git:
externals:
- spec: [email protected]~tcltk
prefix: /usr
all:
variants: cuda_arch=90
develop:
q-e-sirius:
spec: q-e-sirius@develop-ristretto
path: /users/USERNAME/qe-sirius-project/q-e-sirius
sirius:
spec: sirius@develop
path: /users/USERNAME/qe-sirius-project/SIRIUS- Concretize the environment. This is done whenever
spack.yamlchanges:
spack -e . concretize -f* Build the source codes. This is done whenever sources are modified:
spack -e . installThe full installation tree will be located at ./.spack-env/view and the binaries at ./.spack-env/view/bin. Be aware that binaries linked to UENV must have it enabled before they can be run. The robust way to avoid forgetting this is to add --uenv=prgenv-gnu/25.6:v2 to the srun command: srun --uenv=prgenv-gnu/25.6:v2 ...
Older version of qe-sirius (before rebase on qe7.5)
If you want to install a version of q-e-sirius prior to the rebase on qe7.5, follow the previous instructions with the following changes.
- Clone spack-0.23 using:
git clone --branch releases/v0.23 --depth 1 https://github.com/spack/spack.gitThis is the recommended version because UENV for q-e-sirius (before rebase on qe7.5) is also based on v0.23.
-
Use q-e-sirius/v1.0.1:v2 as your UENV.
-
The spack.yaml` to create the spack environment file will be:
# This is a Spack Environment file.
#
# It describes a set of packages to be installed, along with
# configuration settings.
spack:
# add package specs to the `specs` list
specs:
- sirius@develop build_type=Release +apps+cuda+fortran+pugixml+tests %gcc ^openblas
threads=openmp ^cray-mpich ^[email protected]
- q-e-sirius@develop-ristretto build_type=Release ~scalapack +libxc hdf5=serial %gcc ^openblas
threads=openmp ^cray-mpich
view: true
concretizer:
unify: true
reuse: true
packages:
all:
variants: cuda_arch=90
develop:
q-e-sirius:
spec: q-e-sirius@develop-ristretto
path: /users/USERNAME/qe-sirius-project/q-e-sirius
sirius:
spec: sirius@develop
path: /users/USERNAME/qe-sirius-project/SIRIUSTo enable the binaries linked to this UENV add --uenv=q-e-sirius/v1.0.1:v2 to the srun command: srun --uenv=q-e-sirius/v1.0.1:v2 ...