Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Corner detection algorithm for mobile

Tags:

I am trying to find a good algorihtm that would detect corners in a image in a mobile phone. There are multiple algorithms to do that I am not sure which one will perform better in a memory and processor limited environment.

Specifically I am trying to find a sudoku grid in a picture taken using the camera of the phone. I am using C# and could not find any libraries that has basic image processing features. I implemented a Sobel filter to do edge detection and that is where I stand.

To make it clear the question is does anybody have any suggestions to use a specific algorithm or a library?

like image 528
Szere Dyeri Avatar asked Jul 19 '09 06:07

Szere Dyeri


People also ask

How does Harris corner detection work?

The Harris corner detector works by taking horizontal and vertical derivatives of the image and looking for areas where both are high, this is quantified by the Harris corner descriptor which is defined in our case as the matrix �and the descriptor is .

What is used to detect corner points in an image?

The Harris corner detector is a corner detection operator that is commonly used in computer vision algorithms to extract corners and infer features of an image.

What is Shi Tomasi corner detection?

Shi-Tomasi is a corner detector that is used to extract strongest corners from images and other corners below level are rejected. It uses minimum euclidean distance between corners detected. Then sorts the remaining corners based on quality in descending order.

What is fast feature detector?

Features from accelerated segment test (FAST) is a corner detection method, which could be used to extract feature points and later used to track and map objects in many computer vision tasks. The FAST corner detector was originally developed by Edward Rosten and Tom Drummond, and was published in 2006.


2 Answers

I wouldn't say "corner detection" by itself is a very good way to do this. Take a step back and think about a photo of a sodoku grid, there are probably lots of assumptions you can make to simplify things.

For example, a sodoku grid always looks exactly the same:

  • White square
  • 9 x 9 regular grid

treating the image in the HSV colour space will allow you to look for high lightness areas (white-ish colours), RGB is a bit pants for most image-processing techniques.

thresholding the image should then reduce noise

Adjusting the image histogram first may also give you better results as it will probably whiten the grid (depends on the image though).

Then all you have to do is find a square. Because you know the grid is regular within it, you can divide the pixels up accordingly and OCR the squares with a number in.

:D

like image 172
Andrew Bullock Avatar answered Oct 12 '22 01:10

Andrew Bullock


Since you are looking for a regular 9x9 grid consider the Hough transform. One way is to run an edge detector first, find all straight lines using the original Hough transform, and then try to figure out which of them form a grid. Or maybe you can come up with a clever way to parametrize the whole grid.

like image 35
Dima Avatar answered Oct 12 '22 01:10

Dima