torchref.refinement.targets.geometry.base module

class torchref.refinement.targets.geometry.base.GeometryTarget(model=None, verbose=0, **kwargs)[source]

Bases: ModelTarget

Base class for geometry restraint targets.

Geometry targets access the model’s restraints property (built lazily) to compute losses for bonds, angles, torsions, planes, etc.

Parameters:
  • model (Model, optional) – Reference to the Model object.

  • verbose (int, optional) – Verbosity level. Default is 0.

  • target_value (float, optional) – Target value for this loss. Default is -1.0.

  • sigma (float, optional) – Sigma parameter for weighting. Default is 0.5.

__init__(model=None, verbose=0, **kwargs)[source]

Initialize model target.

Parameters:
  • model (Model, optional) – Reference to the Model object (optional for empty init).

  • verbose (int, optional) – Verbosity level. Default is 0.

stats()[source]

Get statistics for this restraint type.

Returns dict with StatEntry values. Filter with filter_stats() at display time.

Returns:

Statistics dict with StatEntry values containing verbosity levels.

Return type:

dict