docling-project / docling-project/docling

DocumentExtractor - Invalid buffer size

Open
#2,221 4 comments 1 reaction 0 assignees View on GitHub
question
Dominant language
Python
Stars
66.4k
Forks
4.8k
Avg merge
2d 21h
Merged PRs (30d)
84

Description

All features of docking are working fine except the new feature DocumentExtractor. There is no issue with the file,
its the same file used in the example - https://github.com/docling-project/docling/blob/main/tests/data_scanned/qr_bill_example.jpg

I've tested on 2 Mac M1 machines and google Colab. Default config, should be using 2B param model, so memory shouldn't be an issue.

from docling.datamodel.base_models import InputFormat
from docling.document_extractor import DocumentExtractor

dict_templ = {
"bill_no": "string",
"total": "number",
}
file_path = "qr_bill_example.jpg"

extractor = DocumentExtractor(allowed_formats=[InputFormat.IMAGE, InputFormat.PDF])
result = extractor.extract(file_path, template=dict_templ)
print(result)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.