unimelb-nlp/wikiann
Viewer • Updated • 2M • 43.8k • 121
How to use mschiesser/ner-bert-german with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("token-classification", model="mschiesser/ner-bert-german") # Load model directly
from transformers import AutoTokenizer, AutoModelForTokenClassification
tokenizer = AutoTokenizer.from_pretrained("mschiesser/ner-bert-german")
model = AutoModelForTokenClassification.from_pretrained("mschiesser/ner-bert-german")# Load model directly
from transformers import AutoTokenizer, AutoModelForTokenClassification
tokenizer = AutoTokenizer.from_pretrained("mschiesser/ner-bert-german")
model = AutoModelForTokenClassification.from_pretrained("mschiesser/ner-bert-german")This model can be used to do named-entity recognition in German. It is trained on a fine-tuned version of bert-base-multilingual-cased on the German wikiann dataset.
It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy | Loc F1 | Org F1 | Per F1 |
|---|---|---|---|---|---|---|---|---|---|---|
| 0.252 | 0.8 | 1000 | 0.1724 | 0.8422 | 0.8368 | 0.8395 | 0.9501 | 0.8702 | 0.7593 | 0.8921 |
| 0.1376 | 1.6 | 2000 | 0.1679 | 0.8388 | 0.8607 | 0.8497 | 0.9528 | 0.8814 | 0.7712 | 0.8971 |
| 0.0982 | 2.4 | 3000 | 0.1880 | 0.8631 | 0.8598 | 0.8614 | 0.9564 | 0.8847 | 0.7915 | 0.9070 |
| 0.0681 | 3.2 | 4000 | 0.1956 | 0.8599 | 0.8775 | 0.8686 | 0.9574 | 0.8905 | 0.8084 | 0.9097 |
| 0.0477 | 4.0 | 5000 | 0.2115 | 0.8738 | 0.8814 | 0.8776 | 0.9593 | 0.9003 | 0.8207 | 0.9144 |
| 0.031 | 4.8 | 6000 | 0.2274 | 0.8751 | 0.8826 | 0.8788 | 0.9598 | 0.9017 | 0.8246 | 0.9115 |
| 0.0229 | 5.6 | 7000 | 0.2317 | 0.8715 | 0.8888 | 0.8801 | 0.9598 | 0.9061 | 0.8208 | 0.9145 |
| 0.0181 | 6.4 | 8000 | 0.2450 | 0.8767 | 0.8893 | 0.8829 | 0.9606 | 0.9067 | 0.8278 | 0.9152 |
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="mschiesser/ner-bert-german")