ncbi/pubmed
Updated • 1.16k • 164
How to use ml4pubmed/scibert-scivocab-cased_pub_section with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-classification", model="ml4pubmed/scibert-scivocab-cased_pub_section") # Load model directly
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("ml4pubmed/scibert-scivocab-cased_pub_section")
model = AutoModelForSequenceClassification.from_pretrained("ml4pubmed/scibert-scivocab-cased_pub_section")allenai/scibert_scivocab_cased for document section text classificationdate_run: Apr-26-2022_t-13
huggingface_tag: allenai/scibert_scivocab_cased
test_set: [{'test_accuracy': 0.8313589096069336, 'test_matthewscorrcoef': 0.7736952900886536, 'test_f1score': 0.8317078948020935, 'test_cross_entropy': 0.5242752432823181}]
NUM_EPOCHS: 12
BATCH_SIZE: 32
MAX_INPUT_LENGTH: 256
TRAIN_FP16: True
TRAIN_STRATEGY: freeze
LR_SCHEDULE: reducelronplateau
LR_INITIAL: 0.001
WEIGHT_DECAY: 0.05
UNFREEZE_EPOCH: 4
hf_tag: allenai/scibert_scivocab_cased
lowercased_input: False
input_text_colname: description
target_cls_colname: target
num_classes: 5
model_shortname: scibert_scivocab_cased