pyOCR LineBoxBuilder skips text / incomplete OCR
In the attached image, tesseract successfully reads all text. But pyOCR drops some of the text (the big headline) when using LineBoxBuilder, it works when the output is simple text. This leads to incomplete OCR in paperwork. Attached is the raw image, the output from running tesseract from the command line, and a python script that shows the difference. Output from the demo script:
=========== All text from tesseract ===========
Lohnsteuerbescheinigung für das Kalenderjahr 2020
Nachstehende Daten wurden maschinell an die Finanzverwaltung übertragen.
ITZBund, Postfach 30 16 45, 53196 Bonn
06 42C1 DECO 05 6000 304A
DV 08.20 0,80 Deutsche Post 69
*K4000*
*30076300*000772*
1. Dauer des Dienstverhältnisses:
01.01. bis 31.07.
2. Zeiträume ohne Anspruch auf Arbeitslohn
Anzahl "U"
Großbuchstaben (S, M, F, FR)
3. Bruttoarbeitsiohn einschl. Sachbezüge ohne 9. und 10.
4. Einbehaltene Lohnsteuer von 3.
============ Text from LineBoxBuilder ===========
ITZBund, Postfach 30 16 45, 53196 Bonn
06 42C1 DECO 05 6000 304A
*K4000*
*30076300*000772*
1. Dauer des Dienstverhältnisses:
01.01. bis 31.07.
2. Zeiträume ohne Anspruch auf Arbeitslohn
Anzahl "U"
Großbuchstaben (S, M, F, FR)
3. Bruttoarbeitsiohn einschl. Sachbezüge ohne 9. und 10.
4. Einbehaltene Lohnsteuer von 3
```.
Edited by Christian Gollwitzer