2 line PNG to more than 2 lines output (used to output 2 lines of text)

18 views
Skip to first unread message

James Smith

unread,
Jan 15, 2026, 2:57:05 PM (3 days ago) Jan 15
to tesseract-ocr
I get data usage reports for my cell phone in png bar graphs with the number and units for each day.
I use convert (from ImageMagic) to crop it to just the numbers and units in two vertical lines.
I then use tesseract to convert it to numbers and units,
tesseract used to create a text file in two lines like:
481 1.20 1.49
MB cB cB

The last month creates a text file like:
481
MB

1.20
cB

1.49
cB


Why would it start creating more than 2 lines?

BTW the cB is GB. :-) MB is always correct but GB is cB or op.
I just do if not MB it is GB.

James Smith

unread,
Jan 15, 2026, 3:28:21 PM (3 days ago) Jan 15
to tesseract-ocr
Oops, they are horizontal lines in the PNG.

James Smith

unread,
Jan 15, 2026, 3:29:39 PM (3 days ago) Jan 15
to tesseract-ocr
Here's the PNG.
ocr-usage-2025-12-28.png

James Smith

unread,
Jan 15, 2026, 6:54:13 PM (3 days ago) Jan 15
to tesseract-ocr

Figured out why it happens but maybe it shouldn't.
It was because the days didn't line up horizontally when it changed months.
In the other reports all the days of each month were the same height.

James Smith

unread,
Jan 15, 2026, 6:55:32 PM (3 days ago) Jan 15
to tesseract-ocr
The ones that worked.
usage-2025-12-28-crop.png
Reply all
Reply to author
Forward
0 new messages