chizhikchi/CARES
Viewer • Updated • 3.22k • 13 • 4
How to use chizhikchi/cares-roberta-clinical with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-classification", model="chizhikchi/cares-roberta-clinical") # Load model directly
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("chizhikchi/cares-roberta-clinical")
model = AutoModelForSequenceClassification.from_pretrained("chizhikchi/cares-roberta-clinical", device_map="auto")