wmt/wmt16
Viewer โข Updated โข 9.98M โข 7.94k โข 28
How to use umer77400/eng_to_rus_t5model with Transformers:
# Use a pipeline as a high-level helper
# Warning: Pipeline type "translation" is no longer supported in transformers v5.
# You must load the model directly (see below) or downgrade to v4.x with:
# pip install "transformers<5.0.0"
from transformers import pipeline
pipe = pipeline("translation", model="umer77400/eng_to_rus_t5model") # pip install -U transformers accelerate
# Load model directly
from transformers import AutoModel
model = AutoModel.from_pretrained("umer77400/eng_to_rus_t5model", device_map="auto")