Closed NewSigma closed 3 years ago
https://github.com/deepmodeling/deepmd-kit/blob/2111ebb82d4401fbfcbff92691c417db4d961f89/source/lmp/pair_nnp.cpp#L455
If we specify the pair style double times, nnp_inter will be initialized double times too, which is not allowed and will lead to memory leak in release mode. It seems that pairs provided by lammps can be specified several times safely.
Let me know if I'm wrong. Thank you.
Thanks a lot for reporting the issue! we will fix it asap.
https://github.com/deepmodeling/deepmd-kit/blob/2111ebb82d4401fbfcbff92691c417db4d961f89/source/lmp/pair_nnp.cpp#L455
If we specify the pair style double times, nnp_inter will be initialized double times too, which is not allowed and will lead to memory leak in release mode. It seems that pairs provided by lammps can be specified several times safely.
Let me know if I'm wrong. Thank you.