Page 1 of 1

Stress in MLFF

Posted: Thu Oct 31, 2024 3:14 am
by reza_namakian1

Dear VASP Team,

I have a naive question regarding the inclusion of stress in training an MLFF:

"If you train a system containing a surface or isolated molecules, do not train the stresses. For that, set ML_WTSIF to a very small value in the INCAR file (e.g., ML_WTSIF=1E-10)."

I was wondering what would be the consequences of including stresses during training for slab configurations or when developing an MLFF for 2D materials. A colleague told me that stresses calculated from VASP are noisy, and as far as I know, there is no threshold that can be set to control the stress values in VASP. Is this one of the reasons for not including stresses in these scenarios, or are there other reasons that I'm missing here?

Thank you so much in advance for your clarification!


Re: Stress in MLFF

Posted: Thu Oct 31, 2024 12:50 pm
by jonathan_lahnsteiner2

Dear Reza Namakian,

The reason not to train stresses for a surface is that it is terminated by a vacuum layer. Also an isolated molecule is surrounded by vacuum. A vacuum can not exert stress onto the atoms in your simulation. Therefore it does not make sense do include the stress in your training data. We updated the vasp wiki Best practices for machine-learned force fields site to make this more clear.

All the best Jonathan


Re: Stress in MLFF

Posted: Fri Nov 01, 2024 3:42 am
by reza_namakian1

Thanks a lot, Jonathan, for the clarification!

Just a quick follow-up on this: as you know, there are numerous studies on the mechanical properties of 2D materials like graphene, where stress-strain curves have been generated using atomistic simulations. While it's true that stress in the full 3x3 form isn't entirely well-defined here—especially within the graphene plane—it might still be useful to learn in-plane stresses for MLFF, even though there's a vacuum normal to this plane. Or perhaps not? Honestly, I'm still not entirely sure how interpretable or reliable the in-plane stresses calculated from DFT calculations for 2D materials really are.


Re: Stress in MLFF

Posted: Mon Nov 04, 2024 10:21 am
by jonathan_lahnsteiner2

Dear Reza Namakian,

You are right it would make sense to only learn in plane stress tensors. Currently this is not possible in vasp and therefore we suggest to not learn the stress tensor at all.

All the best Jonathan


Re: Stress in MLFF

Posted: Mon Nov 04, 2024 5:27 pm
by reza_namakian1

Many thanks for the clarification, Jonathan!