Closed danmb1979 closed 5 months ago
For the time being, input documents must be either given as a pathname (in string format) or as a PyMuPDF Document
.
If you have a document given in some binary format (bytes
/ io.BytesIO
) you must open it as a Document
first and use that document to pymupdf4llm.
Python 3.10.14 pymupdf4llm version 0.5
Trying to read a pdf from an S3 bucket (
file_content
in the code below) and runpymupdf4llm
later, but got an error. I usedBytesIO
object. This works fine when loading pdf from local disk (i.e. withoutBytesIO
)