xnn.ffnn.models.amberlib.from_forcefield#
- xnn.ffnn.models.amberlib.from_forcefield(ff, strict=True)[source]#
Build an
AmberLibraryfrom a resolved.frcforce field.- Parameters:
ff (xnn.ffnn.common.frc.ForceField) – A force field of the AMBER functional form:
quadratic_bond,quadratic_angle,torsion_fourier,improper_fourierand anonbond(12-6)section with arithmetic combination (the reader already normalised its@typeto sigma/epsilon;R*is recovered assigma 2^(1/6) / 2).strict (bool, optional) – If
True(default) refuse a force field that carries functional forms this model does not implement; ifFalseignore those sections and record them innotes.
- Returns:
The library, including the file’s templates and residue fragments.
- Return type:
- Raises:
ValueError – If the nonbond combination rule is not arithmetic, or an unsupported section is present under
strict.