I use GROMACS 2023.3 with CUDA 12.3 on my Ubuntu 22.04 computer with a single RTX 4090.
For my desired 1us-long membrane simulation, I chunk it up into ten separate 100ns-long simulations.
For each of the ten 100ns-long simulations, I run the following terminal command:
gmx mdrun -v -deffnm ${istep} -nb gpu -bonded gpu -pme gpu -update gpu
The GROMACS .mdp is as follows:
integrator = md
dt = 0.004
nsteps = 25000000
nstxout-compressed = 25000
nstxout = 0
nstvout = 0
nstfout = 0
nstcalcenergy = 100
nstenergy = 5000
nstlog = 5000
;
cutoff-scheme = Verlet
nstlist = 20
rlist = 1.2
vdwtype = Cut-off
vdw-modifier = Force-switch
rvdw_switch = 1.0
rvdw = 1.2
coulombtype = PME
rcoulomb = 1.2
;
tcoupl = v-rescale
tc_grps = MEMB SOLV
tau_t = 1.0 1.0
ref_t = 303.15 303.15
;
pcoupl = C-rescale
pcoupltype = semiisotropic
tau_p = 5.0
compressibility = 4.5e-5 4.5e-5
ref_p = 1.0 1.0
;
constraints = h-bonds
constraint_algorithm = LINCS
continuation = yes
;
nstcomm = 100
comm_mode = linear
comm_grps = MEMB SOLV
As can be seen in the below plot, when I simulate a 100-total-molecule membrane system (orange line below), the simulation time for each progressive 100ns run steadily increases, going from 100 minutes to over 250 minutes.
I tried halving the size of my membrane system to 50-total-molecules (blue line below). This seemed to largely mitigate the issue of increasing run times as the GPU is used over time.
Why is it that the simulations incrementally slow over time for my larger membrane system? As recommended by this NVIDIA blog by Alan Gray, I played around with the nstlist
parameter and found no difference; the issue persisted.
From the GROMACS side, do you have any recommendations for other .mdp parameters to try?
Alternatively or in combination, is there anything I could do in between each of the ten 100-ns-long runs, like a “cool-down” period for the GPU (i.e., do nothing for a few minutes)? Or perhaps clear GPU cache?
Thanks in advance!
Best,
Evan