Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

stefaanhessmann
Copy link
Collaborator

Currently the numerical stability parameter epsilon is only used in PaiNNMixing for calculating the norm and not for calculating the norm dir_ij.
For training force field models this is not necessary, because force field datasets do not contain any structures where two atoms come very close. However, in generative models (e.g. diffusion) it can happen that two atoms are located at the same position.
I suggest to add the same numerical stability parameter epsilon as for calculating the norm in PaiNNMixing:

105        mu_Vn = torch.sqrt(torch.sum(mu_V**2, dim=-2, keepdim=True) + self.epsilon)

@stefaanhessmann stefaanhessmann marked this pull request as draft June 24, 2025 09:45
@stefaanhessmann
Copy link
Collaborator Author

I also added the argument return_vector_representation in PaiNN to make it consistent with SO3Net.

Copy link
Collaborator

@Maltimore Maltimore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! I didn't fully check all the changes in the generated .ipynb file, but I suppose they're fine.

@Maltimore
Copy link
Collaborator

two intermediate commits should probably be squashed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants