Gromacs on Theta
What is Gromacs?
GROMACS is a versatile package to perform molecular dynamics, i.e. simulate the Newtonian equations of motion for systems with hundreds to millions of particles. It is primarily designed for biochemical molecules like proteins, lipids, and nucleic acids that have a lot of complicated bonded interactions, but since GROMACS is extremely fast at calculating the nonbonded interactions (that usually dominate simulations) many groups are also using it for research on non-biological systems, e.g. polymers.
Using GROMACS at ALCF
ALCF offers assistance with building binaries and compiling instructions for GROMACS. For questions, contact us at firstname.lastname@example.org.
- Download latest source code: http://manual.gromacs.org/documentation/2022.1/download.html
- tar -xzf gromacs-2022.1.tar.gz
- cd gromacs-2022.1
- mkdir build
- module load cmake
- module swap PrgEnv-intel PrgEnv-gnu/6.0.10
cmake -DCMAKE_C_COMPILER=cc -DCMAKE_CXX_COMPILER=CC \ -DBUILD_SHARED_LIBS=OFF -DGMX_BUILD_OWN_FFTW=ON \ -DCMAKE_INSTALL_PREFIX=/path-to/gromacs-2022.1/build \ -DGMX_MPI=ON -DGMX_OPENMP=ON -DGMX_CYCLE_SUBCOUNTERS=ON -DGMX_GPU=OFF \ -DGMX_BUILD_HELP=OFF -DGMX_HWLOC=OFF -DGMX_SIMD=AVX_512_KNL \ -DGMX_OPENMP_MAX_THREADS=256
- make –j 16
- make install
- The installed binary is
Running Gromacs on Theta
Prebuilt Gromacs binaries can be found in the directory
A sample qsub script follows.
#!/bin/bash #COBALT -n 1 #COBALT -t 30 #COBALT -q debug-cache-quad #COBALT -project catalyst #COBALT --attrs mcdram=cache:numa=quad #COBALT --attrs filesystems=home,theta-fs0 export GMX_MAXBACKUP=-1 aprun -n64 -N64 --env OMP_NUM_THREADS=2 --cc depth -d 2 -j 2 \ /soft/applications/gromacs/gromacs_theta/gmx_mpi.2022.1 mdrun \ -dlb yes -resethway -pin on -v deffnm step5_1 -g test.log
We strongly suggest that users try combinations of different numbers of nodes, MPI ranks per node, and OMP threads per rank to find the optimal throughput for their particular workload.
The following is a representative benchmark for a system with 30,000 atoms generated on a single Theta node with above aprun command.
|Core time(sec)||Wall time(sec)||(%)|