Simulation with openKIM takes to much time

Hello

I am conducting a simulation with 4000 particles using the SNAP Ni Potential to calculate the enthalpy and density of the system. The system is being heated from 300K to 2700K, and I am studying the phase changes. The first time I ran the simulation, I used the Ni_Zuo_JPCA2020 with Kokkos and it took about 10 hours to finish. However, when I ran the simulation using OpenKIM with the same potential, it has been running for more than 3 days and is less than halfway done. How can I speed up the simulation?

This is the Script

variable nrep equal 10
variable a equal 3.527

kim init SNAP_ZuoChenLi_2019_Ni__MO_365106510449_000 metal

variable nx equal ${nrep}

variable ny equal ${nrep}

variable nz equal ${nrep}

boundary p p p

lattice fcc $a

region box block 0 ${nx} 0 ${ny} 0 ${nz}
create_box 1 box
create_atoms 1 box

mass 1 58.69

kim interactions Ni

thermo 100
thermo_style custom step density temp press enthalpy

timestep 1.0e-3
neighbor 1.0 bin
neigh_modify once no every 1 delay 0 check yes

velocity all create 300.0 1523945 dist gaussian

variable i loop 50
label loopa
variable tx equal 300+50*($i-1)

log heating_ni_t${tx}.out

fix 1 all npt temp ${tx} ${tx} 0.01 iso 0.0 0.0 0.1

run 40000

unfix 1

next i

jump in.heating loopa

variable i loop 50

label loopb

variable tx equal ${tx}-50

log cooling_ni_t${tx}.out

fix 1 all npt temp ${tx} ${tx} 0.01 iso 0.0 0.0 0.1

run 40000

unfix 1

next i

jump in.heating loopb

The command i use to run the simulation is

nohup nice mpirun -n 1 lmp -k on g 1 -sf kk -pk kokkos cuda/aware on neigh half newton on -in in.heating >./out.heating &

Thank you and greetings!

@juanorregom I have recategorized your post. This is really a question for the OpenKIM folks.

thank you, greetings

Hi Juan,

The OpenKIM SNAP model driver is CPU-only, that’s why running with Kokkos on GPU is so much faster. I would guess if you ran the non-OpenKIM SNAP on CPU only, you would get similar results.

Cheers, illia

oh, i see… well, i will go back to non-OpenKIM SNAP.
is it possible to run a simulation with non-OpenKIM SNAP in lammps with the OpenKIM database installed?

Greetings

I’m not sure what you mean. The OpenKIM API and models being installed does not interfere with how LAMMPS normally operates. If you wish to use Kokkos, you need to write your script without KIM commands like you did previously (unless you are using Sim_LAMMPS_SNAP_ChenDengTran_2017_Mo__SM_003882782678_000 – this is a Simulator Model and can be used with Kokkos, but it’s the only SNAP in OpenKIM that this is true for).

If you wish to use parameters from OpenKIM models, you can download them independently of the KIM API by downloading them from the website (e.g. https://openkim.org/id/SNAP_LiHuChen_2018_Ni__MO_913991514986_000#files) Note that if you are using a modern LAMMPS version, you will need to delete the “diagonalstyle 3” line from the *.snapparam file if such a line exists.