End of training
Browse files- README.md +79 -0
- logs/events.out.tfevents.1700192196.7a4a5107f6a8.15988.0 +2 -2
- preprocessor_config.json +14 -0
- pytorch_model.bin +1 -1
- special_tokens_map.json +7 -0
- tokenizer.json +0 -0
- tokenizer_config.json +38 -0
- vocab.txt +0 -0
README.md
ADDED
@@ -0,0 +1,79 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- generated_from_trainer
|
4 |
+
datasets:
|
5 |
+
- sroie
|
6 |
+
model-index:
|
7 |
+
- name: layoutlm-sroie
|
8 |
+
results: []
|
9 |
+
---
|
10 |
+
|
11 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
12 |
+
should probably proofread and complete it, then remove this comment. -->
|
13 |
+
|
14 |
+
# layoutlm-sroie
|
15 |
+
|
16 |
+
This model is a fine-tuned version of [microsoft/layoutlm-base-uncased](https://huggingface.co/microsoft/layoutlm-base-uncased) on the sroie dataset.
|
17 |
+
It achieves the following results on the evaluation set:
|
18 |
+
- Loss: 0.0363
|
19 |
+
- Address: {'precision': 0.901685393258427, 'recall': 0.9250720461095101, 'f1': 0.9132290184921764, 'number': 347}
|
20 |
+
- Company: {'precision': 0.904891304347826, 'recall': 0.9596541786743515, 'f1': 0.9314685314685315, 'number': 347}
|
21 |
+
- Date: {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347}
|
22 |
+
- Total: {'precision': 0.8155080213903744, 'recall': 0.8789625360230547, 'f1': 0.8460471567267684, 'number': 347}
|
23 |
+
- Overall Precision: 0.9017
|
24 |
+
- Overall Recall: 0.9388
|
25 |
+
- Overall F1: 0.9199
|
26 |
+
- Overall Accuracy: 0.9930
|
27 |
+
|
28 |
+
## Model description
|
29 |
+
|
30 |
+
More information needed
|
31 |
+
|
32 |
+
## Intended uses & limitations
|
33 |
+
|
34 |
+
More information needed
|
35 |
+
|
36 |
+
## Training and evaluation data
|
37 |
+
|
38 |
+
More information needed
|
39 |
+
|
40 |
+
## Training procedure
|
41 |
+
|
42 |
+
### Training hyperparameters
|
43 |
+
|
44 |
+
The following hyperparameters were used during training:
|
45 |
+
- learning_rate: 3e-05
|
46 |
+
- train_batch_size: 16
|
47 |
+
- eval_batch_size: 8
|
48 |
+
- seed: 42
|
49 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
50 |
+
- lr_scheduler_type: linear
|
51 |
+
- num_epochs: 15
|
52 |
+
|
53 |
+
### Training results
|
54 |
+
|
55 |
+
| Training Loss | Epoch | Step | Validation Loss | Address | Company | Date | Total | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
|
56 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------------------------------------------------------------------------------------------------------:|:--------------------------------------------------------------------------------------------------------:|:--------------------------------------------------------------------------------------------------------:|:---------------------------------------------------------------------------------------------------------:|:-----------------:|:--------------:|:----------:|:----------------:|
|
57 |
+
| 0.5189 | 1.0 | 40 | 0.1280 | {'precision': 0.7891891891891892, 'recall': 0.8414985590778098, 'f1': 0.8145048814504882, 'number': 347} | {'precision': 0.6987012987012987, 'recall': 0.7752161383285303, 'f1': 0.7349726775956286, 'number': 347} | {'precision': 0.6651982378854625, 'recall': 0.8703170028818443, 'f1': 0.7540574282147315, 'number': 347} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 347} | 0.7138 | 0.6218 | 0.6646 | 0.9650 |
|
58 |
+
| 0.0849 | 2.0 | 80 | 0.0558 | {'precision': 0.8753462603878116, 'recall': 0.9106628242074928, 'f1': 0.8926553672316384, 'number': 347} | {'precision': 0.8102189781021898, 'recall': 0.9596541786743515, 'f1': 0.8786279683377309, 'number': 347} | {'precision': 0.9178082191780822, 'recall': 0.9654178674351584, 'f1': 0.9410112359550562, 'number': 347} | {'precision': 0.5179282868525896, 'recall': 0.3746397694524496, 'f1': 0.43478260869565216, 'number': 347} | 0.8026 | 0.8026 | 0.8026 | 0.9851 |
|
59 |
+
| 0.0447 | 3.0 | 120 | 0.0435 | {'precision': 0.8997214484679665, 'recall': 0.930835734870317, 'f1': 0.9150141643059491, 'number': 347} | {'precision': 0.8954423592493298, 'recall': 0.962536023054755, 'f1': 0.9277777777777777, 'number': 347} | {'precision': 0.96045197740113, 'recall': 0.9798270893371758, 'f1': 0.9700427960057061, 'number': 347} | {'precision': 0.6222222222222222, 'recall': 0.6455331412103746, 'f1': 0.6336633663366337, 'number': 347} | 0.8444 | 0.8797 | 0.8617 | 0.9890 |
|
60 |
+
| 0.0318 | 4.0 | 160 | 0.0347 | {'precision': 0.8777777777777778, 'recall': 0.9106628242074928, 'f1': 0.8939179632248939, 'number': 347} | {'precision': 0.9153005464480874, 'recall': 0.9654178674351584, 'f1': 0.9396914446002805, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.671957671957672, 'recall': 0.7319884726224783, 'f1': 0.7006896551724137, 'number': 347} | 0.8608 | 0.8999 | 0.8799 | 0.9910 |
|
61 |
+
| 0.0245 | 5.0 | 200 | 0.0360 | {'precision': 0.8885793871866295, 'recall': 0.9193083573487032, 'f1': 0.9036827195467422, 'number': 347} | {'precision': 0.8909574468085106, 'recall': 0.9654178674351584, 'f1': 0.9266943291839556, 'number': 347} | {'precision': 0.9913294797687862, 'recall': 0.9884726224783862, 'f1': 0.98989898989899, 'number': 347} | {'precision': 0.7873754152823921, 'recall': 0.6829971181556196, 'f1': 0.7314814814814815, 'number': 347} | 0.8929 | 0.8890 | 0.8910 | 0.9910 |
|
62 |
+
| 0.0171 | 6.0 | 240 | 0.0325 | {'precision': 0.8932584269662921, 'recall': 0.9164265129682997, 'f1': 0.9046941678520626, 'number': 347} | {'precision': 0.912568306010929, 'recall': 0.962536023054755, 'f1': 0.9368863955119215, 'number': 347} | {'precision': 0.991304347826087, 'recall': 0.9855907780979827, 'f1': 0.9884393063583815, 'number': 347} | {'precision': 0.823170731707317, 'recall': 0.7780979827089337, 'f1': 0.8, 'number': 347} | 0.9061 | 0.9107 | 0.9084 | 0.9926 |
|
63 |
+
| 0.0133 | 7.0 | 280 | 0.0352 | {'precision': 0.8969359331476323, 'recall': 0.9279538904899135, 'f1': 0.9121813031161472, 'number': 347} | {'precision': 0.9103260869565217, 'recall': 0.9654178674351584, 'f1': 0.937062937062937, 'number': 347} | {'precision': 0.9885057471264368, 'recall': 0.9913544668587896, 'f1': 0.9899280575539569, 'number': 347} | {'precision': 0.7801608579088471, 'recall': 0.8386167146974063, 'f1': 0.8083333333333332, 'number': 347} | 0.8923 | 0.9308 | 0.9111 | 0.9922 |
|
64 |
+
| 0.013 | 8.0 | 320 | 0.0338 | {'precision': 0.889196675900277, 'recall': 0.9250720461095101, 'f1': 0.9067796610169492, 'number': 347} | {'precision': 0.9103260869565217, 'recall': 0.9654178674351584, 'f1': 0.937062937062937, 'number': 347} | {'precision': 0.9885057471264368, 'recall': 0.9913544668587896, 'f1': 0.9899280575539569, 'number': 347} | {'precision': 0.7887700534759359, 'recall': 0.8501440922190202, 'f1': 0.8183079056865465, 'number': 347} | 0.8925 | 0.9330 | 0.9123 | 0.9927 |
|
65 |
+
| 0.0105 | 9.0 | 360 | 0.0378 | {'precision': 0.8885793871866295, 'recall': 0.9193083573487032, 'f1': 0.9036827195467422, 'number': 347} | {'precision': 0.9081081081081082, 'recall': 0.968299711815562, 'f1': 0.9372384937238494, 'number': 347} | {'precision': 0.9913294797687862, 'recall': 0.9884726224783862, 'f1': 0.98989898989899, 'number': 347} | {'precision': 0.8096590909090909, 'recall': 0.8213256484149856, 'f1': 0.8154506437768241, 'number': 347} | 0.8991 | 0.9244 | 0.9115 | 0.9923 |
|
66 |
+
| 0.0094 | 10.0 | 400 | 0.0353 | {'precision': 0.901685393258427, 'recall': 0.9250720461095101, 'f1': 0.9132290184921764, 'number': 347} | {'precision': 0.904891304347826, 'recall': 0.9596541786743515, 'f1': 0.9314685314685315, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.8142076502732241, 'recall': 0.8587896253602305, 'f1': 0.8359046283309958, 'number': 347} | 0.9019 | 0.9337 | 0.9175 | 0.9929 |
|
67 |
+
| 0.0078 | 11.0 | 440 | 0.0373 | {'precision': 0.8938547486033519, 'recall': 0.9221902017291066, 'f1': 0.9078014184397163, 'number': 347} | {'precision': 0.9098360655737705, 'recall': 0.9596541786743515, 'f1': 0.9340813464235624, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.8150134048257373, 'recall': 0.8760806916426513, 'f1': 0.8444444444444444, 'number': 347} | 0.9010 | 0.9373 | 0.9188 | 0.9928 |
|
68 |
+
| 0.0074 | 12.0 | 480 | 0.0379 | {'precision': 0.8994413407821229, 'recall': 0.9279538904899135, 'f1': 0.9134751773049646, 'number': 347} | {'precision': 0.9128065395095368, 'recall': 0.9654178674351584, 'f1': 0.938375350140056, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.835195530726257, 'recall': 0.861671469740634, 'f1': 0.8482269503546098, 'number': 347} | 0.9091 | 0.9366 | 0.9226 | 0.9931 |
|
69 |
+
| 0.007 | 13.0 | 520 | 0.0357 | {'precision': 0.9019607843137255, 'recall': 0.9279538904899135, 'f1': 0.9147727272727272, 'number': 347} | {'precision': 0.9024390243902439, 'recall': 0.9596541786743515, 'f1': 0.9301675977653631, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.8328767123287671, 'recall': 0.8760806916426513, 'f1': 0.853932584269663, 'number': 347} | 0.9061 | 0.9388 | 0.9222 | 0.9932 |
|
70 |
+
| 0.0069 | 14.0 | 560 | 0.0361 | {'precision': 0.901685393258427, 'recall': 0.9250720461095101, 'f1': 0.9132290184921764, 'number': 347} | {'precision': 0.9051490514905149, 'recall': 0.962536023054755, 'f1': 0.9329608938547486, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.8046875, 'recall': 0.8904899135446686, 'f1': 0.8454172366621068, 'number': 347} | 0.8984 | 0.9424 | 0.9198 | 0.9930 |
|
71 |
+
| 0.0065 | 15.0 | 600 | 0.0363 | {'precision': 0.901685393258427, 'recall': 0.9250720461095101, 'f1': 0.9132290184921764, 'number': 347} | {'precision': 0.904891304347826, 'recall': 0.9596541786743515, 'f1': 0.9314685314685315, 'number': 347} | {'precision': 0.9913544668587896, 'recall': 0.9913544668587896, 'f1': 0.9913544668587896, 'number': 347} | {'precision': 0.8155080213903744, 'recall': 0.8789625360230547, 'f1': 0.8460471567267684, 'number': 347} | 0.9017 | 0.9388 | 0.9199 | 0.9930 |
|
72 |
+
|
73 |
+
|
74 |
+
### Framework versions
|
75 |
+
|
76 |
+
- Transformers 4.28.0
|
77 |
+
- Pytorch 2.1.0+cu118
|
78 |
+
- Datasets 2.15.0
|
79 |
+
- Tokenizers 0.12.1
|
logs/events.out.tfevents.1700192196.7a4a5107f6a8.15988.0
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:376953f1ffa90eda3ae3bae9543fb71d4c32112a67af87547d75c884299d5d73
|
3 |
+
size 14545
|
preprocessor_config.json
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"apply_ocr": true,
|
3 |
+
"do_resize": true,
|
4 |
+
"feature_extractor_type": "LayoutLMv2FeatureExtractor",
|
5 |
+
"image_processor_type": "LayoutLMv2ImageProcessor",
|
6 |
+
"ocr_lang": null,
|
7 |
+
"processor_class": "LayoutLMv2Processor",
|
8 |
+
"resample": 2,
|
9 |
+
"size": {
|
10 |
+
"height": 224,
|
11 |
+
"width": 224
|
12 |
+
},
|
13 |
+
"tesseract_config": ""
|
14 |
+
}
|
pytorch_model.bin
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 450614978
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ff51b7c417709f681127431bbe434d73320d82add8d2cebd4d17024cb075194d
|
3 |
size 450614978
|
special_tokens_map.json
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": "[CLS]",
|
3 |
+
"mask_token": "[MASK]",
|
4 |
+
"pad_token": "[PAD]",
|
5 |
+
"sep_token": "[SEP]",
|
6 |
+
"unk_token": "[UNK]"
|
7 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"additional_special_tokens": null,
|
3 |
+
"apply_ocr": false,
|
4 |
+
"clean_up_tokenization_spaces": true,
|
5 |
+
"cls_token": "[CLS]",
|
6 |
+
"cls_token_box": [
|
7 |
+
0,
|
8 |
+
0,
|
9 |
+
0,
|
10 |
+
0
|
11 |
+
],
|
12 |
+
"do_basic_tokenize": true,
|
13 |
+
"do_lower_case": true,
|
14 |
+
"mask_token": "[MASK]",
|
15 |
+
"model_max_length": 512,
|
16 |
+
"never_split": null,
|
17 |
+
"only_label_first_subword": true,
|
18 |
+
"pad_token": "[PAD]",
|
19 |
+
"pad_token_box": [
|
20 |
+
0,
|
21 |
+
0,
|
22 |
+
0,
|
23 |
+
0
|
24 |
+
],
|
25 |
+
"pad_token_label": -100,
|
26 |
+
"processor_class": "LayoutLMv2Processor",
|
27 |
+
"sep_token": "[SEP]",
|
28 |
+
"sep_token_box": [
|
29 |
+
1000,
|
30 |
+
1000,
|
31 |
+
1000,
|
32 |
+
1000
|
33 |
+
],
|
34 |
+
"strip_accents": null,
|
35 |
+
"tokenize_chinese_chars": true,
|
36 |
+
"tokenizer_class": "LayoutLMv2Tokenizer",
|
37 |
+
"unk_token": "[UNK]"
|
38 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|