Instructions to use Synthyra/ESMplusplus_6B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Synthyra/ESMplusplus_6B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="Synthyra/ESMplusplus_6B", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForMaskedLM model = AutoModelForMaskedLM.from_pretrained("Synthyra/ESMplusplus_6B", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -1,11 +1,12 @@
|
|
| 1 |
---
|
| 2 |
library_name: transformers
|
|
|
|
| 3 |
tags:
|
| 4 |
-
- biology
|
| 5 |
-
- esm
|
| 6 |
-
- protein
|
| 7 |
-
- protein-language-model
|
| 8 |
-
- masked-language-modeling
|
| 9 |
---
|
| 10 |
|
| 11 |
# ESM++ 6B
|
|
@@ -13,6 +14,8 @@ tags:
|
|
| 13 |
[ESM++](https://github.com/Synthyra/FastPLMs) is a Hugging Face compatible implementation of [Biohub ESMC](https://biohub.ai/esm/protein) ([license](https://github.com/Biohub/esm/blob/main/LICENSE.md)).
|
| 14 |
This checkpoint corresponds to the 6 billion parameter ESMC model released as [`biohub/ESMC-6B`](https://huggingface.co/biohub/ESMC-6B).
|
| 15 |
|
|
|
|
|
|
|
| 16 |
The 6B model has 80 transformer layers, hidden size 2560, and 40 attention heads. It is large enough that `dtype=torch.bfloat16` or `torch.float16` plus `device_map="auto"` is usually the practical loading path.
|
| 17 |
|
| 18 |
## Attention Backends
|
|
@@ -93,7 +96,6 @@ embedding_dict = model.embed_dataset(
|
|
| 93 |
"MSEQWENCE",
|
| 94 |
"MPRTEIN",
|
| 95 |
],
|
| 96 |
-
tokenizer=model.tokenizer,
|
| 97 |
batch_size=1,
|
| 98 |
max_len=1024,
|
| 99 |
full_embeddings=False,
|
|
@@ -112,7 +114,6 @@ For residue-level embeddings, set `full_embeddings=True`:
|
|
| 112 |
```python
|
| 113 |
residue_embeddings = model.embed_dataset(
|
| 114 |
sequences=["MALWMRLLPLLALLALWGPDPAAA"],
|
| 115 |
-
tokenizer=model.tokenizer,
|
| 116 |
batch_size=1,
|
| 117 |
max_len=1024,
|
| 118 |
full_embeddings=True,
|
|
@@ -126,7 +127,6 @@ For very large datasets, write embeddings directly to SQLite:
|
|
| 126 |
```python
|
| 127 |
model.embed_dataset(
|
| 128 |
fasta_path="proteins.fasta",
|
| 129 |
-
tokenizer=model.tokenizer,
|
| 130 |
batch_size=1,
|
| 131 |
max_len=1024,
|
| 132 |
pooling_types=["mean"],
|
|
@@ -222,13 +222,14 @@ model = ESMplusplusForMaskedLM.from_pretrained_esm("esmc-6b")
|
|
| 222 |
```
|
| 223 |
|
| 224 |
The source repository is [`biohub/ESMC-6B`](https://huggingface.co/biohub/ESMC-6B).
|
|
|
|
| 225 |
|
| 226 |
## Citation
|
| 227 |
|
| 228 |
```bibtex
|
| 229 |
@misc{FastPLMs,
|
| 230 |
author={Hallee, Logan and Bichara, David and Gleghorn, Jason P.},
|
| 231 |
-
title={FastPLMs: Fast, efficient, protein language model inference from
|
| 232 |
year={2024},
|
| 233 |
url={https://huggingface.co/Synthyra/ESMplusplus_6B},
|
| 234 |
DOI={10.57967/hf/3726},
|
|
|
|
| 1 |
---
|
| 2 |
library_name: transformers
|
| 3 |
+
license: mit
|
| 4 |
tags:
|
| 5 |
+
- biology
|
| 6 |
+
- esm
|
| 7 |
+
- protein
|
| 8 |
+
- protein-language-model
|
| 9 |
+
- masked-language-modeling
|
| 10 |
---
|
| 11 |
|
| 12 |
# ESM++ 6B
|
|
|
|
| 14 |
[ESM++](https://github.com/Synthyra/FastPLMs) is a Hugging Face compatible implementation of [Biohub ESMC](https://biohub.ai/esm/protein) ([license](https://github.com/Biohub/esm/blob/main/LICENSE.md)).
|
| 15 |
This checkpoint corresponds to the 6 billion parameter ESMC model released as [`biohub/ESMC-6B`](https://huggingface.co/biohub/ESMC-6B).
|
| 16 |
|
| 17 |
+
This repository includes the Biohub ESM MIT license in `LICENSE`.
|
| 18 |
+
|
| 19 |
The 6B model has 80 transformer layers, hidden size 2560, and 40 attention heads. It is large enough that `dtype=torch.bfloat16` or `torch.float16` plus `device_map="auto"` is usually the practical loading path.
|
| 20 |
|
| 21 |
## Attention Backends
|
|
|
|
| 96 |
"MSEQWENCE",
|
| 97 |
"MPRTEIN",
|
| 98 |
],
|
|
|
|
| 99 |
batch_size=1,
|
| 100 |
max_len=1024,
|
| 101 |
full_embeddings=False,
|
|
|
|
| 114 |
```python
|
| 115 |
residue_embeddings = model.embed_dataset(
|
| 116 |
sequences=["MALWMRLLPLLALLALWGPDPAAA"],
|
|
|
|
| 117 |
batch_size=1,
|
| 118 |
max_len=1024,
|
| 119 |
full_embeddings=True,
|
|
|
|
| 127 |
```python
|
| 128 |
model.embed_dataset(
|
| 129 |
fasta_path="proteins.fasta",
|
|
|
|
| 130 |
batch_size=1,
|
| 131 |
max_len=1024,
|
| 132 |
pooling_types=["mean"],
|
|
|
|
| 222 |
```
|
| 223 |
|
| 224 |
The source repository is [`biohub/ESMC-6B`](https://huggingface.co/biohub/ESMC-6B).
|
| 225 |
+
The Biohub ESM license is available at https://github.com/Biohub/esm/blob/main/LICENSE.md.
|
| 226 |
|
| 227 |
## Citation
|
| 228 |
|
| 229 |
```bibtex
|
| 230 |
@misc{FastPLMs,
|
| 231 |
author={Hallee, Logan and Bichara, David and Gleghorn, Jason P.},
|
| 232 |
+
title={FastPLMs: Fast, efficient, protein language model inference from Hugging Face AutoModel.},
|
| 233 |
year={2024},
|
| 234 |
url={https://huggingface.co/Synthyra/ESMplusplus_6B},
|
| 235 |
DOI={10.57967/hf/3726},
|