Instructions to use hf-internal-testing/tiny-random-layoutlmv2-for-dqa-test with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hf-internal-testing/tiny-random-layoutlmv2-for-dqa-test with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("document-question-answering", model="hf-internal-testing/tiny-random-layoutlmv2-for-dqa-test")# Load model directly from transformers import AutoProcessor, AutoModelForDocumentQuestionAnswering processor = AutoProcessor.from_pretrained("hf-internal-testing/tiny-random-layoutlmv2-for-dqa-test") model = AutoModelForDocumentQuestionAnswering.from_pretrained("hf-internal-testing/tiny-random-layoutlmv2-for-dqa-test") - Notebooks
- Google Colab
- Kaggle
Upload processor
Browse files- preprocessor_config.json +24 -0
preprocessor_config.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_valid_processor_keys": [
|
| 3 |
+
"images",
|
| 4 |
+
"do_resize",
|
| 5 |
+
"size",
|
| 6 |
+
"resample",
|
| 7 |
+
"apply_ocr",
|
| 8 |
+
"ocr_lang",
|
| 9 |
+
"tesseract_config",
|
| 10 |
+
"return_tensors",
|
| 11 |
+
"data_format",
|
| 12 |
+
"input_data_format"
|
| 13 |
+
],
|
| 14 |
+
"apply_ocr": true,
|
| 15 |
+
"do_resize": true,
|
| 16 |
+
"image_processor_type": "LayoutLMv2ImageProcessor",
|
| 17 |
+
"ocr_lang": null,
|
| 18 |
+
"resample": 2,
|
| 19 |
+
"size": {
|
| 20 |
+
"height": 224,
|
| 21 |
+
"width": 224
|
| 22 |
+
},
|
| 23 |
+
"tesseract_config": ""
|
| 24 |
+
}
|