Expand description
ESMFold2 pretrained model loading.
Downloads the structure-head weights from HuggingFace and optionally wires in the ESMC-6B backbone for end-to-end structure prediction.
§Weight layout
biohub/ESMFold2-Fast model.safetensors (~755 MB) contains the structure
head only. The ESMC-6B backbone (~12 GB) must be loaded from a second repo
(biohub/ESMC-6B).
| Weight prefix | Component |
|---|---|
lm_encoder.* | LM adapter (4 blocks, 2560 → d_single=384) |
folding_trunk.* | 24-layer Pairformer trunk |
inputs.atom_encoder.* | Atom encoder (3 blocks, d_atom=128→768) |
msa_encoder.* | MSA encoder (disabled in Fast) |
structure_head.* | Diffusion module (token 12-block + atom 3-block) |
confidence_head.* | pLDDT / pAE / pDE / distogram heads |
§Two loading modes
-
ESMFold2Runner::from_pretrained— structure head only (~755 MB). Backbone hidden states are zero-initialised; coordinates will be physically meaningless but all shapes are correct (useful for shape testing). -
ESMFold2Runner::from_pretrained_with_backbone— structure head + ESMC-6B backbone (~12 GB total). Required for real structure predictions.
Structs§
- ESMFold2
Runner - Wraps a loaded ESMFold2 model for all-atom structure prediction inference.
Enums§
- ESMFold2
Models - Available ESMFold2 model variants hosted on HuggingFace.