bagel.mutation.GrandCanonical.
In that type of simulation when adding a new residues, the “inheritable” attribute decides whether or not
the new residue will be added to the residues for which this term is calculated. In general, a new residue
inherits all energy terms of one of its neighbours (chosen randomly to be the left or right neighbour),
if these terms are inheritable.
Definition
The total energy of a state is the weighted sum of all its energy terms:- is the energy of state
- is the weight of energy term in state
- is the unweighted energy of term
- is the set of chains in state
Parameters
str
required
The name of the energy term.
Oracle
required
The oracle to use for the energy term.
bool
required
Whether the energy term is inheritable.
float
default:"1.0"
The weight of the energy term.
Methods
compute
Calculates the EnergyTerm’s energy given information about the folded structure. The result is returned and stored as an internal attribute (.value). ParametersOraclesResultDict
required
Dictionary mapping oracles to their results. This is used to get the relevant information for the energy term.
(unweighted_energy, weighted_energy) : tuple[float, float]
float
How well the structure satisfies the given criteria. Where possible, this number should be between 0 and 1.
float
The unweighted energy multiplied by the energy term’s weight.
shift_residues_indices_after_removal
Shifts internally stored res_indices on a given chain to reflect a residue has been removed from the chain. Parametersstr
required
int
required
shift_residues_indices_before_addition
Shifts internally stored res_indices on a given chain to reflect a residue has been added. Parametersstr
required
int
required
remove_residue
Remove residue from this energy term’s calculations. Parametersstr
required
int
required
add_residue
Adds residue to this energy term’s calculations, in the same group as its parent residue. Parametersstr
required
int
required
int
required
get_residue_mask
Creates residue mask from residue group. Structure used to find unique residues in state ParametersAtomArray
required
int
required
get_atom_mask
Creates atom mask from residue group. Structure used to find unique atoms in state ParametersAtomArray
required
int
required
