diff --git a/source/api_c/include/c_api.h b/source/api_c/include/c_api.h index e3ba57370e..b214d3c7a9 100644 --- a/source/api_c/include/c_api.h +++ b/source/api_c/include/c_api.h @@ -96,6 +96,7 @@ const char* DP_NlistCheckOK(DP_Nlist* dp); /** * @brief The deep potential base model. + * @since API version 24 **/ typedef struct DP_DeepBaseModel DP_DeepBaseModel; @@ -109,6 +110,7 @@ extern void DP_DeleteDeepBaseModel(DP_DeepBaseModel* dp); /** * @brief The deep potential base model deviation. + * @since API version 24 **/ typedef struct DP_DeepBaseModelDevi DP_DeepBaseModelDevi; @@ -561,8 +563,8 @@ extern void DP_DeepPotComputeNList2(DP_DeepPot* dp, double* atomic_virial); /** - * @brief Evaluate the energy, force and virial by using a DP spin model - * with the neighbor list. (double version) + * @brief Evaluate the energy, force, magnetic force and virial by using a DP + *spin model with the neighbor list. (double version) * @version 2 * @param[in] dp The DP spin model to use. * @param[in] nframes The number of frames. @@ -660,8 +662,8 @@ extern void DP_DeepPotComputeNListf2(DP_DeepPot* dp, float* atomic_virial); /** - * @brief Evaluate the energy, force and virial by using a DP spin model - * with the neighbor list. (float version) + * @brief Evaluate the energy, force, magnetic force and virial by using a DP + *spin model with the neighbor list. (float version) * @version 2 * @param[in] dp The DP spin model to use. * @param[in] nframes The number of frames. @@ -1138,8 +1140,8 @@ void DP_DeepPotModelDeviComputeNList2(DP_DeepPotModelDevi* dp, double* atomic_virial); /** - * @brief Evaluate the energy, force and virial by using a DP spin model - *deviation with neighbor list. (double version) + * @brief Evaluate the energy, force, magnetic force and virial by using a DP + *spin model deviation with neighbor list. (double version) * @version 2 * @param[in] dp The DP model deviation to use. * @param[in] nframes The number of frames. Only support 1 for now. @@ -1236,8 +1238,8 @@ void DP_DeepPotModelDeviComputeNListf2(DP_DeepPotModelDevi* dp, float* atomic_virial); /** - * @brief Evaluate the energy, force and virial by using a DP spin model - *deviation with neighbor list. (float version) + * @brief Evaluate the energy, force, magnetic force and virial by using a DP + *spin model deviation with neighbor list. (float version) * @version 2 * @param[in] dp The DP model deviation to use. * @param[in] nframes The number of frames. Only support 1 for now. diff --git a/source/api_c/include/deepmd.hpp b/source/api_c/include/deepmd.hpp index 6d54cbdfa2..ee22cf7ce7 100644 --- a/source/api_c/include/deepmd.hpp +++ b/source/api_c/include/deepmd.hpp @@ -97,59 +97,59 @@ inline void _DP_DeepPotCompute(DP_DeepPot *dp, // support spin template -inline void _DP_DeepPotComputeSP(DP_DeepSpin *dp, - const int nframes, - const int natom, - const FPTYPE *coord, - const FPTYPE *spin, - const int *atype, - const FPTYPE *cell, - const FPTYPE *fparam, - const FPTYPE *aparam, - double *energy, - FPTYPE *force, - FPTYPE *force_mag, - FPTYPE *virial, - FPTYPE *atomic_energy, - FPTYPE *atomic_virial); +inline void _DP_DeepSpinCompute(DP_DeepSpin *dp, + const int nframes, + const int natom, + const FPTYPE *coord, + const FPTYPE *spin, + const int *atype, + const FPTYPE *cell, + const FPTYPE *fparam, + const FPTYPE *aparam, + double *energy, + FPTYPE *force, + FPTYPE *force_mag, + FPTYPE *virial, + FPTYPE *atomic_energy, + FPTYPE *atomic_virial); template <> -inline void _DP_DeepPotComputeSP(DP_DeepSpin *dp, - const int nframes, - const int natom, - const double *coord, - const double *spin, - const int *atype, - const double *cell, - const double *fparam, - const double *aparam, - double *energy, - double *force, - double *force_mag, - double *virial, - double *atomic_energy, - double *atomic_virial) { +inline void _DP_DeepSpinCompute(DP_DeepSpin *dp, + const int nframes, + const int natom, + const double *coord, + const double *spin, + const int *atype, + const double *cell, + const double *fparam, + const double *aparam, + double *energy, + double *force, + double *force_mag, + double *virial, + double *atomic_energy, + double *atomic_virial) { DP_DeepSpinCompute2(dp, nframes, natom, coord, spin, atype, cell, fparam, aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); } template <> -inline void _DP_DeepPotComputeSP(DP_DeepSpin *dp, - const int nframes, - const int natom, - const float *coord, - const float *spin, - const int *atype, - const float *cell, - const float *fparam, - const float *aparam, - double *energy, - float *force, - float *force_mag, - float *virial, - float *atomic_energy, - float *atomic_virial) { +inline void _DP_DeepSpinCompute(DP_DeepSpin *dp, + const int nframes, + const int natom, + const float *coord, + const float *spin, + const int *atype, + const float *cell, + const float *fparam, + const float *aparam, + double *energy, + float *force, + float *force_mag, + float *virial, + float *atomic_energy, + float *atomic_virial) { DP_DeepSpinComputef2(dp, nframes, natom, coord, spin, atype, cell, fparam, aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); @@ -219,68 +219,68 @@ inline void _DP_DeepPotComputeNList(DP_DeepPot *dp, // support spin template -inline void _DP_DeepPotComputeNListSP(DP_DeepSpin *dp, - const int nframes, - const int natom, - const FPTYPE *coord, - const FPTYPE *spin, - const int *atype, - const FPTYPE *cell, - const int nghost, - const DP_Nlist *nlist, - const int ago, - const FPTYPE *fparam, - const FPTYPE *aparam, - double *energy, - FPTYPE *force, - FPTYPE *force_mag, - FPTYPE *virial, - FPTYPE *atomic_energy, - FPTYPE *atomic_virial); +inline void _DP_DeepSpinComputeNList(DP_DeepSpin *dp, + const int nframes, + const int natom, + const FPTYPE *coord, + const FPTYPE *spin, + const int *atype, + const FPTYPE *cell, + const int nghost, + const DP_Nlist *nlist, + const int ago, + const FPTYPE *fparam, + const FPTYPE *aparam, + double *energy, + FPTYPE *force, + FPTYPE *force_mag, + FPTYPE *virial, + FPTYPE *atomic_energy, + FPTYPE *atomic_virial); template <> -inline void _DP_DeepPotComputeNListSP(DP_DeepSpin *dp, - const int nframes, - const int natom, - const double *coord, - const double *spin, - const int *atype, - const double *cell, - const int nghost, - const DP_Nlist *nlist, - const int ago, - const double *fparam, - const double *aparam, - double *energy, - double *force, - double *force_mag, - double *virial, - double *atomic_energy, - double *atomic_virial) { - DP_DeepSpinComputeNList2(dp, nframes, natom, coord, spin, atype, cell, nghost, - nlist, ago, fparam, aparam, energy, force, force_mag, - virial, atomic_energy, atomic_virial); -} - -template <> -inline void _DP_DeepPotComputeNListSP(DP_DeepSpin *dp, +inline void _DP_DeepSpinComputeNList(DP_DeepSpin *dp, const int nframes, const int natom, - const float *coord, - const float *spin, + const double *coord, + const double *spin, const int *atype, - const float *cell, + const double *cell, const int nghost, const DP_Nlist *nlist, const int ago, - const float *fparam, - const float *aparam, + const double *fparam, + const double *aparam, double *energy, - float *force, - float *force_mag, - float *virial, - float *atomic_energy, - float *atomic_virial) { + double *force, + double *force_mag, + double *virial, + double *atomic_energy, + double *atomic_virial) { + DP_DeepSpinComputeNList2(dp, nframes, natom, coord, spin, atype, cell, nghost, + nlist, ago, fparam, aparam, energy, force, force_mag, + virial, atomic_energy, atomic_virial); +} + +template <> +inline void _DP_DeepSpinComputeNList(DP_DeepSpin *dp, + const int nframes, + const int natom, + const float *coord, + const float *spin, + const int *atype, + const float *cell, + const int nghost, + const DP_Nlist *nlist, + const int ago, + const float *fparam, + const float *aparam, + double *energy, + float *force, + float *force_mag, + float *virial, + float *atomic_energy, + float *atomic_virial) { DP_DeepSpinComputeNListf2(dp, nframes, natom, coord, spin, atype, cell, nghost, nlist, ago, fparam, aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); @@ -449,63 +449,63 @@ inline void _DP_DeepPotModelDeviComputeNList(DP_DeepPotModelDevi *dp, } template -inline void _DP_DeepPotModelDeviComputeNListSP(DP_DeepSpinModelDevi *dp, - const int natom, - const FPTYPE *coord, - const FPTYPE *spin, - const int *atype, - const FPTYPE *cell, - const int nghost, - const DP_Nlist *nlist, - const int ago, - const FPTYPE *fparam, - const FPTYPE *aparam, - double *energy, - FPTYPE *force, - FPTYPE *force_mag, - FPTYPE *virial, - FPTYPE *atomic_energy, - FPTYPE *atomic_virial); -template <> -inline void _DP_DeepPotModelDeviComputeNListSP(DP_DeepSpinModelDevi *dp, - const int natom, - const double *coord, - const double *spin, - const int *atype, - const double *cell, - const int nghost, - const DP_Nlist *nlist, - const int ago, - const double *fparam, - const double *aparam, - double *energy, - double *force, - double *force_mag, - double *virial, - double *atomic_energy, - double *atomic_virial) { - DP_DeepSpinModelDeviComputeNList2( - dp, 1, natom, coord, spin, atype, cell, nghost, nlist, ago, fparam, - aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); -} +inline void _DP_DeepSpinModelDeviComputeNList(DP_DeepSpinModelDevi *dp, + const int natom, + const FPTYPE *coord, + const FPTYPE *spin, + const int *atype, + const FPTYPE *cell, + const int nghost, + const DP_Nlist *nlist, + const int ago, + const FPTYPE *fparam, + const FPTYPE *aparam, + double *energy, + FPTYPE *force, + FPTYPE *force_mag, + FPTYPE *virial, + FPTYPE *atomic_energy, + FPTYPE *atomic_virial); template <> -inline void _DP_DeepPotModelDeviComputeNListSP(DP_DeepSpinModelDevi *dp, +inline void _DP_DeepSpinModelDeviComputeNList(DP_DeepSpinModelDevi *dp, const int natom, - const float *coord, - const float *spin, + const double *coord, + const double *spin, const int *atype, - const float *cell, + const double *cell, const int nghost, const DP_Nlist *nlist, const int ago, - const float *fparam, - const float *aparam, + const double *fparam, + const double *aparam, double *energy, - float *force, - float *force_mag, - float *virial, - float *atomic_energy, - float *atomic_virial) { + double *force, + double *force_mag, + double *virial, + double *atomic_energy, + double *atomic_virial) { + DP_DeepSpinModelDeviComputeNList2( + dp, 1, natom, coord, spin, atype, cell, nghost, nlist, ago, fparam, + aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); +} +template <> +inline void _DP_DeepSpinModelDeviComputeNList(DP_DeepSpinModelDevi *dp, + const int natom, + const float *coord, + const float *spin, + const int *atype, + const float *cell, + const int nghost, + const DP_Nlist *nlist, + const int ago, + const float *fparam, + const float *aparam, + double *energy, + float *force, + float *force_mag, + float *virial, + float *atomic_energy, + float *atomic_virial) { DP_DeepSpinModelDeviComputeNListf2( dp, 1, natom, coord, spin, atype, cell, nghost, nlist, ago, fparam, aparam, energy, force, force_mag, virial, atomic_energy, atomic_virial); @@ -1123,33 +1123,6 @@ class DeepPot : public DeepBaseModel { DP_CHECK_OK(DP_DeepBaseModelCheckOK, (DP_DeepBaseModel *)dp); }; - /** - * @brief Evaluate the energy, force, magnetic force, virial, atomic energy, - *and atomic virial by using this DP with spin input. - * @param[out] ener The system energy. - * @param[out] force The force on each atom. - * @param[out] force_mag The magnetic force on each atom. - * @param[out] virial The virial. - * @param[out] atom_energy The atomic energy. - * @param[out] atom_virial The atomic virial. - * @param[in] coord The coordinates of atoms. The array should be of size - *nframes x natoms x 3. - * @param[in] spin The spins of atoms, [0, 0, 0] if no spin. The array should - *be of size nframes x natoms x 3. - * @param[in] atype The atom types. The list should contain natoms ints. - * @param[in] box The cell of the region. The array should be of size nframes - *x 9 (PBC) or empty (no PBC). - * @param[in] fparam The frame parameter. The array can be of size : - * nframes x dim_fparam. - * dim_fparam. Then all frames are assumed to be provided with the same - *fparam. - * @param[in] aparam The atomic parameter The array can be of size : - * nframes x natoms x dim_aparam. - * natoms x dim_aparam. Then all frames are assumed to be provided with the - *same aparam. - * @warning Natoms should not be zero when computing multiple frames. - **/ - /** * @brief Evaluate the energy, force and virial by using this DP with the *neighbor list. @@ -1471,10 +1444,9 @@ class DeepSpin : public DeepBaseModel { dpbase = (DP_DeepBaseModel *)dp; }; - // support spin /** * @brief Evaluate the energy, force, magnetic force and virial by using this - *DP with spin input. + *DP spin model. * @param[out] ener The system energy. * @param[out] force The force on each atom. * @param[out] force_mag The magnetic force on each atom. @@ -1532,15 +1504,15 @@ class DeepSpin : public DeepBaseModel { const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotComputeSP(dp, nframes, natoms, coord_, spin_, atype_, - box_, fparam__, aparam__, ener_, force_, - force_mag_, virial_, nullptr, nullptr); + _DP_DeepSpinCompute(dp, nframes, natoms, coord_, spin_, atype_, + box_, fparam__, aparam__, ener_, force_, + force_mag_, virial_, nullptr, nullptr); DP_CHECK_OK(DP_DeepBaseModelCheckOK, (DP_DeepBaseModel *)dp); }; /** * @brief Evaluate the energy, force, magnetic force, virial, atomic energy, - *and atomic virial by using this DP with spin input. + *and atomic virial by using this DP spin model. * @param[out] ener The system energy. * @param[out] force The force on each atom. * @param[out] force_mag The magnetic force on each atom. @@ -1607,13 +1579,39 @@ class DeepSpin : public DeepBaseModel { const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotComputeSP( + _DP_DeepSpinCompute( dp, nframes, natoms, coord_, spin_, atype_, box_, fparam__, aparam__, ener_, force_, force_mag_, virial_, atomic_ener_, atomic_virial_); DP_CHECK_OK(DP_DeepBaseModelCheckOK, (DP_DeepBaseModel *)dp); }; - // support spin + /** + * @brief Evaluate the energy, force, magnetic force and virial by using this + * DP spin model with the neighbor list. + * @param[out] ener The system energy. + * @param[out] force The force on each atom. + * @param[out] force_mag The magnetic force on each atom. + * @param[out] virial The virial. + * @param[in] coord The coordinates of atoms. The array should be of size + *nframes x natoms x 3. + * @param[in] spin The spins of atoms, [0, 0, 0] if no spin. The array should + *be of size nframes x natoms x 3. + * @param[in] atype The atom types. The list should contain natoms ints. + * @param[in] box The cell of the region. The array should be of size nframes + *x 9 (PBC) or empty (no PBC). + * @param[in] nghost The number of ghost atoms. + * @param[in] nlist The neighbor list. + * @param[in] ago Update the internal neighbour list if ago is 0. + * @param[in] fparam The frame parameter. The array can be of size : + * nframes x dim_fparam. + * dim_fparam. Then all frames are assumed to be provided with the same + *fparam. + * @param[in] aparam The atomic parameter The array can be of size : + * nframes x natoms x dim_aparam. + * natoms x dim_aparam. Then all frames are assumed to be provided with the + *same aparam. + * @warning Natoms should not be zero when computing multiple frames. + **/ template void compute( ENERGYVTYPE &ener, @@ -1655,14 +1653,42 @@ class DeepSpin : public DeepBaseModel { aparam); const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotComputeNListSP(dp, nframes, natoms, coord_, spin_, - atype_, box_, nghost, lmp_list.nl, ago, - fparam__, aparam__, ener_, force_, - force_mag_, virial_, nullptr, nullptr); + _DP_DeepSpinComputeNList(dp, nframes, natoms, coord_, spin_, + atype_, box_, nghost, lmp_list.nl, ago, + fparam__, aparam__, ener_, force_, + force_mag_, virial_, nullptr, nullptr); DP_CHECK_OK(DP_DeepBaseModelCheckOK, (DP_DeepBaseModel *)dp); }; - // support spin + /** + * @brief Evaluate the energy, force, magnetic force, virial, atomic energy, + * and atomic virial by using this DP spin model with the neighbor list. + * @param[out] ener The system energy. + * @param[out] force The force on each atom. + * @param[out] force_mag The magnetic force on each atom. + * @param[out] virial The virial. + * @param[out] atom_energy The atomic energy. + * @param[out] atom_virial The atomic virial. + * @param[in] coord The coordinates of atoms. The array should be of size + *nframes x natoms x 3. + * @param[in] spin The spins of atoms, [0, 0, 0] if no spin. The array should + *be of size nframes x natoms x 3. + * @param[in] atype The atom types. The list should contain natoms ints. + * @param[in] box The cell of the region. The array should be of size nframes + *x 9 (PBC) or empty (no PBC). + * @param[in] nghost The number of ghost atoms. + * @param[in] nlist The neighbor list. + * @param[in] ago Update the internal neighbour list if ago is 0. + * @param[in] fparam The frame parameter. The array can be of size : + * nframes x dim_fparam. + * dim_fparam. Then all frames are assumed to be provided with the same + *fparam. + * @param[in] aparam The atomic parameter The array can be of size : + * nframes x natoms x dim_aparam. + * natoms x dim_aparam. Then all frames are assumed to be provided with the + *same aparam. + * @warning Natoms should not be zero when computing multiple frames. + **/ template void compute( ENERGYVTYPE &ener, @@ -1710,7 +1736,7 @@ class DeepSpin : public DeepBaseModel { aparam); const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotComputeNListSP( + _DP_DeepSpinComputeNList( dp, nframes, natoms, coord_, spin_, atype_, box_, nghost, lmp_list.nl, ago, fparam__, aparam__, ener_, force_, force_mag_, virial_, atomic_ener_, atomic_virial_); @@ -2428,7 +2454,32 @@ class DeepSpinModelDevi : public DeepBaseModelDevi { aparam_nall = DP_DeepBaseModelDeviIsAParamNAll((DP_DeepBaseModelDevi *)dp); dpbase = (DP_DeepBaseModelDevi *)dp; }; - // support spin + /** + * @brief Evaluate the energy, force, magnetic force and virial by using this + * DP spin model deviation. + * @param[out] ener The system energy. + * @param[out] force The force on each atom. + * @param[out] force_mag The magnetic force on each atom. + * @param[out] virial The virial. + * @param[in] coord The coordinates of atoms. The array should be of size + *nframes x natoms x 3. + * @param[in] spin The spins of atoms, [0, 0, 0] if no spin. The array should + *be of size nframes x natoms x 3. + * @param[in] atype The atom types. The list should contain natoms ints. + * @param[in] box The cell of the region. The array should be of size nframes + *x 9 (PBC) or empty (no PBC). + * @param[in] nghost The number of ghost atoms. + * @param[in] nlist The neighbor list. + * @param[in] ago Update the internal neighbour list if ago is 0. + * @param[in] fparam The frame parameter. The array can be of size : + * nframes x dim_fparam. + * dim_fparam. Then all frames are assumed to be provided with the same + *fparam. + * @param[in] aparam The atomic parameter The array can be of size : + * nframes x natoms x dim_aparam. + * natoms x dim_aparam. Then all frames are assumed to be provided with the + *same aparam. + **/ template void compute( std::vector &ener, @@ -2474,7 +2525,7 @@ class DeepSpinModelDevi : public DeepBaseModelDevi { aparam); const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotModelDeviComputeNListSP( + _DP_DeepSpinModelDeviComputeNList( dp, natoms, coord_, spin_, atype_, box_, nghost, lmp_list.nl, ago, fparam__, aparam__, ener_, force_, force_mag_, virial_, nullptr, nullptr); @@ -2501,7 +2552,34 @@ class DeepSpinModelDevi : public DeepBaseModelDevi { } }; - // support spin + /** + * @brief Evaluate the energy, force, magnetic force, virial, atomic energy, + * and atomic virial by using this DP spin model deviation. + * @param[out] ener The system energy. + * @param[out] force The force on each atom. + * @param[out] force_mag The magnetic force on each atom. + * @param[out] virial The virial. + * @param[out] atom_energy The atomic energy. + * @param[out] atom_virial The atomic virial. + * @param[in] coord The coordinates of atoms. The array should be of size + *nframes x natoms x 3. + * @param[in] spin The spins of atoms, [0, 0, 0] if no spin. The array should + *be of size nframes x natoms x 3. + * @param[in] atype The atom types. The list should contain natoms ints. + * @param[in] box The cell of the region. The array should be of size nframes + *x 9 (PBC) or empty (no PBC). + * @param[in] nghost The number of ghost atoms. + * @param[in] nlist The neighbor list. + * @param[in] ago Update the internal neighbour list if ago is 0. + * @param[in] fparam The frame parameter. The array can be of size : + * nframes x dim_fparam. + * dim_fparam. Then all frames are assumed to be provided with the same + *fparam. + * @param[in] aparam The atomic parameter The array can be of size : + * nframes x natoms x dim_aparam. + * natoms x dim_aparam. Then all frames are assumed to be provided with the + *same aparam. + **/ template void compute( std::vector &ener, @@ -2554,7 +2632,7 @@ class DeepSpinModelDevi : public DeepBaseModelDevi { aparam); const VALUETYPE *fparam__ = !fparam_.empty() ? &fparam_[0] : nullptr; const VALUETYPE *aparam__ = !aparam_.empty() ? &aparam_[0] : nullptr; - _DP_DeepPotModelDeviComputeNListSP( + _DP_DeepSpinModelDeviComputeNList( dp, natoms, coord_, spin_, atype_, box_, nghost, lmp_list.nl, ago, fparam__, aparam__, ener_, force_, force_mag_, virial_, atomic_ener_, atomic_virial_); diff --git a/source/api_c/src/c_api.cc b/source/api_c/src/c_api.cc index e42fa16e93..5f453cccd1 100644 --- a/source/api_c/src/c_api.cc +++ b/source/api_c/src/c_api.cc @@ -1722,26 +1722,6 @@ void DP_DeepPotModelDeviComputeNList(DP_DeepPotModelDevi* dp, force, virial, atomic_energy, atomic_virial); } -void DP_DeepSpinModelDeviComputeNListSP(DP_DeepSpinModelDevi* dp, - const int natoms, - const double* coord, - const double* spin, - const int* atype, - const double* cell, - const int nghost, - const DP_Nlist* nlist, - const int ago, - double* energy, - double* force, - double* force_mag, - double* virial, - double* atomic_energy, - double* atomic_virial) { - DP_DeepSpinModelDeviComputeNList_variant( - dp, 1, natoms, coord, spin, atype, cell, nghost, nlist, ago, NULL, NULL, - energy, force, force_mag, virial, atomic_energy, atomic_virial); -} - void DP_DeepPotModelDeviComputeNListf(DP_DeepPotModelDevi* dp, const int natoms, const float* coord, @@ -1760,26 +1740,6 @@ void DP_DeepPotModelDeviComputeNListf(DP_DeepPotModelDevi* dp, force, virial, atomic_energy, atomic_virial); } -void DP_DeepSpinModelDeviComputeNListfSP(DP_DeepSpinModelDevi* dp, - const int natoms, - const float* coord, - const float* spin, - const int* atype, - const float* cell, - const int nghost, - const DP_Nlist* nlist, - const int ago, - double* energy, - float* force, - float* force_mag, - float* virial, - float* atomic_energy, - float* atomic_virial) { - DP_DeepSpinModelDeviComputeNList_variant( - dp, 1, natoms, coord, spin, atype, cell, nghost, nlist, ago, NULL, NULL, - energy, force, force_mag, virial, atomic_energy, atomic_virial); -} - void DP_DeepPotModelDeviComputeNList2(DP_DeepPotModelDevi* dp, const int nframes, const int natoms,