Update README.md
Browse files
README.md
CHANGED
@@ -34,8 +34,8 @@ The easiest way is to load the inference api from huggingface and second method
|
|
34 |
from transformers import pipeline
|
35 |
from transformers import AutoTokenizer, AutoModelForTokenClassification
|
36 |
|
37 |
-
tokenizer = AutoTokenizer.from_pretrained("d4data/biomedical-all")
|
38 |
-
model = AutoModelForTokenClassification.from_pretrained("d4data/biomedical-all")
|
39 |
|
40 |
pipe = pipeline("ner", model=model, tokenizer=tokenizer, aggregation_strategy="simple") # pass device=0 if using gpu
|
41 |
pipe("""The patient reported no recurrence of palpitations at follow-up 6 months after the ablation.""")
|
|
|
34 |
from transformers import pipeline
|
35 |
from transformers import AutoTokenizer, AutoModelForTokenClassification
|
36 |
|
37 |
+
tokenizer = AutoTokenizer.from_pretrained("d4data/biomedical-ner-all")
|
38 |
+
model = AutoModelForTokenClassification.from_pretrained("d4data/biomedical-ner-all")
|
39 |
|
40 |
pipe = pipeline("ner", model=model, tokenizer=tokenizer, aggregation_strategy="simple") # pass device=0 if using gpu
|
41 |
pipe("""The patient reported no recurrence of palpitations at follow-up 6 months after the ablation.""")
|