End of training
Browse files- README.md +79 -0
- logs/events.out.tfevents.1690466940.fcb3ea2dcf27.4909.0 +2 -2
- preprocessor_config.json +14 -0
- 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 |
+
base_model: microsoft/layoutlm-base-uncased
|
3 |
+
tags:
|
4 |
+
- generated_from_trainer
|
5 |
+
datasets:
|
6 |
+
- funsd
|
7 |
+
model-index:
|
8 |
+
- name: layoutlm-funsd
|
9 |
+
results: []
|
10 |
+
---
|
11 |
+
|
12 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
13 |
+
should probably proofread and complete it, then remove this comment. -->
|
14 |
+
|
15 |
+
# layoutlm-funsd
|
16 |
+
|
17 |
+
This model is a fine-tuned version of [microsoft/layoutlm-base-uncased](https://huggingface.co/microsoft/layoutlm-base-uncased) on the funsd dataset.
|
18 |
+
It achieves the following results on the evaluation set:
|
19 |
+
- Loss: 1.3725
|
20 |
+
- Answer: {'precision': 0.07982261640798226, 'recall': 0.08899876390605686, 'f1': 0.0841613091759205, 'number': 809}
|
21 |
+
- Header: {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119}
|
22 |
+
- Question: {'precision': 0.4174242424242424, 'recall': 0.5173708920187794, 'f1': 0.46205450733752623, 'number': 1065}
|
23 |
+
- Overall Precision: 0.2804
|
24 |
+
- Overall Recall: 0.3126
|
25 |
+
- Overall F1: 0.2956
|
26 |
+
- Overall Accuracy: 0.5437
|
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: 5e-06
|
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 | Answer | Header | Question | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
|
56 |
+
|:-------------:|:-----:|:----:|:---------------:|:---------------------------------------------------------------------------------------------------------------:|:-----------------------------------------------------------:|:-------------------------------------------------------------------------------------------------------------:|:-----------------:|:--------------:|:----------:|:----------------:|
|
57 |
+
| 1.8773 | 1.0 | 10 | 1.8489 | {'precision': 0.00547645125958379, 'recall': 0.006180469715698393, 'f1': 0.005807200929152149, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.04874446085672083, 'recall': 0.030985915492957747, 'f1': 0.03788748564867968, 'number': 1065} | 0.0227 | 0.0191 | 0.0207 | 0.2819 |
|
58 |
+
| 1.807 | 2.0 | 20 | 1.7831 | {'precision': 0.005925925925925926, 'recall': 0.004944375772558714, 'f1': 0.005390835579514824, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.06716417910447761, 'recall': 0.03380281690140845, 'f1': 0.04497189256714553, 'number': 1065} | 0.0327 | 0.0201 | 0.0249 | 0.2996 |
|
59 |
+
| 1.7516 | 3.0 | 30 | 1.7272 | {'precision': 0.0071633237822349575, 'recall': 0.006180469715698393, 'f1': 0.006635700066357001, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.10175438596491228, 'recall': 0.054460093896713614, 'f1': 0.0709480122324159, 'number': 1065} | 0.0496 | 0.0316 | 0.0386 | 0.3189 |
|
60 |
+
| 1.7057 | 4.0 | 40 | 1.6785 | {'precision': 0.012626262626262626, 'recall': 0.012360939431396786, 'f1': 0.012492192379762648, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.16886930983847284, 'recall': 0.107981220657277, 'f1': 0.13172966781214204, 'number': 1065} | 0.0849 | 0.0627 | 0.0721 | 0.3426 |
|
61 |
+
| 1.6571 | 5.0 | 50 | 1.6336 | {'precision': 0.016286644951140065, 'recall': 0.018541409147095178, 'f1': 0.017341040462427744, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.2211764705882353, 'recall': 0.17652582159624414, 'f1': 0.19634464751958225, 'number': 1065} | 0.1146 | 0.1019 | 0.1079 | 0.3714 |
|
62 |
+
| 1.6219 | 6.0 | 60 | 1.5894 | {'precision': 0.03238095238095238, 'recall': 0.042027194066749075, 'f1': 0.036578805809575045, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.26129666011787817, 'recall': 0.24976525821596243, 'f1': 0.2554008641382621, 'number': 1065} | 0.1451 | 0.1505 | 0.1477 | 0.4028 |
|
63 |
+
| 1.5748 | 7.0 | 70 | 1.5484 | {'precision': 0.03796296296296296, 'recall': 0.05067985166872682, 'f1': 0.04340921122286924, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.28073394495412846, 'recall': 0.28732394366197184, 'f1': 0.28399071925754066, 'number': 1065} | 0.1599 | 0.1741 | 0.1667 | 0.4319 |
|
64 |
+
| 1.5387 | 8.0 | 80 | 1.5098 | {'precision': 0.044036697247706424, 'recall': 0.059332509270704575, 'f1': 0.05055292259083728, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.30583333333333335, 'recall': 0.34460093896713617, 'f1': 0.3240618101545254, 'number': 1065} | 0.1812 | 0.2082 | 0.1938 | 0.4623 |
|
65 |
+
| 1.5004 | 9.0 | 90 | 1.4753 | {'precision': 0.05149812734082397, 'recall': 0.06798516687268233, 'f1': 0.05860415556739478, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.3378812199036918, 'recall': 0.39530516431924884, 'f1': 0.36434443963652097, 'number': 1065} | 0.2057 | 0.2388 | 0.2210 | 0.4887 |
|
66 |
+
| 1.4659 | 10.0 | 100 | 1.4462 | {'precision': 0.058823529411764705, 'recall': 0.0754017305315204, 'f1': 0.06608884073672806, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.3586530931871574, 'recall': 0.4300469483568075, 'f1': 0.39111870196413323, 'number': 1065} | 0.2243 | 0.2604 | 0.2410 | 0.5046 |
|
67 |
+
| 1.4314 | 11.0 | 110 | 1.4207 | {'precision': 0.06769230769230769, 'recall': 0.0815822002472188, 'f1': 0.07399103139013452, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.38271604938271603, 'recall': 0.46572769953051646, 'f1': 0.42016094875052945, 'number': 1065} | 0.2475 | 0.2820 | 0.2636 | 0.5184 |
|
68 |
+
| 1.4242 | 12.0 | 120 | 1.4003 | {'precision': 0.07203389830508475, 'recall': 0.08405438813349815, 'f1': 0.0775812892184826, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.40076628352490423, 'recall': 0.49107981220657276, 'f1': 0.4413502109704641, 'number': 1065} | 0.2628 | 0.2965 | 0.2786 | 0.5273 |
|
69 |
+
| 1.3939 | 13.0 | 130 | 1.3855 | {'precision': 0.07792207792207792, 'recall': 0.08899876390605686, 'f1': 0.0830929024812464, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.40953822861468586, 'recall': 0.507981220657277, 'f1': 0.45347862531433364, 'number': 1065} | 0.2731 | 0.3076 | 0.2893 | 0.5367 |
|
70 |
+
| 1.3837 | 14.0 | 140 | 1.3764 | {'precision': 0.08021978021978023, 'recall': 0.09023485784919653, 'f1': 0.08493310063990692, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.41635124905374715, 'recall': 0.5164319248826291, 'f1': 0.4610226320201173, 'number': 1065} | 0.2792 | 0.3126 | 0.2950 | 0.5410 |
|
71 |
+
| 1.3603 | 15.0 | 150 | 1.3725 | {'precision': 0.07982261640798226, 'recall': 0.08899876390605686, 'f1': 0.0841613091759205, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.4174242424242424, 'recall': 0.5173708920187794, 'f1': 0.46205450733752623, 'number': 1065} | 0.2804 | 0.3126 | 0.2956 | 0.5437 |
|
72 |
+
|
73 |
+
|
74 |
+
### Framework versions
|
75 |
+
|
76 |
+
- Transformers 4.31.0
|
77 |
+
- Pytorch 2.0.1+cu118
|
78 |
+
- Datasets 2.14.0
|
79 |
+
- Tokenizers 0.13.3
|
logs/events.out.tfevents.1690466940.fcb3ea2dcf27.4909.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:18fe7c613086565240243c0d46ee1c6f84bd3d4c32e87dc543f002f2bf1bc2f7
|
3 |
+
size 14426
|
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 |
+
}
|
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
|
|