I want to trim off excess whitespace in documents that are scanned copies. Is it possible using python?

I want to remove the unwanted whitespace that is surrounding the text.

This is the sample image before cropping. https://ibb.co/BVVZwDb

This is after cropping. https://ibb.co/PGy4mdd

Thanks guys!

1 Answers

Frenchy On

you have to use an OCR for this type of job.

A possible solution to test: Tesseract OCR with Python

*an OCR is an application which transforms an image to Text