Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use_canonize for inference through pretrained.py #148

Open
ironhammer269 opened this issue Apr 10, 2024 · 1 comment
Open

use_canonize for inference through pretrained.py #148

ironhammer269 opened this issue Apr 10, 2024 · 1 comment

Comments

@ironhammer269
Copy link

pretrained.py calls following :
g, lg = Graph.atom_dgl_multigraph(
atoms,
cutoff=float(cutoff),
max_neighbors=max_neighbors,
)

This uses the default value of use_canonize = False, which is not necessarly the value which was used for training. From my testing, changing this value for inference greatly influences results (tested on jv_formation_energy_peratom_alignn with POSCAR files from the sample_data folder).

Typically, running the following : python pretrained.py --model_name jv_formation_energy_peratom_alignn --file_format poscar --file_path .\examples\sample_data\POSCAR-JVASP-107772.vasp
gives 0.003147430717945099 if use_canonize = False (default behaviour).
gives -5.2578747272491455e-05 if use_canonize = True

This difference is not huge but seems to be greatly increased when batching mutliple files for inference (my own implementation).

From these results, my guess is that one would want this variable to be stored in the model parameters, rather than called upon training/inference.

Are these normal results ? What is the physical/mathematical meaning of this variable ?

@knc6
Copy link
Collaborator

knc6 commented Apr 14, 2024

You are right @ironhammer269
We have made use_canonize as True now as it should be.

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

No branches or pull requests

2 participants