ase_uhal.committee_calculators.TorchCommitteeCalculator#

class ase_uhal.committee_calculators.TorchCommitteeCalculator(*args, **kwargs)[source]#
__init__(*args, **kwargs)[source]#
Parameters:
  • *args, **kwargs

  • Passed to :class:`~ase_uhal.committee_calculators.BaseCommitteeCalculator`

resample_committee(committee_size=None)[source]#

Resample the committee, based on the states of self.likelihood and self.sqrt_prior Populates self.committee_weights based on the newly sampled committee

Parameters:

committee_size (int, optional) – New size of the committee, if supplied. By default, a committee of size self.n_comm is drawn

select_structure(atoms)#
sync()#
get_descriptor_energy(atoms=None)#

Get “descriptor energy”, which is the average of descriptor vectors in the structure

Returns an array of length self.n_desc

get_descriptor_forces(atoms=None)#

Get “descriptor forces”, which are the derivatives w.r.t atomic positions of the total descriptor energy

Returns an array of shape (self.n_desc, Nats, 3)

get_descriptor_stress(atoms=None)#

Get “descriptor stresses”, which are the stress analogues to the total descriptor energy

Returns an array of shape (self.n_desc, 3, 3)

get_committee_energies(atoms=None)#

Get energy predictions by each member of the committee

Returns an array of length self.n_comm

get_committee_forces(atoms=None)#

Get force predictions by each member of the committee

Returns an array of shape (self.n_comm, Nats, 3)

get_committee_stresses(atoms=None)#

Get stress predictions by each member of the committee

Returns an array of shape (self.n_comm, 3, 3)

get_bias_energy(atoms=None)#
get_bias_forces(atoms=None)#
get_bias_stress(atoms=None)#

Methods

__init__(*args, **kwargs)

band_structure()

Create band-structure object for plotting.

calculate([atoms, properties, system_changes])

Do the calculation.

calculate_numerical_forces(atoms[, d])

Calculate numerical forces using finite difference.

calculate_numerical_stress(atoms[, d, voigt])

Calculate numerical stress using finite difference.

calculate_properties(atoms, properties)

This method is experimental; currently for internal use.

calculation_required(atoms, properties)

check_state(atoms[, tol])

Check for any system changes since last calculation.

export_properties()

get_atoms()

get_bias_energy([atoms])

get_bias_forces([atoms])

get_bias_stress([atoms])

get_charges([atoms])

get_committee_energies([atoms])

Get energy predictions by each member of the committee

get_committee_forces([atoms])

Get force predictions by each member of the committee

get_committee_stresses([atoms])

Get stress predictions by each member of the committee

get_default_parameters()

get_descriptor_energy([atoms])

Get "descriptor energy", which is the average of descriptor vectors in the structure

get_descriptor_forces([atoms])

Get "descriptor forces", which are the derivatives w.r.t atomic positions of the total descriptor energy

get_descriptor_stress([atoms])

Get "descriptor stresses", which are the stress analogues to the total descriptor energy

get_dipole_moment([atoms])

get_forces([atoms])

get_magnetic_moment([atoms])

get_magnetic_moments([atoms])

Calculate magnetic moments projected onto atoms.

get_potential_energies([atoms])

get_potential_energy([atoms, force_consistent])

get_property(name[, atoms, allow_calculation])

Overload of Calculator.get_property, converts from torch tensors to numpy arrays Allows for torch tensors to be stored in self.results between calls to self.calculate

get_stress([atoms])

get_stresses([atoms])

the calculator should return intensive stresses, i.e., such that stresses.sum(axis=0) == stress

read(label)

Read atoms, parameters and calculated properties from output file.

read_atoms(restart, **kwargs)

resample_committee([committee_size])

Resample the committee, based on the states of self.likelihood and self.sqrt_prior Populates self.committee_weights based on the newly sampled committee

reset()

Clear all information from old calculation.

select_structure(atoms)

set(**kwargs)

Set parameters like set(key1=value1, key2=value2, ...).

set_label(label)

Set label and convert label to directory and prefix.

sync()

todict([skip_default])

Obtain a dictionary of parameter information

Attributes

default_parameters

Default parameters

directory

discard_results_on_any_change

Whether we purge the results following any change in the set() method.

energy_weight

forces_weight

ignored_changes

Properties of Atoms which we ignore for the purposes of cache

implemented_properties

Properties calculator can handle (energy, forces, ...)

label

name

stress_weight

torch_device