Instructions to use jkefeli/CancerStage_Classifier_T with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jkefeli/CancerStage_Classifier_T with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="jkefeli/CancerStage_Classifier_T")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("jkefeli/CancerStage_Classifier_T") model = AutoModelForSequenceClassification.from_pretrained("jkefeli/CancerStage_Classifier_T", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 299 Bytes
6cf7502 45602a9 77c86f8 2b622e6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | To use the model, add the following from the transformers package:
(1) Tokenizer:
tokenizer = AutoTokenizer.from_pretrained("yikuan8/Clinical-BigBird")
(2) Model type:
#T in [1,2,3,4]
num_classes = 4
model = BigBirdForSequenceClassification.from_pretrained(directory, num_labels=num_classes) |