cagrikymk / JAX-ReaxFF

JAX-ReaxFF: A Gradient Based Framework for Extremely Fast Optimization of Reactive Force Fields
GNU General Public License v3.0
52 stars 21 forks source link

Problem on energy minimization #22

Open houdingyu opened 1 month ago

houdingyu commented 1 month ago

Thank you very much for sharing the code. I am training a set of ReaxFF parameters against the equation of state of Si3N4 crystal using JAX-ReaxFF. However, I noticed that the error reported by JAX-ReaxFF is not consistent with the error calculated by the standalone ReaxFF fortran code. I suspect this difference is caused by different algorithm of energy minimization (i.e., geometry optimization) in JAX-ReaxFF and standalone ReaxFF fortran code? I checked the output of JAX-ReaxFF, and it suggests that RMSG for most structures are larger than 1 after energy minimization. (I used num_e_minim_steps 1000 and e_minim_LR 5e-4). Am I supposed to change these two parameters until < 1.0 RMSG can be achieved?

cagrikymk commented 1 month ago

@houdingyu The energy minimizer in this library is not state of the art and might not work too well for unstable geometries. The optimizer can still work while having small discrepancies. However, if the difference is large, it might indicate some bug in the code.

What is the cell structure? If you could email me the structure and the force field, I can try to reproduce the issue and see if there is any problems in the code.

houdingyu commented 1 month ago

@houdingyu The energy minimizer in this library is not state of the art and might not work too well for unstable geometries. The optimizer can still work while having small discrepancies. However, if the difference is large, it might indicate some bug in the code.

What is the cell structure? If you could email me the structure and the force field, I can try to reproduce the issue and see if there is any problems in the code.

Thank you very much for your reply. Please see the attached input files I have used for running JAX-ReaxFF. The initial force field is taken from literature (J. Phys. Chem. C 2020, 124, 18, 10007–10015). I have optimized Si-Si bond parameters and Si-Si-Si angle parameters using JAX-ReaxFF. After that, I was trying to optimize Si-N parameters against the EOS of Si3N4 crystals, and noticed that the energy minimization may be a problem during parameter optimization. Looking forward to your reply. Si-N_EOS.zip