fixes rotated images so they can be fed to an OCR program
CSS JavaScript HTML Python
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


ocrprep prepares photos taken in less than optimal conditions for optical character recognition.

ocrprep is licensed under the LGPL

We use OpenCV for almost everything

  1. adaptive thresholding fixes lighting issue that can occur when using camera phones
  2. clean up noisy images using edge preserving median blur, dilation and erosion
  3. The hough transform finds lines formed by rows of text
  4. Once we know what the lines look like, we can calculate the degree of rotation
  5. OpenCV will build a rotation matrix for us given a point around which to rotate, and the angle