Tasks
Tasks map sampler indices to model inputs and supervision targets. Summaries below are taken from each class docstring.
Predict amino-acid sequences from backbone structure.
- class bioverse.tasks.inverse_folding.InverseFoldingTask(resolution='residue')[source]
Bases:
TaskPredict amino-acid sequences from backbone structure.
Mask protein pocket residues and predict their amino-acid identities.
- class bioverse.tasks.masked_pocket_prediction.MaskedPocketPredictionTask(radius=8.0, hide_peptide=False, peptide_type='peptide')[source]
Bases:
TaskMask protein pocket residues and predict their amino-acid identities.
The pocket is every protein residue whose Cα is within
radiusÅ of any peptide Cα. Peptide letters are optional context: sethide_peptideto replace them with the masking token after the targets are extracted.
Predict masked residue identities or properties.
- class bioverse.tasks.masked_residue_prediction.MaskedResiduePredictionTask[source]
Bases:
TaskPredict masked residue identities or properties.
Predict the effect of amino-acid mutations.
- class bioverse.tasks.mutation_effect_prediction.MutationEffectPredictionTask(resolution='residue', mutate_structure=True)[source]
Bases:
TaskPredict the effect of amino-acid mutations.
mutate_structure=Truewrites the mutant residue intoX(ProteinGym fitness / inverse-folding).Falseleaves the wild-type graph and only recordsposition/wt/mutonyso the model can splice one-hot features and re-encode, matching Huber eval.
Predict a property for pairs of molecules.
- class bioverse.tasks.pairwise_property_prediction.PairwisePropertyPredictionTask(meta: str, id_field: str = 'id', level: str = 'molecule', target: str | None = None, resolution: str = 'residue')[source]
Bases:
TaskPredict a property for pairs of molecules.
Predict which protein residues contact a bound peptide.
- class bioverse.tasks.pocket_contact_prediction.PocketContactPredictionTask(radius=8.0, peptide_type='peptide', drop_peptide=True)[source]
Bases:
TaskPredict which protein residues contact a bound peptide.
Labels come from Cα distance to the peptide (
AnnotatePocketContacts) or are computed here. The peptide is dropped fromXso the encoder matches MEROPS (receptor only).y["target"]is a 0/1 contact per remaining residue;y["distance"]is the nearest peptide Cα distance.
Predict a scalar or vector property at a chosen hierarchy level.
- class bioverse.tasks.property_prediction.PropertyPredictionTask(property='label', level='molecule', resolution='atom')[source]
Bases:
TaskPredict a scalar or vector property at a chosen hierarchy level.
Loads a molecule (or sub-molecule level) from the indexed batch and extracts
{level}_{property}as the supervision target. Setresolutionto control which atoms/residues are exposed as features.- Parameters:
property (str or tuple) – Target column name, or
(name, index)to select one element of a vector-valued property.level (str) – Hierarchy level of the target (
"molecule","residue", etc.).resolution (str) – Feature resolution passed to the returned batch (
"atom"or"residue").
Keep the wild-type fold and emit mutation + P6–P4′ fields.
- class bioverse.tasks.protease_mutation_delta.ProteaseMutationDeltaTask(resolution='residue', window_len: int = 10)[source]
Bases:
TaskKeep the wild-type fold and emit mutation + P6–P4′ fields.
The geometric model scores
f(P_mut, S) - f(P_WT, S)against the synthetic (or measured)Δactivitystored inmolecule_mutation_effect. Coordinates stay wild-type; mutant identity is spliced at train time.
Return a protease fold and a tokenized P6–P4′ substrate window.
- class bioverse.tasks.protease_substrate_compatibility.ProteaseSubstrateCompatibilityTask(resolution='residue', window_len: int = 10)[source]
Bases:
TaskReturn a protease fold and a tokenized P6–P4′ substrate window.
Protease point mutations from
molecule_mutation_*are applied to residue identity (coordinates stay wild-type). The paired substrate window is written toy["substrate"]as integer tokens so a two-tower model can scoref(P, S).
Score ligand-target pairs for virtual screening.