Image-to-Text
Transformers
Safetensors
vision-encoder-decoder
image-text-to-text
donut
document-parsing
lhdn
ebc
Instructions to use acceler-technology/dev-lhdn-parse-donut-model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use acceler-technology/dev-lhdn-parse-donut-model with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "image-to-text" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("image-to-text", model="acceler-technology/dev-lhdn-parse-donut-model")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("acceler-technology/dev-lhdn-parse-donut-model") model = AutoModelForMultimodalLM.from_pretrained("acceler-technology/dev-lhdn-parse-donut-model", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Robust set test train
Browse files- preprocessor_config.json +2 -2
- tokenizer.json +4 -4
- tokenizer_config.json +4 -4
preprocessor_config.json
CHANGED
|
@@ -20,7 +20,7 @@
|
|
| 20 |
"resample": 2,
|
| 21 |
"rescale_factor": 0.00392156862745098,
|
| 22 |
"size": [
|
| 23 |
-
|
| 24 |
-
|
| 25 |
]
|
| 26 |
}
|
|
|
|
| 20 |
"resample": 2,
|
| 21 |
"rescale_factor": 0.00392156862745098,
|
| 22 |
"size": [
|
| 23 |
+
1800,
|
| 24 |
+
1350
|
| 25 |
]
|
| 26 |
}
|
tokenizer.json
CHANGED
|
@@ -23,8 +23,8 @@
|
|
| 23 |
"single_word": false,
|
| 24 |
"lstrip": false,
|
| 25 |
"rstrip": false,
|
| 26 |
-
"normalized":
|
| 27 |
-
"special":
|
| 28 |
},
|
| 29 |
{
|
| 30 |
"id": 1,
|
|
@@ -41,8 +41,8 @@
|
|
| 41 |
"single_word": false,
|
| 42 |
"lstrip": false,
|
| 43 |
"rstrip": false,
|
| 44 |
-
"normalized":
|
| 45 |
-
"special":
|
| 46 |
},
|
| 47 |
{
|
| 48 |
"id": 3,
|
|
|
|
| 23 |
"single_word": false,
|
| 24 |
"lstrip": false,
|
| 25 |
"rstrip": false,
|
| 26 |
+
"normalized": true,
|
| 27 |
+
"special": false
|
| 28 |
},
|
| 29 |
{
|
| 30 |
"id": 1,
|
|
|
|
| 41 |
"single_word": false,
|
| 42 |
"lstrip": false,
|
| 43 |
"rstrip": false,
|
| 44 |
+
"normalized": true,
|
| 45 |
+
"special": false
|
| 46 |
},
|
| 47 |
{
|
| 48 |
"id": 3,
|
tokenizer_config.json
CHANGED
|
@@ -3,10 +3,10 @@
|
|
| 3 |
"0": {
|
| 4 |
"content": "<s>",
|
| 5 |
"lstrip": false,
|
| 6 |
-
"normalized":
|
| 7 |
"rstrip": false,
|
| 8 |
"single_word": false,
|
| 9 |
-
"special":
|
| 10 |
},
|
| 11 |
"1": {
|
| 12 |
"content": "<pad>",
|
|
@@ -19,10 +19,10 @@
|
|
| 19 |
"2": {
|
| 20 |
"content": "</s>",
|
| 21 |
"lstrip": false,
|
| 22 |
-
"normalized":
|
| 23 |
"rstrip": false,
|
| 24 |
"single_word": false,
|
| 25 |
-
"special":
|
| 26 |
},
|
| 27 |
"3": {
|
| 28 |
"content": "<unk>",
|
|
|
|
| 3 |
"0": {
|
| 4 |
"content": "<s>",
|
| 5 |
"lstrip": false,
|
| 6 |
+
"normalized": true,
|
| 7 |
"rstrip": false,
|
| 8 |
"single_word": false,
|
| 9 |
+
"special": false
|
| 10 |
},
|
| 11 |
"1": {
|
| 12 |
"content": "<pad>",
|
|
|
|
| 19 |
"2": {
|
| 20 |
"content": "</s>",
|
| 21 |
"lstrip": false,
|
| 22 |
+
"normalized": true,
|
| 23 |
"rstrip": false,
|
| 24 |
"single_word": false,
|
| 25 |
+
"special": false
|
| 26 |
},
|
| 27 |
"3": {
|
| 28 |
"content": "<unk>",
|