Views
No views yet
| entity | precision | recall | f1 |
|---|---|---|---|
| General | 0.9976 | 0.9980 | 0.9978 |
| Geoscience | 0.9980 | 0.9984 | 0.9982 |
1from transformers import AutoTokenizer, AutoModelForSequenceClassification
2
3tokenizer = AutoTokenizer.from_pretrained("botryan96/GeoBERT_analyzer")
4model = AutoModelForTokenClassification.from_pretrained("botryan96/GeoBERT_analyzer")
5
6#Define the pipeline
7from transformers import pipeline
8anlyze_machine=pipeline('text-classification',model = model_checkpoint2)
9
10#Define the sentences
11sentences = ['the average iron and sulfate concentrations were calculated to be 19 . 6 5 . 2 and 426 182 mg / l , respectively .',
12 'She first gained media attention as a friend and stylist of Paris Hilton']
13
14#Deploy the machine
15anlyze_machine(sentences)