Error in using lammps kokkos package for reax/c on gpu

Aman,

Your “-pk kokkos device 1” command isn’t quite right and that is why you are getting the original error. Please see the docs here http://lammps.sandia.gov/doc/package.html. I would recommend using an unmodified input script (no /kk commands in the input script) along with:

lmp_kokkos_cuda_mpich -pk kokkos newton on neigh half comm no -k on g 1 -sf kk < in.CHO

Often the half neighbor list is better than the default full even on the GPU. There is also a new “-pk kokkos neigh/qeq” option that you can try out as well, sometimes it is better to use a full neighbor list with fix qeq/reax/kk and a half neighbor list for pair reax/c/kk. You will need to update your version of LAMMPS though.

Stan

Thanks for your suggestions,

I installed the latest LAMMPS (10th March, 2017) version and tried the same input script given in the example without any modification. I used the command suggested by Stan but I got the same error:

Neighbor list info ...
   update every 10 steps, delay 0 steps, check no
   max neighbors/atom: 2000, page size: 100000
   master list distance cutoff = 12
   ghost atom cutoff = 12
   binsize = 6, bins = 5 5 5
   2 neighbor lists, perpetual/occasional/extra = 2 0 0
   (1) pair reax/c/kk, perpetual
       attributes: half, newton off, ghost, kokkos_device
       pair build: half/bin/ghost/kk/device
       stencil: half/ghost/bin/3d/newtoff
       bin: kk/device
   (2) fix qeq/reax, perpetual, copy from (1)
       attributes: half, newton off, ghost, kokkos_device
       pair build: copy/kk/device
       stencil: none
       bin: none
Setting up Verlet run ...
   Unit style : real
   Current step : 0
   Time step : 0.25
terminate called after throwing an instance of 'std::runtime_error'
   what(): cudaMalloc( &ptr, arg_alloc_size ) error( cudaErrorMemoryAllocation): out of memory ../../lib/kokkos/core/src/Cuda/Kokkos_CudaSpace.cpp:176
Traceback functionality not available

Aborted (core dumped)

Please give some advice.

Thanks,

Aman