diff --git a/source/api_cc/tests/test_deeppot_dpa_pt.cc b/source/api_cc/tests/test_deeppot_dpa_pt.cc index eeef0620b6..4adc12084f 100644 --- a/source/api_cc/tests/test_deeppot_dpa_pt.cc +++ b/source/api_cc/tests/test_deeppot_dpa_pt.cc @@ -25,15 +25,15 @@ class TestInferDeepPotDpaPt : public ::testing::Test { 3.51, 2.51, 2.60, 4.27, 3.22, 1.56}; std::vector atype = {0, 0, 0, 0, 0, 0}; std::vector box = {13., 0., 0., 0., 13., 0., 0., 0., 13.}; - std::vector expected_e = { --92.764905689986, -186.094047026640, -186.076093742681, -92.655789598697, - -185.718629663486}; + std::vector expected_e = {-92.764905689986, -186.094047026640, + -186.076093742681, -92.655789598697, + -185.718629663486}; std::vector expected_f = { --6.014285454688, -0.117415862256, 0.909976406194, -0.058755844443, - -0.589966016072, -0.235278171532, 0.483870488636, 0.338301034169, + -6.014285454688, -0.117415862256, 0.909976406194, -0.058755844443, + -0.589966016072, -0.235278171532, 0.483870488636, 0.338301034169, -0.538259022526, 5.229560416553}; std::vector expected_v = { - -10.354386415497, 0.920140248533, 6.499718669934, -16.258335886103, + -10.354386415497, 0.920140248533, 6.499718669934, -16.258335886103, 0.067297469207, -0.575195264098, 4.392295016061, -0.338241970141, -0.835516051852, -14.851643816437, 0.033098659297, -1.061263863927, 2.374008409869, -0.016149388418, 0.170055485103, 8.600268264426, diff --git a/source/lmp/tests/test_lammps_dpa_pt.py b/source/lmp/tests/test_lammps_dpa_pt.py index 1ffef606ae..cda00c8253 100644 --- a/source/lmp/tests/test_lammps_dpa_pt.py +++ b/source/lmp/tests/test_lammps_dpa_pt.py @@ -33,16 +33,26 @@ # this is as the same as python and c++ tests, test_deeppot_a.py expected_ae = np.array( [ --92.764905689986, -186.094047026640, -186.076093742681, -92.655789598697, - -185.718629663486 + -92.764905689986, + -186.094047026640, + -186.076093742681, + -92.655789598697, + -185.718629663486, ] ) expected_e = np.sum(expected_ae) expected_f = np.array( [ --6.014285454688, -0.117415862256, 0.909976406194, -0.058755844443, - -0.589966016072, -0.235278171532, 0.483870488636, 0.338301034169, - -0.538259022526, 5.229560416553 + -6.014285454688, + -0.117415862256, + 0.909976406194, + -0.058755844443, + -0.589966016072, + -0.235278171532, + 0.483870488636, + 0.338301034169, + -0.538259022526, + 5.229560416553, ] ).reshape(6, 3) @@ -59,20 +69,60 @@ expected_v = -np.array( [ - -10.354386415497, 0.920140248533, 6.499718669934, -16.258335886103, - 0.067297469207, -0.575195264098, 4.392295016061, -0.338241970141, - -0.835516051852, -14.851643816437, 0.033098659297, -1.061263863927, - 2.374008409869, -0.016149388418, 0.170055485103, 8.600268264426, - -0.027869254689, 0.691937433336, 6.169225730997, 0.244831791298, - 0.034831047240, 12.137933736936, 0.115779703815, 0.522653171179, - -10.043154308105, -0.213524051977, -0.159862489647, 27.897569062860, - 0.850893105913, -7.167280545513, 6.502654913608, 0.019020688297, - -0.452832699108, -8.392512895479, 0.032993026742, 0.099452385425, - 4.585903488998, -0.087008504902, 0.195331013424, -4.461738874082, - -0.410332961015, 0.302227770306, 6.852403864252, 0.649592712208, - -0.468543024604, 5.650128346142, -0.619456389363, 1.329581340420, - 1.047976610548, -0.169940826454, 0.360848206024, -1.578382279577, - 0.224806207264, -0.471006970793 + -10.354386415497, + 0.920140248533, + 6.499718669934, + -16.258335886103, + 0.067297469207, + -0.575195264098, + 4.392295016061, + -0.338241970141, + -0.835516051852, + -14.851643816437, + 0.033098659297, + -1.061263863927, + 2.374008409869, + -0.016149388418, + 0.170055485103, + 8.600268264426, + -0.027869254689, + 0.691937433336, + 6.169225730997, + 0.244831791298, + 0.034831047240, + 12.137933736936, + 0.115779703815, + 0.522653171179, + -10.043154308105, + -0.213524051977, + -0.159862489647, + 27.897569062860, + 0.850893105913, + -7.167280545513, + 6.502654913608, + 0.019020688297, + -0.452832699108, + -8.392512895479, + 0.032993026742, + 0.099452385425, + 4.585903488998, + -0.087008504902, + 0.195331013424, + -4.461738874082, + -0.410332961015, + 0.302227770306, + 6.852403864252, + 0.649592712208, + -0.468543024604, + 5.650128346142, + -0.619456389363, + 1.329581340420, + 1.047976610548, + -0.169940826454, + 0.360848206024, + -1.578382279577, + 0.224806207264, + -0.471006970793, ] ).reshape(6, 9) expected_v2 = -np.array(