LinusReply
commited on
Commit
·
b3f5cd5
1
Parent(s):
206b2cc
LiLT-FineTuned
Browse files- README.md +79 -0
- logs/events.out.tfevents.1684916484.bfcff1482729.14153.0 +2 -2
- logs/events.out.tfevents.1684917426.bfcff1482729.14153.2 +3 -0
- merges.txt +0 -0
- preprocessor_config.json +26 -0
- pytorch_model.bin +1 -1
- special_tokens_map.json +51 -0
- tokenizer.json +0 -0
- tokenizer_config.json +85 -0
- vocab.json +0 -0
README.md
ADDED
@@ -0,0 +1,79 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language:
|
3 |
+
- Hello
|
4 |
+
license: mit
|
5 |
+
tags:
|
6 |
+
- generated_from_trainer
|
7 |
+
datasets:
|
8 |
+
- funsd-layoutlmv3
|
9 |
+
model-index:
|
10 |
+
- name: lilt-en-funsd-2
|
11 |
+
results: []
|
12 |
+
---
|
13 |
+
|
14 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
15 |
+
should probably proofread and complete it, then remove this comment. -->
|
16 |
+
|
17 |
+
# lilt-en-funsd-2
|
18 |
+
|
19 |
+
This model is a fine-tuned version of [SCUT-DLVCLab/lilt-roberta-en-base](https://huggingface.co/SCUT-DLVCLab/lilt-roberta-en-base) on the funsd-layoutlmv3 dataset.
|
20 |
+
It achieves the following results on the evaluation set:
|
21 |
+
- Loss: 1.7012
|
22 |
+
- Answer: {'precision': 0.901985111662531, 'recall': 0.8898408812729498, 'f1': 0.8958718422674061, 'number': 817}
|
23 |
+
- Header: {'precision': 0.6371681415929203, 'recall': 0.6050420168067226, 'f1': 0.6206896551724138, 'number': 119}
|
24 |
+
- Question: {'precision': 0.8736027515047291, 'recall': 0.9433611884865367, 'f1': 0.9071428571428571, 'number': 1077}
|
25 |
+
- Overall Precision: 0.8718
|
26 |
+
- Overall Recall: 0.9016
|
27 |
+
- Overall F1: 0.8864
|
28 |
+
- Overall Accuracy: 0.8041
|
29 |
+
|
30 |
+
## Model description
|
31 |
+
|
32 |
+
More information needed
|
33 |
+
|
34 |
+
## Intended uses & limitations
|
35 |
+
|
36 |
+
More information needed
|
37 |
+
|
38 |
+
## Training and evaluation data
|
39 |
+
|
40 |
+
More information needed
|
41 |
+
|
42 |
+
## Training procedure
|
43 |
+
|
44 |
+
### Training hyperparameters
|
45 |
+
|
46 |
+
The following hyperparameters were used during training:
|
47 |
+
- learning_rate: 5e-05
|
48 |
+
- train_batch_size: 8
|
49 |
+
- eval_batch_size: 8
|
50 |
+
- seed: 42
|
51 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
52 |
+
- lr_scheduler_type: linear
|
53 |
+
- training_steps: 2500
|
54 |
+
- mixed_precision_training: Native AMP
|
55 |
+
|
56 |
+
### Training results
|
57 |
+
|
58 |
+
| Training Loss | Epoch | Step | Validation Loss | Answer | Header | Question | Overall Precision | Overall Recall | Overall F1 | Overall Accuracy |
|
59 |
+
|:-------------:|:------:|:----:|:---------------:|:--------------------------------------------------------------------------------------------------------:|:---------------------------------------------------------------------------------------------------------:|:---------------------------------------------------------------------------------------------------------:|:-----------------:|:--------------:|:----------:|:----------------:|
|
60 |
+
| 0.4401 | 10.53 | 200 | 0.9136 | {'precision': 0.8668252080856124, 'recall': 0.8922888616891065, 'f1': 0.879372738238842, 'number': 817} | {'precision': 0.512, 'recall': 0.5378151260504201, 'f1': 0.5245901639344263, 'number': 119} | {'precision': 0.8825622775800712, 'recall': 0.9210770659238626, 'f1': 0.9014084507042255, 'number': 1077} | 0.8541 | 0.8867 | 0.8701 | 0.8093 |
|
61 |
+
| 0.0458 | 21.05 | 400 | 1.2043 | {'precision': 0.879415347137637, 'recall': 0.8837209302325582, 'f1': 0.8815628815628815, 'number': 817} | {'precision': 0.6153846153846154, 'recall': 0.5378151260504201, 'f1': 0.5739910313901345, 'number': 119} | {'precision': 0.8856121537086684, 'recall': 0.9201485608170845, 'f1': 0.9025500910746811, 'number': 1077} | 0.8694 | 0.8828 | 0.8760 | 0.8042 |
|
62 |
+
| 0.0127 | 31.58 | 600 | 1.3936 | {'precision': 0.880722891566265, 'recall': 0.8947368421052632, 'f1': 0.8876745598057073, 'number': 817} | {'precision': 0.6019417475728155, 'recall': 0.5210084033613446, 'f1': 0.5585585585585585, 'number': 119} | {'precision': 0.8826714801444043, 'recall': 0.9080779944289693, 'f1': 0.8951945080091533, 'number': 1077} | 0.8677 | 0.8798 | 0.8737 | 0.8098 |
|
63 |
+
| 0.0082 | 42.11 | 800 | 1.3872 | {'precision': 0.8771498771498771, 'recall': 0.8739290085679314, 'f1': 0.8755364806866953, 'number': 817} | {'precision': 0.6428571428571429, 'recall': 0.5294117647058824, 'f1': 0.5806451612903226, 'number': 119} | {'precision': 0.8669565217391304, 'recall': 0.9257195914577531, 'f1': 0.895374943870678, 'number': 1077} | 0.8603 | 0.8813 | 0.8707 | 0.8067 |
|
64 |
+
| 0.0035 | 52.63 | 1000 | 1.6235 | {'precision': 0.8825665859564165, 'recall': 0.8922888616891065, 'f1': 0.887401095556908, 'number': 817} | {'precision': 0.49044585987261147, 'recall': 0.6470588235294118, 'f1': 0.5579710144927537, 'number': 119} | {'precision': 0.8833333333333333, 'recall': 0.8857938718662952, 'f1': 0.8845618915159944, 'number': 1077} | 0.8531 | 0.8743 | 0.8636 | 0.7953 |
|
65 |
+
| 0.0031 | 63.16 | 1200 | 1.6677 | {'precision': 0.9051833122629582, 'recall': 0.8763769889840881, 'f1': 0.890547263681592, 'number': 817} | {'precision': 0.48484848484848486, 'recall': 0.6722689075630253, 'f1': 0.5633802816901409, 'number': 119} | {'precision': 0.8893023255813953, 'recall': 0.8876508820798514, 'f1': 0.8884758364312269, 'number': 1077} | 0.8626 | 0.8703 | 0.8665 | 0.7994 |
|
66 |
+
| 0.0014 | 73.68 | 1400 | 1.7012 | {'precision': 0.901985111662531, 'recall': 0.8898408812729498, 'f1': 0.8958718422674061, 'number': 817} | {'precision': 0.6371681415929203, 'recall': 0.6050420168067226, 'f1': 0.6206896551724138, 'number': 119} | {'precision': 0.8736027515047291, 'recall': 0.9433611884865367, 'f1': 0.9071428571428571, 'number': 1077} | 0.8718 | 0.9016 | 0.8864 | 0.8041 |
|
67 |
+
| 0.0011 | 84.21 | 1600 | 1.6779 | {'precision': 0.8715814506539834, 'recall': 0.8971848225214198, 'f1': 0.8841978287092883, 'number': 817} | {'precision': 0.6413043478260869, 'recall': 0.4957983193277311, 'f1': 0.5592417061611374, 'number': 119} | {'precision': 0.8754448398576512, 'recall': 0.9136490250696379, 'f1': 0.894139027714675, 'number': 1077} | 0.8634 | 0.8823 | 0.8727 | 0.8067 |
|
68 |
+
| 0.0009 | 94.74 | 1800 | 1.6159 | {'precision': 0.8729216152019003, 'recall': 0.8996328029375765, 'f1': 0.8860759493670887, 'number': 817} | {'precision': 0.5740740740740741, 'recall': 0.5210084033613446, 'f1': 0.5462555066079295, 'number': 119} | {'precision': 0.8681898066783831, 'recall': 0.9173630454967502, 'f1': 0.8920993227990971, 'number': 1077} | 0.8549 | 0.8867 | 0.8705 | 0.8060 |
|
69 |
+
| 0.0007 | 105.26 | 2000 | 1.5876 | {'precision': 0.8733572281959379, 'recall': 0.8947368421052632, 'f1': 0.8839177750906893, 'number': 817} | {'precision': 0.5982142857142857, 'recall': 0.5630252100840336, 'f1': 0.5800865800865801, 'number': 119} | {'precision': 0.8783783783783784, 'recall': 0.9052924791086351, 'f1': 0.8916323731138546, 'number': 1077} | 0.8611 | 0.8808 | 0.8708 | 0.8091 |
|
70 |
+
| 0.0003 | 115.79 | 2200 | 1.6529 | {'precision': 0.8662721893491124, 'recall': 0.8959608323133414, 'f1': 0.8808664259927798, 'number': 817} | {'precision': 0.5714285714285714, 'recall': 0.5378151260504201, 'f1': 0.554112554112554, 'number': 119} | {'precision': 0.8662587412587412, 'recall': 0.9201485608170845, 'f1': 0.8923908149482216, 'number': 1077} | 0.8505 | 0.8877 | 0.8687 | 0.8039 |
|
71 |
+
| 0.0002 | 126.32 | 2400 | 1.6602 | {'precision': 0.8699763593380615, 'recall': 0.9008567931456548, 'f1': 0.8851473241130486, 'number': 817} | {'precision': 0.5775862068965517, 'recall': 0.5630252100840336, 'f1': 0.5702127659574467, 'number': 119} | {'precision': 0.8725663716814159, 'recall': 0.9155060352831941, 'f1': 0.8935206162211146, 'number': 1077} | 0.8552 | 0.8887 | 0.8716 | 0.8024 |
|
72 |
+
|
73 |
+
|
74 |
+
### Framework versions
|
75 |
+
|
76 |
+
- Transformers 4.29.2
|
77 |
+
- Pytorch 2.0.1+cu118
|
78 |
+
- Datasets 2.12.0
|
79 |
+
- Tokenizers 0.13.3
|
logs/events.out.tfevents.1684916484.bfcff1482729.14153.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:3ac405cf226f22ee67453349b0309b0d225aa7d382ba58ecdb03e27eaf0cc36f
|
3 |
+
size 12706
|
logs/events.out.tfevents.1684917426.bfcff1482729.14153.2
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5885fd9bce8495757281b6c854fee1af36ffdc511953773668b6c4cb616fdd48
|
3 |
+
size 592
|
merges.txt
ADDED
The diff for this file is too large to render.
See raw diff
|
|
preprocessor_config.json
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"apply_ocr": true,
|
3 |
+
"do_normalize": true,
|
4 |
+
"do_rescale": true,
|
5 |
+
"do_resize": true,
|
6 |
+
"image_mean": [
|
7 |
+
0.5,
|
8 |
+
0.5,
|
9 |
+
0.5
|
10 |
+
],
|
11 |
+
"image_processor_type": "LayoutLMv3FeatureExtractor",
|
12 |
+
"image_std": [
|
13 |
+
0.5,
|
14 |
+
0.5,
|
15 |
+
0.5
|
16 |
+
],
|
17 |
+
"ocr_lang": null,
|
18 |
+
"processor_class": "LayoutLMv3Processor",
|
19 |
+
"resample": 2,
|
20 |
+
"rescale_factor": 0.00392156862745098,
|
21 |
+
"size": {
|
22 |
+
"height": 224,
|
23 |
+
"width": 224
|
24 |
+
},
|
25 |
+
"tesseract_config": ""
|
26 |
+
}
|
pytorch_model.bin
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 520821201
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:9382cd3273e3f6397eebcc99914a4d9dad3ebb9e590de8521a7e0f838ab92607
|
3 |
size 520821201
|
special_tokens_map.json
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"bos_token": {
|
3 |
+
"content": "<s>",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": true,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"cls_token": {
|
10 |
+
"content": "<s>",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": true,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"eos_token": {
|
17 |
+
"content": "</s>",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": true,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
},
|
23 |
+
"mask_token": {
|
24 |
+
"content": "<mask>",
|
25 |
+
"lstrip": true,
|
26 |
+
"normalized": true,
|
27 |
+
"rstrip": false,
|
28 |
+
"single_word": false
|
29 |
+
},
|
30 |
+
"pad_token": {
|
31 |
+
"content": "<pad>",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": true,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false
|
36 |
+
},
|
37 |
+
"sep_token": {
|
38 |
+
"content": "</s>",
|
39 |
+
"lstrip": false,
|
40 |
+
"normalized": true,
|
41 |
+
"rstrip": false,
|
42 |
+
"single_word": false
|
43 |
+
},
|
44 |
+
"unk_token": {
|
45 |
+
"content": "<unk>",
|
46 |
+
"lstrip": false,
|
47 |
+
"normalized": true,
|
48 |
+
"rstrip": false,
|
49 |
+
"single_word": false
|
50 |
+
}
|
51 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,85 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"add_prefix_space": true,
|
3 |
+
"bos_token": {
|
4 |
+
"__type": "AddedToken",
|
5 |
+
"content": "<s>",
|
6 |
+
"lstrip": false,
|
7 |
+
"normalized": true,
|
8 |
+
"rstrip": false,
|
9 |
+
"single_word": false
|
10 |
+
},
|
11 |
+
"clean_up_tokenization_spaces": true,
|
12 |
+
"cls_token": {
|
13 |
+
"__type": "AddedToken",
|
14 |
+
"content": "<s>",
|
15 |
+
"lstrip": false,
|
16 |
+
"normalized": true,
|
17 |
+
"rstrip": false,
|
18 |
+
"single_word": false
|
19 |
+
},
|
20 |
+
"cls_token_box": [
|
21 |
+
0,
|
22 |
+
0,
|
23 |
+
0,
|
24 |
+
0
|
25 |
+
],
|
26 |
+
"eos_token": {
|
27 |
+
"__type": "AddedToken",
|
28 |
+
"content": "</s>",
|
29 |
+
"lstrip": false,
|
30 |
+
"normalized": true,
|
31 |
+
"rstrip": false,
|
32 |
+
"single_word": false
|
33 |
+
},
|
34 |
+
"errors": "replace",
|
35 |
+
"mask_token": {
|
36 |
+
"__type": "AddedToken",
|
37 |
+
"content": "<mask>",
|
38 |
+
"lstrip": true,
|
39 |
+
"normalized": true,
|
40 |
+
"rstrip": false,
|
41 |
+
"single_word": false
|
42 |
+
},
|
43 |
+
"model_max_length": 512,
|
44 |
+
"only_label_first_subword": true,
|
45 |
+
"pad_token": {
|
46 |
+
"__type": "AddedToken",
|
47 |
+
"content": "<pad>",
|
48 |
+
"lstrip": false,
|
49 |
+
"normalized": true,
|
50 |
+
"rstrip": false,
|
51 |
+
"single_word": false
|
52 |
+
},
|
53 |
+
"pad_token_box": [
|
54 |
+
0,
|
55 |
+
0,
|
56 |
+
0,
|
57 |
+
0
|
58 |
+
],
|
59 |
+
"pad_token_label": -100,
|
60 |
+
"processor_class": "LayoutLMv3Processor",
|
61 |
+
"sep_token": {
|
62 |
+
"__type": "AddedToken",
|
63 |
+
"content": "</s>",
|
64 |
+
"lstrip": false,
|
65 |
+
"normalized": true,
|
66 |
+
"rstrip": false,
|
67 |
+
"single_word": false
|
68 |
+
},
|
69 |
+
"sep_token_box": [
|
70 |
+
0,
|
71 |
+
0,
|
72 |
+
0,
|
73 |
+
0
|
74 |
+
],
|
75 |
+
"tokenizer_class": "LayoutLMv3Tokenizer",
|
76 |
+
"trim_offsets": true,
|
77 |
+
"unk_token": {
|
78 |
+
"__type": "AddedToken",
|
79 |
+
"content": "<unk>",
|
80 |
+
"lstrip": false,
|
81 |
+
"normalized": true,
|
82 |
+
"rstrip": false,
|
83 |
+
"single_word": false
|
84 |
+
}
|
85 |
+
}
|
vocab.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|