Exploration
In the exploration phase we will generate new configurations (referred to as candidates) to include in the training set. For this we will perform MD simulations with either the LAMMPS (classical nuclei) or i-PI (quantum nuclei) softwares. Go to the current iteration exploration folder XXX-exploration
created at the end of the previous training phase and execute the prepare
phase to initialize the exploration.
For the first exploration phase we might want to generate only a few candidate configurations to check whether our initial NNP are stable enough to give physically meaningful configurations. We might as well want to use a relatively strict error criterion for candidate selection.
To change these parameters you can create a input.json
file , indicating the values to be updated, and run the prepare
phase again. If you want to keep the default values you only need to run the prepare
phase once. As for the Initialization and Training steps, this will generate a used_input.json
file:
{
"step_name": "exploration",
"user_machine_keyword_exp": "mykeyword1",
"slurm_email": "",
"atomsk_path": "PATH_TO_THE_ATOMSK_BINARY",
"vmd_path": "PATH_TO_THE_VMD_BINARY",
"exploration_type": ["lammps", "lammps", "lammps"],
"traj_count": [2, 2, 2],
"temperature_K": [273.0, 300.0, 300.0],
"timestep_ps": [0.0005, 0.0005, 0.0005],
"previous_start": [true, true, true],
"disturbed_start": [false, false, false],
"print_interval_mult": [0.01, 0.01, 0.01],
"job_walltime_h": [-1, -1, -1],
"exp_time_ps": [10, 10, 10],
"max_exp_time_ps": [400, 400, 400],
"max_candidates": [50, 50, 100],
"sigma_low": [0.1, 0.1, 0.1],
"sigma_high": [0.8, 0.8, 0.8],
"sigma_high_limit": [1.5, 1.5, 1.5],
"ignore_first_x_ps": [0.5, 0.5, 0.5],
"init_exp_time_ps": [-1, -1, -1],
"init_job_walltime_h": [-1, -1, -1],
"disturbed_candidate_value": [0.5, 0, 0],
"disturbed_start_value": [0.0, 0.0, 0.0],
"disturbed_start_indexes": [[], [], []],
"disturbed_candidate_indexes": [[], [], []]
}
The "sigma_low"
, "sigma_high"
and "sigma_high_limit"
keywords indicate the deviation acceptance criteria in eV/Ang for the candidate selection.
The "max_candidates"
keywords indicates the maximum candidated that can be selected.
The values in disturbed_start_value
are used to disturb the starting structures for the next iteration. A non-zero value sets the maximal amplitude of the random translation vector that will be applied to each atom (a different vector for each atom) in Å.
Note: the vmd_path
keyword is not needed if vmd
is inmediately available in our path when executing the extract
phase (loaded as a module for example). Similarly, we can remove atomsk_path
if atomsk
is already in the path.
Some of the phases are slightly different if you use LAMMPS or i-PI, both phase workflows are detailed below.
LAMMPS: classical nuclei simulations
Once you are satisfied with your exploration parameters (see example below) you can execute the next exploration phases : launch
to run MD trajectories with each subsystem and check
(once the Slurm
MD jobs are done!). If the check
phase is succesfull, you can move on to the deviate
phase, where you can set important parameters for candidate selection. Once again you can modify these keywors by the creation (or modification if you already created one for a previous phase) of a default_input.json
file and re-executing the deviate
phase. In the extract
phase an important choice can be made: whether to include "disturbed" candidates in the training set or not. This is done by changing the disturbed_start_value
and disturbed_candidate_value
variables from the defaults (0.0) and will include a set of candidates generated by applying a random perturbation to those obtained in the MD trajectories (this will multiply by 2 the number of selected candidates, make sure that the disturbed_start_value
that you choose will still give physically meaningful configurations, otherwise you will deteriorate your NNP!). Once you execute this phase a candidates_SUBSYS_XXX.xyz
file will be created in each subsystem directory containing the candidate configurations that will be added to the training set (you might want to check that they make sense!). You can also disturb only some atoms in the configuration in which case you will need to write their (zero-based) atomic indices in the disturbed_candidate_indexes
variable. The clean
phase can be executed to clean up all the temporary files. A control/exploration_XXX.json
file will be written recording all the exploration parameters. You can now move on to the labeling phase! (Don't forget to keep your local folder updated so that you can analyze all these results)
i-PI quantum nuclei simulations
Simulations explicitly including nuclear quantum effects by path-integral molecular dynamics with i-PI are quite similar to classical nuclei simulations with LAMMPS. Although the i-PI input files are different (see i-PI), the prepare
, launch
and check
phases can be done exactly as previously (see LAMMPS classical nuclei simulations above). Then, before executing the deviate
and extract
phases, you must run select_beads
and rerun
in this order. These phases do not have special parameters that need to be tuned but require VMD
and Atomsk
. After that, you can run the rest of the steps as for LAMMPS MD simulations.