Instructions to use Synthyra/Boltz2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Synthyra/Boltz2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="Synthyra/Boltz2", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Synthyra/Boltz2", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
| from dataclasses import dataclass | |
| from typing import List | |
| class ProteinStructureTemplate: | |
| sequence: str | |
| residue_names: List[str] | |
| atom_names: List[str] | |
| atom_elements: List[str] | |
| atom_residue_index: List[int] | |
| atom_chain_id: List[str] | |
| def num_atoms(self) -> int: | |
| return len(self.atom_names) | |
| def num_residues(self) -> int: | |
| return len(self.residue_names) | |