Sign inSign up

mariojmdavid/gromacs-cuda

By mariojmdavid

Updated about 7 years ago

Gromacs compiled with CUDA

Image
1

1.5K

mariojmdavid/gromacs-cuda repository overview

Information

The Dockerfile is available in github repository https://github.com/mariojmdavid/docker-gromacs-cuda

Tags:

  • 2018.3-devel - full source plus compiled
  • 2018.3-runtime - pre-compiled gromacs
  • 2018.5-cpu - Gromacs compiled for CPU only

Running the GPU version with udocker and nvidia-docker

If you have a tpr (molecule) input file in a directory, for example:

gromacs/md.tpr

After installing nvidia-docker

docker pull mariojmdavid/gromacs-cuda:2019.3-runtime
nvidia-docker run --rm -v $HOME/gromacs:/home mariojmdavid/gromacs-cuda:2019.3-runtime gmx mdrun -s md.tpr

With udocker (https://github.com/indigo-dc/udocker), these steps include installation:

mkdir -p bin
cd bin
curl https://raw.githubusercontent.com/indigo-dc/udocker/devel/udocker.py > udocker
chmod u+rx ./udocker
cd
udocker create --name=gromacs mariojmdavid/gromacs-cuda:2019.3-runtime
udocker setup --nvidia gromacs
udocker run -v $HOME/grm:/home gromacs gmx mdrun -s md.tpr

Use case

If you have a tpr (molecule) input file in a directory, for example:

gromacs/md.tpr

You can run the following way:

docker run -v $HOME/gromacs:/home mariojmdavid/gromacs-cuda:2018.5-cpu gmx mdrun -s md.tpr

The output files are in this case:

  • ener.edr
  • md.log
  • state.cpt
  • traj_comp.xtc
  • traj.trr

Runtime statistics can be obtained with:

tail -34 gromacs/md.log 
-----------------------------------------------------------------------------

     R E A L   C Y C L E   A N D   T I M E   A C C O U N T I N G

On 1 MPI rank, each using 12 OpenMP threads

 Computing:          Num   Num      Call    Wall time         Giga-Cycles
                     Ranks Threads  Count      (s)         total sum    %
-----------------------------------------------------------------------------
 Neighbor search        1   12        426       3.084        125.807   2.2
 Force                  1   12      21251      94.820       3868.650  68.8
 PME mesh               1   12      21251      29.632       1208.992  21.5
 NB X/F buffer ops.     1   12      42076       5.423        221.250   3.9
 Write traj.            1   12          6       0.063          2.572   0.0
 Update                 1   12      21251       1.582         64.547   1.1
 Constraints            1   12      21251       2.450         99.968   1.8
 Rest                                           0.670         27.317   0.5
-----------------------------------------------------------------------------
 Total                                        137.724       5619.103 100.0
-----------------------------------------------------------------------------
 Breakdown of PME mesh computation
-----------------------------------------------------------------------------
 PME spread             1   12      21251      11.269        459.774   8.2
 PME gather             1   12      21251       6.774        276.393   4.9
 PME 3D-FFT             1   12      42502      10.162        414.622   7.4
 PME solve Elec         1   12      21251       1.221         49.831   0.9
-----------------------------------------------------------------------------

               Core t (s)   Wall t (s)        (%)
       Time:     1652.682      137.724     1200.0
                 (ns/day)    (hour/ns)
Performance:       26.663        0.900

Doing a restart/checkpointing

If you want/need to restart the calculation, that has broken/crashed, simply run:

docker run -v $HOME/gromacs:/home mariojmdavid/gromacs-cuda:2018.5-cpu gmx mdrun -s md.tpr -cpi state.cpt -append

Tag summary

Content type

Image

Digest

Size

765.3 MB

Last updated

about 7 years ago

docker pull mariojmdavid/gromacs-cuda:2019.3-runtime