Stress in MLFF

Queries about input and output files, running specific calculations, etc.


Moderators: Global Moderator, Moderator

Post Reply
Message
Author
reza_namakian1
Newbie
Newbie
Posts: 11
Joined: Wed Jun 26, 2024 3:39 pm

Stress in MLFF

#1 Post by reza_namakian1 » Thu Oct 31, 2024 3:14 am

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!


jonathan_lahnsteiner2
Global Moderator
Global Moderator
Posts: 215
Joined: Fri Jul 01, 2022 2:17 pm

Re: Stress in MLFF

#2 Post by jonathan_lahnsteiner2 » Thu Oct 31, 2024 12:50 pm

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


reza_namakian1
Newbie
Newbie
Posts: 11
Joined: Wed Jun 26, 2024 3:39 pm

Re: Stress in MLFF

#3 Post by reza_namakian1 » Fri Nov 01, 2024 3:42 am

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.


jonathan_lahnsteiner2
Global Moderator
Global Moderator
Posts: 215
Joined: Fri Jul 01, 2022 2:17 pm

Re: Stress in MLFF

#4 Post by jonathan_lahnsteiner2 » Mon Nov 04, 2024 10:21 am

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


reza_namakian1
Newbie
Newbie
Posts: 11
Joined: Wed Jun 26, 2024 3:39 pm

Re: Stress in MLFF

#5 Post by reza_namakian1 » Mon Nov 04, 2024 5:27 pm

Many thanks for the clarification, Jonathan!


Post Reply