|
Dear @gabor1, I have two different datasets (dataset 1 and dataset 2) that include the same metal (M) in different electronic states, which we can call M₁ and M₂. I was wondering if it is possible to develop a single potential from a combined data pool that includes both datasets by defining custom atoms M₁ and M₂. In addition, how can I define the reference-energy entry for both atoms? I would also like to perform fine-tuning. Is this possible? Thanks. Paula Abufager |
Replies: 12 comments 39 replies
|
If you always want to keep M1 and M2 separate, you will never want to change one oxidation state into the other, you can pretend that M1 and M2 are different atoms (just use a fake atom type). Alternatively, you can just call them both the same atom, and let MACE ingest all the data - it will need to infer the electronic structure from the local geometry. for many cases that works well! |
|
One way you can do that cleanly also is using the new embedding functionality of mace. Just create a categorical embedding with 0 being M1 and 1 being M1. You add to your input the following Then add oxydations_states to the atoms.arrays. You will need to modify the AtomicData though to correctly extract it. See the test here: mace/tests/test_embedding_train.py Line 13 in 0139da1 AtomicData here: https://github.com/ACEsuit/mace/blob/0139da1b864b29054f07db6627887a847a42050e/mace/data/atomic_data.py Plus if you |
|
bring the discussion from #1218 here @bernstei @rreocreux |
|
It seems like the embedding functionality is the best, and it's already almost there, just needs a modification in the data extractor ? |
|
yeah someone needs to take the pieces that exist and just put them together into an example that works. Several people could do it (@RokasEl @hatemhelal etc.) I'll ask around who has the capacity. |
|
@ilyes319 can you confirm the format of |
|
So, it turns out that doing this well for arbitrary features is actually quite tricky, basically because there are several different places where you need to know what atoms.info/atoms.arrays entries you need in the Actually, this is already broken, I think. You can see that I'm trying to figure out what can be done, but there are so many places that at least a piece of the |
|
Please see #1222. Seems to work in my initial test https://github.com/ACEsuit/mace/blob/arb_per_atom_descriptors/tests/test_embedding_train.py#L213 |
|
I am not sure how to include the embedding_spec block in the input file for training. I am not using config.yaml. Please find below my input file (after running, it does not recognize the embedding part). In the trainG1.xyz and testG1.xyz files, I have included total_spin = X (with X being the corresponding value) on the line where REF_energy is defined for each configuration. Thank you very much. Best. Paula. mace_run_train |
|
Dear @ilyes319 In total_spin_key (embedding part), I replaced spin (total_spin) with total_spin (spin), but it did not work. Any help would be welcome. Thanks. Paula |
|
Dear @bernstei , I would like to know if there is any known incompatibility between PyTorch 2.4.0 and the development version of MACE. Thank you very much, Best. Paula 2025-11-10 13:52:04.787 INFO: Training complete |
If you always want to keep M1 and M2 separate, you will never want to change one oxidation state into the other, you can pretend that M1 and M2 are different atoms (just use a fake atom type).
Alternatively, you can just call them both the same atom, and let MACE ingest all the data - it will need to infer the electronic structure from the local geometry. for many cases that works well!