From 9d8b7e6039f520917cad7c629e850d36bfec4c35 Mon Sep 17 00:00:00 2001 From: liferecords Date: Tue, 5 Aug 2025 14:38:02 +0800 Subject: [PATCH] support infer with transformers add use_hf --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 3812c76..26e1c9e 100755 --- a/README.md +++ b/README.md @@ -1151,6 +1151,9 @@ python3 dots_ocr/parser.py demo/demo_image1.jpg --prompt prompt_ocr python3 dots_ocr/parser.py demo/demo_image1.jpg --prompt prompt_grounding_ocr --bbox 163 241 1536 705 ``` +**Based on Transformers**, you can parse an image or a pdf file using the same commands above, just add `--use_hf true`. + +> Notice: transformers is slower than vllm, if you want to use demo/* with transformers,just add `use_hf=True` in `DotsOCRParser(..,use_hf=True)`
Output Results