MolecularDiffusion.modules.models.syncogen.diffusion.loss.smooth_lddt

Smooth LDDT-based loss that operates on Coordinates objects.

Classes

SmoothLDDTLoss

Smooth LDDT-based loss.

Module Contents

class MolecularDiffusion.modules.models.syncogen.diffusion.loss.smooth_lddt.SmoothLDDTLoss(cutoff: float = 15.0, sqrd: bool = False, coef: float = 1.0, time_weighted: bool = False, square_time_weight: bool = False, t_threshold: float = None, normalize_threshold: bool = True)

Bases: MolecularDiffusion.modules.models.syncogen.diffusion.loss.base.LossBase

Smooth LDDT-based loss.

compute_loss(pred, target) torch.Tensor

Base per-graph smooth LDDT loss (no time weighting or coef).

forward(pred, target, t: torch.Tensor = None) torch.Tensor

Compute loss -> optional time weight -> threshold -> coef.

cutoff = 15.0
normalize_threshold = True
sqrd = False