-
Notifications
You must be signed in to change notification settings - Fork 68
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
Can not exclude stresses from training #397
Comments
Hi, Based on the error message, it looks like this version of the code requires you to set the energy noise even if you're not training on stress. |
Did you mean stress noise? raise PropertyNotImplementedError('{} not present in this ' Re-enabling stress calculation, I would get a training on stress as well. I would get stresses predictions and mae on the output file anyway. Maybe it would output those without using them, but I can not understand if that is the case. This "stress not present" gives me lots of doubts, why would you need it? For validation maybe? |
Sorry, yes, I meant the stress noise. From what I can tell, it looks like it might work to set flare/flare/bffs/sgp/sparse_gp.py Lines 365 to 366 in 700f2c8
Note: I have no familiarity with the YAML file and |
I tried an offline training on a database I had which included stress tensors, and actually by setting Also the potential made worse predictions, so I think I will keep stresses in there.
Really interesting. I will contact you about it, I don't think I can contribute with code but will be happy to help. |
I would like to train my model on forces and energies, excluding stresses. In my input.yaml i have:
input.yaml
[.....]
flare_calc:
gp: SGP_Wrapper
kernels:
- name: NormalizedDotProduct
sigma: 3.0
power: 2
descriptors:
- name: B2
nmax: 9
lmax: 3
cutoff_function: quadratic
radial_basis: chebyshev
cutoff_matrix: [[5.0]]
energy_training: True
force_training: True
stress_training: False
energy_noise: 0.3
forces_noise: 0.1
#stress_noise: 0.001
species:
- 13
single_atom_energies:
- 0
cutoff: 5.0
variance_type: local
max_iterations: 50
use_mapping: True
[.....]
This input worked well for trainings that include stresses, however, once I changed
stress_training: False
And commented the stress noise, I can not run the training. Instead I would get:
output
Traceback (most recent call last):
File "[...]/miniconda3/envs/envflare/bin/flare-otf", line 8, in
sys.exit(main())
File "[....]/flare/flare/scripts/otf_train.py", line 378, in main
fresh_start_otf(config)
File "[....]/flare/flare/scripts/otf_train.py", line 324, in fresh_start_otf
flare_calc, kernels = get_flare_calc(config["flare_calc"])
File "[....]/flare/flare/scripts/otf_train.py", line 99, in get_flare_calc
return get_sgp_calc(flare_config)
File "[....]/flare/flare/scripts/otf_train.py", line 295, in get_sgp_calc
sgp = SGP_Wrapper(
File "[.....]/flare/flare/bffs/sgp/sparse_gp.py", line 40, in __init__
self.sparse_gp = SparseGP(kernels, sigma_e, sigma_f, sigma_s)
TypeError: __init__(): incompatible constructor arguments. The following argument types are supported:
1. flare.bffs.sgp._C_flare.SparseGP()
2. flare.bffs.sgp._C_flare.SparseGP(arg0: List[flare.bffs.sgp._C_flare.Kernel], arg1: float, arg2: float, arg3: float)
Invoked with: [<flare.bffs.sgp._C_flare.NormalizedDotProduct object at 0x7f8465bdae30>], 0.3, 0.1, None
Information
FLARE version: 1.3.3
The text was updated successfully, but these errors were encountered: