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

Error when specifying more e0s then present in training set #605

Open
LarsSchaaf opened this issue Sep 23, 2024 · 1 comment
Open

Error when specifying more e0s then present in training set #605

LarsSchaaf opened this issue Sep 23, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@LarsSchaaf
Copy link
Collaborator

Description
When you specify e0s for Oxygen for example, but you dont have any oxygen in your training set you get the following error:

 File "programms/mace/modules/blocks.py", line 160, in forward
    return torch.matmul(x, torch.atleast_2d(self.atomic_energies).T)
RuntimeError: mat1 and mat2 shapes cannot be multiplied (799x7 and 8x1)

To Reproduce
Specify e0s from input script of two elements, but only have one element in dataset
--E0s={1:0.1, 2:0.2}

Solution:
Edit:

logging.info(f"Atomic Energies used (z: eV) for head {head_config.head_name}: " + "{" + ", ".join([f"{z}: {atomic_energies_dict[head_config.head_name][z]}" for z in head_config.z_table.zs]) + "}")

@gabor1
Copy link
Collaborator

gabor1 commented Sep 23, 2024

Hm.. I guess we could just silently ignore additional E0s.

@ilyes319 ilyes319 added the enhancement New feature or request label Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants