petebch666 commited on
Commit
e7834ee
·
1 Parent(s): 7855f8d

End of training

Browse files
README.md ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - generated_from_trainer
4
+ datasets:
5
+ - funsd
6
+ model-index:
7
+ - name: layoutlm-funsd
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-funsd
15
+
16
+ This model is a fine-tuned version of [microsoft/layoutlm-base-uncased](https://huggingface.co/microsoft/layoutlm-base-uncased) on the funsd dataset.
17
+ It achieves the following results on the evaluation set:
18
+ - Loss: 0.6820
19
+ - Answer: {'precision': 0.7084257206208425, 'recall': 0.7898640296662547, 'f1': 0.7469316189362946, 'number': 809}
20
+ - Header: {'precision': 0.2689655172413793, 'recall': 0.3277310924369748, 'f1': 0.2954545454545454, 'number': 119}
21
+ - Question: {'precision': 0.7870619946091644, 'recall': 0.8225352112676056, 'f1': 0.8044077134986226, 'number': 1065}
22
+ - Overall Precision: 0.7194
23
+ - Overall Recall: 0.7797
24
+ - Overall F1: 0.7484
25
+ - Overall Accuracy: 0.8102
26
+
27
+ ## Model description
28
+
29
+ More information needed
30
+
31
+ ## Intended uses & limitations
32
+
33
+ More information needed
34
+
35
+ ## Training and evaluation data
36
+
37
+ More information needed
38
+
39
+ ## Training procedure
40
+
41
+ ### Training hyperparameters
42
+
43
+ The following hyperparameters were used during training:
44
+ - learning_rate: 3e-05
45
+ - train_batch_size: 16
46
+ - eval_batch_size: 8
47
+ - seed: 42
48
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
49
+ - lr_scheduler_type: linear
50
+ - num_epochs: 15
51
+ - mixed_precision_training: Native AMP
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.7857 | 1.0 | 10 | 1.5985 | {'precision': 0.009248554913294798, 'recall': 0.009888751545117428, 'f1': 0.00955794504181601, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.1273972602739726, 'recall': 0.08732394366197183, 'f1': 0.10362116991643454, 'number': 1065} | 0.0633 | 0.0507 | 0.0563 | 0.3562 |
58
+ | 1.4597 | 2.0 | 20 | 1.2331 | {'precision': 0.18717683557394002, 'recall': 0.22373300370828184, 'f1': 0.20382882882882883, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.4439461883408072, 'recall': 0.5577464788732395, 'f1': 0.4943820224719101, 'number': 1065} | 0.3362 | 0.3889 | 0.3606 | 0.6007 |
59
+ | 1.0902 | 3.0 | 30 | 0.9489 | {'precision': 0.4371069182389937, 'recall': 0.515451174289246, 'f1': 0.47305728871242203, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.6257615317667538, 'recall': 0.6751173708920187, 'f1': 0.6495031616982836, 'number': 1065} | 0.5311 | 0.5700 | 0.5499 | 0.6910 |
60
+ | 0.8339 | 4.0 | 40 | 0.7979 | {'precision': 0.5977366255144033, 'recall': 0.7181705809641533, 'f1': 0.652442448062886, 'number': 809} | {'precision': 0.13513513513513514, 'recall': 0.08403361344537816, 'f1': 0.10362694300518135, 'number': 119} | {'precision': 0.6854545454545454, 'recall': 0.707981220657277, 'f1': 0.6965357967667436, 'number': 1065} | 0.6267 | 0.6749 | 0.6499 | 0.7453 |
61
+ | 0.6983 | 5.0 | 50 | 0.7659 | {'precision': 0.6392896781354052, 'recall': 0.7119901112484549, 'f1': 0.6736842105263159, 'number': 809} | {'precision': 0.19626168224299065, 'recall': 0.17647058823529413, 'f1': 0.18584070796460178, 'number': 119} | {'precision': 0.6688102893890675, 'recall': 0.7812206572769953, 'f1': 0.7206582936336077, 'number': 1065} | 0.6345 | 0.7170 | 0.6733 | 0.7610 |
62
+ | 0.5815 | 6.0 | 60 | 0.6907 | {'precision': 0.6410256410256411, 'recall': 0.7725587144622992, 'f1': 0.7006726457399104, 'number': 809} | {'precision': 0.23863636363636365, 'recall': 0.17647058823529413, 'f1': 0.20289855072463767, 'number': 119} | {'precision': 0.7027463651050081, 'recall': 0.8169014084507042, 'f1': 0.7555362570560139, 'number': 1065} | 0.6588 | 0.7607 | 0.7061 | 0.7913 |
63
+ | 0.5044 | 7.0 | 70 | 0.6802 | {'precision': 0.6727078891257996, 'recall': 0.7799752781211372, 'f1': 0.7223812249570692, 'number': 809} | {'precision': 0.26605504587155965, 'recall': 0.24369747899159663, 'f1': 0.2543859649122807, 'number': 119} | {'precision': 0.7305699481865285, 'recall': 0.7943661971830986, 'f1': 0.7611336032388665, 'number': 1065} | 0.6830 | 0.7556 | 0.7175 | 0.7902 |
64
+ | 0.4534 | 8.0 | 80 | 0.6595 | {'precision': 0.7018701870187019, 'recall': 0.788627935723115, 'f1': 0.7427240977881256, 'number': 809} | {'precision': 0.234375, 'recall': 0.25210084033613445, 'f1': 0.242914979757085, 'number': 119} | {'precision': 0.7378559463986599, 'recall': 0.8272300469483568, 'f1': 0.779991146525011, 'number': 1065} | 0.6943 | 0.7772 | 0.7334 | 0.8074 |
65
+ | 0.3971 | 9.0 | 90 | 0.6625 | {'precision': 0.6967032967032967, 'recall': 0.7836835599505563, 'f1': 0.7376381617219313, 'number': 809} | {'precision': 0.27007299270072993, 'recall': 0.31092436974789917, 'f1': 0.2890625, 'number': 119} | {'precision': 0.7433930093776641, 'recall': 0.8187793427230047, 'f1': 0.7792672028596961, 'number': 1065} | 0.6950 | 0.7742 | 0.7325 | 0.8060 |
66
+ | 0.3593 | 10.0 | 100 | 0.6634 | {'precision': 0.7079152731326644, 'recall': 0.7849196538936959, 'f1': 0.7444314185228605, 'number': 809} | {'precision': 0.2714285714285714, 'recall': 0.31932773109243695, 'f1': 0.29343629343629346, 'number': 119} | {'precision': 0.7571305099394987, 'recall': 0.8225352112676056, 'f1': 0.7884788478847885, 'number': 1065} | 0.7060 | 0.7772 | 0.7399 | 0.8115 |
67
+ | 0.3209 | 11.0 | 110 | 0.6655 | {'precision': 0.6973262032085561, 'recall': 0.8059332509270705, 'f1': 0.7477064220183487, 'number': 809} | {'precision': 0.2903225806451613, 'recall': 0.3025210084033613, 'f1': 0.2962962962962963, 'number': 119} | {'precision': 0.7788632326820604, 'recall': 0.8234741784037559, 'f1': 0.8005476951163851, 'number': 1065} | 0.7162 | 0.7852 | 0.7492 | 0.8129 |
68
+ | 0.3064 | 12.0 | 120 | 0.6771 | {'precision': 0.7104072398190046, 'recall': 0.7762669962917181, 'f1': 0.74187832250443, 'number': 809} | {'precision': 0.2689655172413793, 'recall': 0.3277310924369748, 'f1': 0.2954545454545454, 'number': 119} | {'precision': 0.7795698924731183, 'recall': 0.8169014084507042, 'f1': 0.797799174690509, 'number': 1065} | 0.7166 | 0.7712 | 0.7429 | 0.8088 |
69
+ | 0.286 | 13.0 | 130 | 0.6765 | {'precision': 0.7030905077262694, 'recall': 0.7873918417799752, 'f1': 0.7428571428571429, 'number': 809} | {'precision': 0.2689655172413793, 'recall': 0.3277310924369748, 'f1': 0.2954545454545454, 'number': 119} | {'precision': 0.769298245614035, 'recall': 0.8234741784037559, 'f1': 0.7954648526077097, 'number': 1065} | 0.7088 | 0.7792 | 0.7424 | 0.8111 |
70
+ | 0.2806 | 14.0 | 140 | 0.6820 | {'precision': 0.7052980132450332, 'recall': 0.7898640296662547, 'f1': 0.7451895043731779, 'number': 809} | {'precision': 0.2689655172413793, 'recall': 0.3277310924369748, 'f1': 0.2954545454545454, 'number': 119} | {'precision': 0.7793594306049823, 'recall': 0.8225352112676056, 'f1': 0.8003654636820466, 'number': 1065} | 0.7145 | 0.7797 | 0.7457 | 0.8106 |
71
+ | 0.2736 | 15.0 | 150 | 0.6820 | {'precision': 0.7084257206208425, 'recall': 0.7898640296662547, 'f1': 0.7469316189362946, 'number': 809} | {'precision': 0.2689655172413793, 'recall': 0.3277310924369748, 'f1': 0.2954545454545454, 'number': 119} | {'precision': 0.7870619946091644, 'recall': 0.8225352112676056, 'f1': 0.8044077134986226, 'number': 1065} | 0.7194 | 0.7797 | 0.7484 | 0.8102 |
72
+
73
+
74
+ ### Framework versions
75
+
76
+ - Transformers 4.23.1
77
+ - Pytorch 1.12.1+cu113
78
+ - Datasets 2.6.1
79
+ - Tokenizers 0.13.1
logs/events.out.tfevents.1666709386.6dedd18d3c89.167.0 CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:02e37e70c524fb2f8f00cd938a8094bd77a4269f76d76c708d69222ee0a0ced9
3
- size 4634
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f7eede695fc9cfcdf23a821fd452cf5f9a7ef7a56421c67f76c0d6dff85409e5
3
+ size 14110
preprocessor_config.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "apply_ocr": true,
3
+ "do_resize": true,
4
+ "feature_extractor_type": "LayoutLMv2FeatureExtractor",
5
+ "ocr_lang": null,
6
+ "processor_class": "LayoutLMv2Processor",
7
+ "resample": 2,
8
+ "size": 224,
9
+ "tesseract_config": ""
10
+ }
pytorch_model.bin CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:a2de594a940e7d7819130d49d5b95df5a92ba802b598177441f460e87d205c7f
3
  size 450606565
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:054f317693eb039bcd4e73d5d3a9459d2220ab27f91ac39ec0d706213c111ed9
3
  size 450606565
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,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "additional_special_tokens": null,
3
+ "apply_ocr": false,
4
+ "cls_token": "[CLS]",
5
+ "cls_token_box": [
6
+ 0,
7
+ 0,
8
+ 0,
9
+ 0
10
+ ],
11
+ "do_basic_tokenize": true,
12
+ "do_lower_case": true,
13
+ "mask_token": "[MASK]",
14
+ "model_max_length": 512,
15
+ "name_or_path": "microsoft/layoutlmv2-base-uncased",
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
+ "special_tokens_map_file": null,
35
+ "strip_accents": null,
36
+ "tokenize_chinese_chars": true,
37
+ "tokenizer_class": "LayoutLMv2Tokenizer",
38
+ "unk_token": "[UNK]"
39
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff