Home

Awesome

Tilt-Scene-Text-OCR

Reads Scene Text in Tilted orientation.

Tested on following IDEs

Dependencies

You can acquire the following using NuGet Package Manager

Overview

This is done by the following steps

  1. Initialize necessary parameters.
  2. Start the image acquisition from the camera.
  3. Apply Canny Algorithm and Thresholding.

Fig. 1 - Canny Algorithm + Thresholding

Fig. 1 - Canny Algorithm + Thresholding

  1. Apply Closed Morphology and Erosion

Fig. 2 - Closed Morphology + Erosion

Fig. 2 - Closed Morphology + Erosion

  1. Apply Dilation

Fig. 3 - Dilation

Fig. 3 - Dilation

  1. Find the Contours of the Dilated image. Then acquire each Region of Interests (ROI) in terms of Rotated Rectangle.

  2. Determine the Tilt Orientation and Angles of each acquired Contour Rotated Rectangles.

Fig. 4 - Tilt Orientation and Angle (in Degrees)

Fig. 4 - Tilt Orientation and Angle (in Degrees)

  1. For each Contour Rotated Rectangles -- crop it from the Grayscaled original input image and apply image rotation based on its Tilt Orientation and its Tilt Angle.

  2. Apply Tesseract APIs OCR, and this will be the actual result.

Fig. 5 - Tilted and oriented upside down

Fig. 5 - Tilted and oriented upside down

Fig. 6 - Tilted to the left

Fig. 6 - Tilted to the left

Fig. 7 - Tilted to the right

Fig. 7 - Tilted to the right

Miscellaneous