End of training
Browse files- README.md +80 -0
- logs/events.out.tfevents.1710936414.FM-PC-LT-280.6887.0 +2 -2
- model.safetensors +1 -1
- preprocessor_config.json +13 -0
- special_tokens_map.json +37 -0
- tokenizer.json +0 -0
- tokenizer_config.json +80 -0
- vocab.txt +0 -0
README.md
ADDED
@@ -0,0 +1,80 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: mit
|
3 |
+
base_model: microsoft/layoutlm-base-uncased
|
4 |
+
tags:
|
5 |
+
- generated_from_trainer
|
6 |
+
datasets:
|
7 |
+
- funsd
|
8 |
+
model-index:
|
9 |
+
- name: layoutlm-funsd
|
10 |
+
results: []
|
11 |
+
---
|
12 |
+
|
13 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
14 |
+
should probably proofread and complete it, then remove this comment. -->
|
15 |
+
|
16 |
+
# layoutlm-funsd
|
17 |
+
|
18 |
+
This model is a fine-tuned version of [microsoft/layoutlm-base-uncased](https://huggingface.co/microsoft/layoutlm-base-uncased) on the funsd dataset.
|
19 |
+
It achieves the following results on the evaluation set:
|
20 |
+
- Loss: 1.2144
|
21 |
+
- Answer: {'precision': 0.46146146146146144, 'recall': 0.5698393077873919, 'f1': 0.5099557522123893, 'number': 809}
|
22 |
+
- Header: {'precision': 0.4024390243902439, 'recall': 0.2773109243697479, 'f1': 0.3283582089552239, 'number': 119}
|
23 |
+
- Question: {'precision': 0.5888412017167381, 'recall': 0.644131455399061, 'f1': 0.6152466367713004, 'number': 1065}
|
24 |
+
- Overall Precision: 0.5254
|
25 |
+
- Overall Recall: 0.5921
|
26 |
+
- Overall F1: 0.5567
|
27 |
+
- Overall Accuracy: 0.6483
|
28 |
+
|
29 |
+
## Model description
|
30 |
+
|
31 |
+
More information needed
|
32 |
+
|
33 |
+
## Intended uses & limitations
|
34 |
+
|
35 |
+
More information needed
|
36 |
+
|
37 |
+
## Training and evaluation data
|
38 |
+
|
39 |
+
More information needed
|
40 |
+
|
41 |
+
## Training procedure
|
42 |
+
|
43 |
+
### Training hyperparameters
|
44 |
+
|
45 |
+
The following hyperparameters were used during training:
|
46 |
+
- learning_rate: 3e-05
|
47 |
+
- train_batch_size: 4
|
48 |
+
- eval_batch_size: 2
|
49 |
+
- seed: 42
|
50 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
51 |
+
- lr_scheduler_type: linear
|
52 |
+
- num_epochs: 15
|
53 |
+
|
54 |
+
### Training results
|
55 |
+
|
56 |
+
| Training Loss | Epoch | Step | Validation Loss | Answer | Header | Question | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
|
57 |
+
|:-------------:|:-----:|:----:|:---------------:|:----------------------------------------------------------------------------------------------------------:|:----------------------------------------------------------------------------------------------------------:|:-----------------------------------------------------------------------------------------------------------:|:-----------------:|:--------------:|:----------:|:----------------:|
|
58 |
+
| 1.5615 | 1.0 | 38 | 1.2309 | {'precision': 0.23910171730515192, 'recall': 0.44746600741656367, 'f1': 0.311665949203616, 'number': 809} | {'precision': 0.2830188679245283, 'recall': 0.12605042016806722, 'f1': 0.1744186046511628, 'number': 119} | {'precision': 0.35969209237228833, 'recall': 0.48262910798122066, 'f1': 0.4121892542101042, 'number': 1065} | 0.2974 | 0.4471 | 0.3572 | 0.4649 |
|
59 |
+
| 1.1729 | 2.0 | 76 | 1.0880 | {'precision': 0.3109656301145663, 'recall': 0.46971569839307786, 'f1': 0.37419990152634175, 'number': 809} | {'precision': 0.423728813559322, 'recall': 0.21008403361344538, 'f1': 0.2808988764044944, 'number': 119} | {'precision': 0.507488986784141, 'recall': 0.5408450704225352, 'f1': 0.5236363636363637, 'number': 1065} | 0.4060 | 0.4922 | 0.4450 | 0.5557 |
|
60 |
+
| 1.0126 | 3.0 | 114 | 1.0622 | {'precision': 0.31921110299488675, 'recall': 0.5401730531520396, 'f1': 0.40128558310376494, 'number': 809} | {'precision': 0.38372093023255816, 'recall': 0.2773109243697479, 'f1': 0.32195121951219513, 'number': 119} | {'precision': 0.4930662557781202, 'recall': 0.6009389671361502, 'f1': 0.5416842996191282, 'number': 1065} | 0.4032 | 0.5569 | 0.4678 | 0.5662 |
|
61 |
+
| 0.9042 | 4.0 | 152 | 1.0144 | {'precision': 0.3859060402684564, 'recall': 0.5686032138442522, 'f1': 0.45977011494252873, 'number': 809} | {'precision': 0.312, 'recall': 0.3277310924369748, 'f1': 0.31967213114754095, 'number': 119} | {'precision': 0.542713567839196, 'recall': 0.6084507042253521, 'f1': 0.5737051792828685, 'number': 1065} | 0.4568 | 0.5755 | 0.5093 | 0.6204 |
|
62 |
+
| 0.7609 | 5.0 | 190 | 1.0307 | {'precision': 0.41357466063348414, 'recall': 0.5648949320148331, 'f1': 0.47753396029258094, 'number': 809} | {'precision': 0.3373493975903614, 'recall': 0.23529411764705882, 'f1': 0.2772277227722772, 'number': 119} | {'precision': 0.5755711775043937, 'recall': 0.6150234741784038, 'f1': 0.5946436677258284, 'number': 1065} | 0.4901 | 0.5720 | 0.5279 | 0.6340 |
|
63 |
+
| 0.6792 | 6.0 | 228 | 1.0643 | {'precision': 0.43541102077687444, 'recall': 0.595797280593325, 'f1': 0.5031315240083507, 'number': 809} | {'precision': 0.4142857142857143, 'recall': 0.24369747899159663, 'f1': 0.3068783068783069, 'number': 119} | {'precision': 0.5757575757575758, 'recall': 0.6065727699530516, 'f1': 0.5907636031092821, 'number': 1065} | 0.5033 | 0.5805 | 0.5391 | 0.6180 |
|
64 |
+
| 0.6081 | 7.0 | 266 | 1.0222 | {'precision': 0.4691780821917808, 'recall': 0.5080346106304079, 'f1': 0.4878338278931751, 'number': 809} | {'precision': 0.26618705035971224, 'recall': 0.31092436974789917, 'f1': 0.2868217054263566, 'number': 119} | {'precision': 0.5478056426332288, 'recall': 0.6563380281690141, 'f1': 0.5971806920119608, 'number': 1065} | 0.5007 | 0.5755 | 0.5355 | 0.6424 |
|
65 |
+
| 0.5218 | 8.0 | 304 | 1.0641 | {'precision': 0.42940038684719534, 'recall': 0.5488257107540173, 'f1': 0.481823114487249, 'number': 809} | {'precision': 0.3409090909090909, 'recall': 0.25210084033613445, 'f1': 0.2898550724637681, 'number': 119} | {'precision': 0.5291512915129152, 'recall': 0.6732394366197183, 'f1': 0.5925619834710744, 'number': 1065} | 0.4808 | 0.5976 | 0.5329 | 0.6167 |
|
66 |
+
| 0.468 | 9.0 | 342 | 1.1145 | {'precision': 0.4584942084942085, 'recall': 0.5871446229913473, 'f1': 0.5149051490514905, 'number': 809} | {'precision': 0.3924050632911392, 'recall': 0.2605042016806723, 'f1': 0.31313131313131315, 'number': 119} | {'precision': 0.5921501706484642, 'recall': 0.6516431924882629, 'f1': 0.6204738489047832, 'number': 1065} | 0.5247 | 0.6021 | 0.5607 | 0.6527 |
|
67 |
+
| 0.4159 | 10.0 | 380 | 1.1606 | {'precision': 0.4683281412253375, 'recall': 0.5574783683559951, 'f1': 0.5090293453724605, 'number': 809} | {'precision': 0.367816091954023, 'recall': 0.2689075630252101, 'f1': 0.31067961165048547, 'number': 119} | {'precision': 0.5958369470945359, 'recall': 0.6450704225352113, 'f1': 0.6194770063119928, 'number': 1065} | 0.5311 | 0.5871 | 0.5577 | 0.6521 |
|
68 |
+
| 0.3764 | 11.0 | 418 | 1.2370 | {'precision': 0.4515828677839851, 'recall': 0.5995055624227441, 'f1': 0.5151354221986192, 'number': 809} | {'precision': 0.3888888888888889, 'recall': 0.29411764705882354, 'f1': 0.3349282296650718, 'number': 119} | {'precision': 0.6041083099906629, 'recall': 0.6075117370892019, 'f1': 0.6058052434456929, 'number': 1065} | 0.5221 | 0.5855 | 0.5520 | 0.6248 |
|
69 |
+
| 0.3393 | 12.0 | 456 | 1.2263 | {'precision': 0.46161515453639085, 'recall': 0.5723114956736712, 'f1': 0.5110375275938189, 'number': 809} | {'precision': 0.35135135135135137, 'recall': 0.2184873949579832, 'f1': 0.26943005181347146, 'number': 119} | {'precision': 0.5891132572431957, 'recall': 0.6300469483568075, 'f1': 0.6088929219600726, 'number': 1065} | 0.5235 | 0.5820 | 0.5512 | 0.6369 |
|
70 |
+
| 0.3253 | 13.0 | 494 | 1.2059 | {'precision': 0.4658590308370044, 'recall': 0.522867737948084, 'f1': 0.49271986022131625, 'number': 809} | {'precision': 0.3402061855670103, 'recall': 0.2773109243697479, 'f1': 0.3055555555555556, 'number': 119} | {'precision': 0.5623028391167192, 'recall': 0.6694835680751173, 'f1': 0.6112301757393913, 'number': 1065} | 0.5143 | 0.5866 | 0.5481 | 0.6376 |
|
71 |
+
| 0.2996 | 14.0 | 532 | 1.2311 | {'precision': 0.46296296296296297, 'recall': 0.5871446229913473, 'f1': 0.5177111716621253, 'number': 809} | {'precision': 0.3263157894736842, 'recall': 0.2605042016806723, 'f1': 0.2897196261682243, 'number': 119} | {'precision': 0.5991189427312775, 'recall': 0.6384976525821596, 'f1': 0.6181818181818182, 'number': 1065} | 0.5257 | 0.5951 | 0.5582 | 0.6350 |
|
72 |
+
| 0.2892 | 15.0 | 570 | 1.2144 | {'precision': 0.46146146146146144, 'recall': 0.5698393077873919, 'f1': 0.5099557522123893, 'number': 809} | {'precision': 0.4024390243902439, 'recall': 0.2773109243697479, 'f1': 0.3283582089552239, 'number': 119} | {'precision': 0.5888412017167381, 'recall': 0.644131455399061, 'f1': 0.6152466367713004, 'number': 1065} | 0.5254 | 0.5921 | 0.5567 | 0.6483 |
|
73 |
+
|
74 |
+
|
75 |
+
### Framework versions
|
76 |
+
|
77 |
+
- Transformers 4.38.2
|
78 |
+
- Pytorch 2.2.1
|
79 |
+
- Datasets 2.18.0
|
80 |
+
- Tokenizers 0.15.2
|
logs/events.out.tfevents.1710936414.FM-PC-LT-280.6887.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:d11eff0f525fede53fb79efd68786f2e35fd28aa336f32eac3e590f819041775
|
3 |
+
size 15855
|
model.safetensors
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 450558212
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:4d6e704b63d55b31c60cfacad63e3671dbf7308513da1aac026fd815a240d0ca
|
3 |
size 450558212
|
preprocessor_config.json
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"apply_ocr": true,
|
3 |
+
"do_resize": true,
|
4 |
+
"image_processor_type": "LayoutLMv2ImageProcessor",
|
5 |
+
"ocr_lang": null,
|
6 |
+
"processor_class": "LayoutLMv2Processor",
|
7 |
+
"resample": 2,
|
8 |
+
"size": {
|
9 |
+
"height": 224,
|
10 |
+
"width": 224
|
11 |
+
},
|
12 |
+
"tesseract_config": ""
|
13 |
+
}
|
special_tokens_map.json
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cls_token": {
|
3 |
+
"content": "[CLS]",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": false,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"mask_token": {
|
10 |
+
"content": "[MASK]",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": false,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"pad_token": {
|
17 |
+
"content": "[PAD]",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": false,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
},
|
23 |
+
"sep_token": {
|
24 |
+
"content": "[SEP]",
|
25 |
+
"lstrip": false,
|
26 |
+
"normalized": false,
|
27 |
+
"rstrip": false,
|
28 |
+
"single_word": false
|
29 |
+
},
|
30 |
+
"unk_token": {
|
31 |
+
"content": "[UNK]",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": false,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false
|
36 |
+
}
|
37 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,80 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"added_tokens_decoder": {
|
3 |
+
"0": {
|
4 |
+
"content": "[PAD]",
|
5 |
+
"lstrip": false,
|
6 |
+
"normalized": false,
|
7 |
+
"rstrip": false,
|
8 |
+
"single_word": false,
|
9 |
+
"special": true
|
10 |
+
},
|
11 |
+
"100": {
|
12 |
+
"content": "[UNK]",
|
13 |
+
"lstrip": false,
|
14 |
+
"normalized": false,
|
15 |
+
"rstrip": false,
|
16 |
+
"single_word": false,
|
17 |
+
"special": true
|
18 |
+
},
|
19 |
+
"101": {
|
20 |
+
"content": "[CLS]",
|
21 |
+
"lstrip": false,
|
22 |
+
"normalized": false,
|
23 |
+
"rstrip": false,
|
24 |
+
"single_word": false,
|
25 |
+
"special": true
|
26 |
+
},
|
27 |
+
"102": {
|
28 |
+
"content": "[SEP]",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": false,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false,
|
33 |
+
"special": true
|
34 |
+
},
|
35 |
+
"103": {
|
36 |
+
"content": "[MASK]",
|
37 |
+
"lstrip": false,
|
38 |
+
"normalized": false,
|
39 |
+
"rstrip": false,
|
40 |
+
"single_word": false,
|
41 |
+
"special": true
|
42 |
+
}
|
43 |
+
},
|
44 |
+
"additional_special_tokens": [],
|
45 |
+
"apply_ocr": false,
|
46 |
+
"clean_up_tokenization_spaces": true,
|
47 |
+
"cls_token": "[CLS]",
|
48 |
+
"cls_token_box": [
|
49 |
+
0,
|
50 |
+
0,
|
51 |
+
0,
|
52 |
+
0
|
53 |
+
],
|
54 |
+
"do_basic_tokenize": true,
|
55 |
+
"do_lower_case": true,
|
56 |
+
"mask_token": "[MASK]",
|
57 |
+
"model_max_length": 512,
|
58 |
+
"never_split": null,
|
59 |
+
"only_label_first_subword": true,
|
60 |
+
"pad_token": "[PAD]",
|
61 |
+
"pad_token_box": [
|
62 |
+
0,
|
63 |
+
0,
|
64 |
+
0,
|
65 |
+
0
|
66 |
+
],
|
67 |
+
"pad_token_label": -100,
|
68 |
+
"processor_class": "LayoutLMv2Processor",
|
69 |
+
"sep_token": "[SEP]",
|
70 |
+
"sep_token_box": [
|
71 |
+
1000,
|
72 |
+
1000,
|
73 |
+
1000,
|
74 |
+
1000
|
75 |
+
],
|
76 |
+
"strip_accents": null,
|
77 |
+
"tokenize_chinese_chars": true,
|
78 |
+
"tokenizer_class": "LayoutLMv2Tokenizer",
|
79 |
+
"unk_token": "[UNK]"
|
80 |
+
}
|
vocab.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|