Instructions to use skypro1111/mbart-large-50-verbalization with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use skypro1111/mbart-large-50-verbalization with Transformers:
# Load model directly from transformers import AutoTokenizer, AutoModelForSeq2SeqLM tokenizer = AutoTokenizer.from_pretrained("skypro1111/mbart-large-50-verbalization") model = AutoModelForSeq2SeqLM.from_pretrained("skypro1111/mbart-large-50-verbalization", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -89,7 +89,7 @@ device = "cuda" if torch.cuda.is_available() else "cpu"
|
|
| 89 |
|
| 90 |
model_name = "skypro1111/mbart-large-50-verbalization"
|
| 91 |
|
| 92 |
-
model =
|
| 93 |
model_name,
|
| 94 |
low_cpu_mem_usage=True,
|
| 95 |
device_map=device,
|
|
@@ -130,7 +130,7 @@ from huggingface_hub import hf_hub_download
|
|
| 130 |
model_name = "skypro1111/mbart-large-50-verbalization"
|
| 131 |
|
| 132 |
|
| 133 |
-
def download_model_from_hf(repo_id=model_name, model_dir="
|
| 134 |
"""Download ONNX models from HuggingFace Hub."""
|
| 135 |
os.makedirs(model_dir, exist_ok=True)
|
| 136 |
|
|
|
|
| 89 |
|
| 90 |
model_name = "skypro1111/mbart-large-50-verbalization"
|
| 91 |
|
| 92 |
+
model = MBartForConditionalGeneration.from_pretrained(
|
| 93 |
model_name,
|
| 94 |
low_cpu_mem_usage=True,
|
| 95 |
device_map=device,
|
|
|
|
| 130 |
model_name = "skypro1111/mbart-large-50-verbalization"
|
| 131 |
|
| 132 |
|
| 133 |
+
def download_model_from_hf(repo_id=model_name, model_dir="onnx"):
|
| 134 |
"""Download ONNX models from HuggingFace Hub."""
|
| 135 |
os.makedirs(model_dir, exist_ok=True)
|
| 136 |
|