Desh8114 commited on
Commit
f0ca86e
1 Parent(s): 6c02afc

End of training

Browse files
README.md ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
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: 0.6888
20
+ - Answer: {'precision': 0.6959826275787188, 'recall': 0.792336217552534, 'f1': 0.7410404624277457, 'number': 809}
21
+ - Header: {'precision': 0.3629032258064516, 'recall': 0.37815126050420167, 'f1': 0.37037037037037035, 'number': 119}
22
+ - Question: {'precision': 0.7736185383244206, 'recall': 0.8150234741784037, 'f1': 0.7937814357567444, 'number': 1065}
23
+ - Overall Precision: 0.7171
24
+ - Overall Recall: 0.7797
25
+ - Overall F1: 0.7471
26
+ - Overall Accuracy: 0.8084
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 | Answer | Header | Question | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
56
+ |:-------------:|:-----:|:----:|:---------------:|:-------------------------------------------------------------------------------------------------------------:|:-----------------------------------------------------------------------------------------------------------:|:-----------------------------------------------------------------------------------------------------------:|:-----------------:|:--------------:|:----------:|:----------------:|
57
+ | 1.8101 | 1.0 | 10 | 1.5789 | {'precision': 0.01434878587196468, 'recall': 0.016069221260815822, 'f1': 0.015160349854227406, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.1038107752956636, 'recall': 0.07417840375586854, 'f1': 0.08652792990142387, 'number': 1065} | 0.0552 | 0.0462 | 0.0503 | 0.3845 |
58
+ | 1.4764 | 2.0 | 20 | 1.2528 | {'precision': 0.16216216216216217, 'recall': 0.14833127317676142, 'f1': 0.15493867010974824, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.452970297029703, 'recall': 0.5154929577464789, 'f1': 0.48221343873517786, 'number': 1065} | 0.3427 | 0.3357 | 0.3392 | 0.5948 |
59
+ | 1.106 | 3.0 | 30 | 0.9703 | {'precision': 0.49557522123893805, 'recall': 0.553770086526576, 'f1': 0.5230589608873321, 'number': 809} | {'precision': 0.0, 'recall': 0.0, 'f1': 0.0, 'number': 119} | {'precision': 0.6458527493010252, 'recall': 0.6507042253521127, 'f1': 0.6482694106641721, 'number': 1065} | 0.5679 | 0.5725 | 0.5702 | 0.7117 |
60
+ | 0.8412 | 4.0 | 40 | 0.7859 | {'precision': 0.6176165803108808, 'recall': 0.7367119901112484, 'f1': 0.6719278466741826, 'number': 809} | {'precision': 0.19642857142857142, 'recall': 0.09243697478991597, 'f1': 0.12571428571428572, 'number': 119} | {'precision': 0.7102272727272727, 'recall': 0.704225352112676, 'f1': 0.7072135785007072, 'number': 1065} | 0.6533 | 0.6809 | 0.6668 | 0.7606 |
61
+ | 0.6772 | 5.0 | 50 | 0.7168 | {'precision': 0.6395582329317269, 'recall': 0.7873918417799752, 'f1': 0.7058171745152354, 'number': 809} | {'precision': 0.17475728155339806, 'recall': 0.15126050420168066, 'f1': 0.16216216216216217, 'number': 119} | {'precision': 0.730072463768116, 'recall': 0.7568075117370892, 'f1': 0.7431996311664361, 'number': 1065} | 0.6632 | 0.7331 | 0.6964 | 0.7834 |
62
+ | 0.571 | 6.0 | 60 | 0.6881 | {'precision': 0.6596638655462185, 'recall': 0.7762669962917181, 'f1': 0.7132311186825667, 'number': 809} | {'precision': 0.2345679012345679, 'recall': 0.15966386554621848, 'f1': 0.18999999999999997, 'number': 119} | {'precision': 0.7076923076923077, 'recall': 0.8206572769953052, 'f1': 0.7600000000000001, 'number': 1065} | 0.6706 | 0.7632 | 0.7139 | 0.7930 |
63
+ | 0.5021 | 7.0 | 70 | 0.6724 | {'precision': 0.6694736842105263, 'recall': 0.7861557478368356, 'f1': 0.7231381466742467, 'number': 809} | {'precision': 0.2542372881355932, 'recall': 0.25210084033613445, 'f1': 0.25316455696202533, 'number': 119} | {'precision': 0.7303754266211604, 'recall': 0.8037558685446009, 'f1': 0.765310683951721, 'number': 1065} | 0.6795 | 0.7637 | 0.7191 | 0.7968 |
64
+ | 0.454 | 8.0 | 80 | 0.6567 | {'precision': 0.6835306781485468, 'recall': 0.7849196538936959, 'f1': 0.7307249712313003, 'number': 809} | {'precision': 0.35051546391752575, 'recall': 0.2857142857142857, 'f1': 0.3148148148148148, 'number': 119} | {'precision': 0.7604259094942325, 'recall': 0.8046948356807512, 'f1': 0.781934306569343, 'number': 1065} | 0.7088 | 0.7657 | 0.7361 | 0.8040 |
65
+ | 0.4011 | 9.0 | 90 | 0.6651 | {'precision': 0.6748140276301806, 'recall': 0.7849196538936959, 'f1': 0.7257142857142858, 'number': 809} | {'precision': 0.30158730158730157, 'recall': 0.31932773109243695, 'f1': 0.310204081632653, 'number': 119} | {'precision': 0.7592592592592593, 'recall': 0.8084507042253521, 'f1': 0.7830832196452934, 'number': 1065} | 0.6970 | 0.7697 | 0.7315 | 0.8006 |
66
+ | 0.3604 | 10.0 | 100 | 0.6693 | {'precision': 0.6716259298618491, 'recall': 0.7812113720642769, 'f1': 0.7222857142857143, 'number': 809} | {'precision': 0.32432432432432434, 'recall': 0.3025210084033613, 'f1': 0.31304347826086953, 'number': 119} | {'precision': 0.7441077441077442, 'recall': 0.8300469483568075, 'f1': 0.7847314691522416, 'number': 1065} | 0.6929 | 0.7787 | 0.7333 | 0.7999 |
67
+ | 0.3269 | 11.0 | 110 | 0.6750 | {'precision': 0.6823027718550106, 'recall': 0.7911001236093943, 'f1': 0.7326846021751574, 'number': 809} | {'precision': 0.3783783783783784, 'recall': 0.35294117647058826, 'f1': 0.3652173913043478, 'number': 119} | {'precision': 0.7705357142857143, 'recall': 0.8103286384976526, 'f1': 0.7899313501144164, 'number': 1065} | 0.7123 | 0.7752 | 0.7424 | 0.8068 |
68
+ | 0.3069 | 12.0 | 120 | 0.6782 | {'precision': 0.6866310160427808, 'recall': 0.7935723114956736, 'f1': 0.7362385321100916, 'number': 809} | {'precision': 0.3865546218487395, 'recall': 0.3865546218487395, 'f1': 0.38655462184873957, 'number': 119} | {'precision': 0.7771739130434783, 'recall': 0.8056338028169014, 'f1': 0.7911479944674966, 'number': 1065} | 0.7164 | 0.7757 | 0.7449 | 0.8062 |
69
+ | 0.293 | 13.0 | 130 | 0.6901 | {'precision': 0.6992316136114161, 'recall': 0.7873918417799752, 'f1': 0.7406976744186047, 'number': 809} | {'precision': 0.3983050847457627, 'recall': 0.3949579831932773, 'f1': 0.39662447257383965, 'number': 119} | {'precision': 0.775089605734767, 'recall': 0.812206572769953, 'f1': 0.7932141219624025, 'number': 1065} | 0.7221 | 0.7772 | 0.7487 | 0.8057 |
70
+ | 0.2775 | 14.0 | 140 | 0.6842 | {'precision': 0.6945337620578779, 'recall': 0.8009888751545118, 'f1': 0.7439724454649829, 'number': 809} | {'precision': 0.36363636363636365, 'recall': 0.3697478991596639, 'f1': 0.3666666666666667, 'number': 119} | {'precision': 0.7723214285714286, 'recall': 0.812206572769953, 'f1': 0.7917620137299771, 'number': 1065} | 0.7162 | 0.7812 | 0.7473 | 0.8068 |
71
+ | 0.2724 | 15.0 | 150 | 0.6888 | {'precision': 0.6959826275787188, 'recall': 0.792336217552534, 'f1': 0.7410404624277457, 'number': 809} | {'precision': 0.3629032258064516, 'recall': 0.37815126050420167, 'f1': 0.37037037037037035, 'number': 119} | {'precision': 0.7736185383244206, 'recall': 0.8150234741784037, 'f1': 0.7937814357567444, 'number': 1065} | 0.7171 | 0.7797 | 0.7471 | 0.8084 |
72
+
73
+
74
+ ### Framework versions
75
+
76
+ - Transformers 4.30.0
77
+ - Pytorch 2.2.1+cu121
78
+ - Datasets 2.19.0
79
+ - Tokenizers 0.13.3
logs/events.out.tfevents.1713871196.965c7af7cbee.12716.0 CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:44475b605fbe072cf1e53aa85d54b893e96c1e3664003bc4cf18b57da4d0bb15
3
- size 12053
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8be95da0364891d3a15eb246cd880d56e64b69277782793a267db4ea93bd1b87
3
+ size 14390
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:1a1c301045cd24f3a59774ba8d65182960e6fb7e764c2681dfedb20349c74fbe
3
  size 450608834
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:327fbf08ca186c22d82560b96b3cb67e0deeab77c0c1a1513249c02330d876d6
3
  size 450608834
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