Implementation of advanced cmap encodings #2356
Labels
is-feature
A feature request
workflow-text-extraction
From a users perspective, text extraction is the affected feature/workflow
Currently, I am trying to extract text from PDF files which partially report some warnings like
I have seen this for the both encodings mentioned above and for
/StandardEncoding
.Digging through the available resources related to the GBK2K cmaps, I found some Adobe resources as well as the implementation from
pdfminer.six
, which ships some custom pickled files derived from the Adobe open source components to handle such cases.Is there any guidance available on how to tackle this or how we would like to see this added to pypdf?
Environment
Which environment were you using when you encountered the problem?
Code + PDF
This is a minimal, complete example that shows the issue:
For now, I have no uncritical file I could share here. Looking at the example file, it seems like in this case it is a scan of a document (from a Canon device?) with Latin characters with wrongly configured or strange OCR, yielding a mix of Latin and Chinese characters inside the text layer.
Traceback
warnings.warn
as currently used only prints the pypdf code line this occurred, thus there is not much of a traceback.The text was updated successfully, but these errors were encountered: