Skip to contents

Supplement equation (7) of Jumper et al. (2021), p. 32. A fixed weighted sum of the FAPE loss, the structure module's auxiliary loss, the distogram and masked-MSA cross entropies and the confidence loss, with the experimentally-resolved and violation terms added only during fine-tuning. The coefficients are the published ones, not free parameters.

Usage

Alfloss(
  fape,
  aux,
  dist,
  msa,
  conf,
  expres = 0,
  viol = 0,
  phase = "training",
  ncrop = NULL
)

Arguments

fape, aux, dist, msa, conf

The five always-present loss terms.

expres, viol

The two fine-tuning-only terms.

phase

Either "training" or "finetuning".

ncrop

Optional residue count after cropping; the total is then multiplied by its square root, the reweighting described just below equation (7).

Value

A list with the weighted terms, the total estimate, the unscaled total, phase, scale and method.

References

Jumper et al (2021) Nature 596:583-589, Suppl. equation (7)

Examples

Alfloss(fape = c(1, 2, 3, 4, 5, 6, 7, 8), aux = c(1, 2, 3, 4, 5, 6, 7, 8),
  dist = c(1, 2, 3, 4, 5, 6, 7, 8), msa = c(1, 2, 3, 4, 5, 6, 7, 8), conf = 0.5)
#> $terms
#> $terms$fape
#> [1] 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0
#> 
#> $terms$aux
#> [1] 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0
#> 
#> $terms$dist
#> [1] 0.3 0.6 0.9 1.2 1.5 1.8 2.1 2.4
#> 
#> $terms$msa
#> [1]  2  4  6  8 10 12 14 16
#> 
#> $terms$conf
#> [1] 0.005
#> 
#> 
#> $estimate
#> [1] 118.805
#> 
#> $unscaled
#> [1] 118.805
#> 
#> $phase
#> [1] "training"
#> 
#> $scale
#> [1] 1
#> 
#> $method
#> [1] "AlphaFold total loss decomposition"
#>