Merge remote-tracking branch 'github/develop' into collected-small-fixes

This commit is contained in:
Axel Kohlmeyer
2025-04-07 14:05:27 -04:00
2 changed files with 6 additions and 2 deletions

View File

@ -35,6 +35,8 @@ template <class DeviceType> class MLIAPModelKokkos : protected Pointers {
void set_k_coeffelem() void set_k_coeffelem()
{ {
if ( model->coeffelem == nullptr )
return;
double **tmp = nullptr; double **tmp = nullptr;
memoryKK->create_kokkos(k_coeffelem, tmp, model->nelements, model->nparams, memoryKK->create_kokkos(k_coeffelem, tmp, model->nelements, model->nparams,
"MLIAPModelKokkos::coeffelem"); "MLIAPModelKokkos::coeffelem");

View File

@ -76,9 +76,11 @@ MLIAPModelPythonKokkos<DeviceType>::MLIAPModelPythonKokkos(LAMMPS *lmp, char *co
PyList_Append(py_path, PyUnicode_FromString(potentials_path)); PyList_Append(py_path, PyUnicode_FromString(potentials_path));
} }
PyGILState_Release(gstate); PyGILState_Release(gstate);
if (coefffilename) read_coeffs(coefffilename); if (coefffilename) {
read_coeffs(coefffilename);
MLIAPModelKokkos<DeviceType>::set_k_coeffelem();
}
if (coefffilename) MLIAPModelKokkos<DeviceType>::set_k_coeffelem();
nonlinearflag = 1; nonlinearflag = 1;
} }