Skip to content

Captures image of Sudoku puzzle using camera and processes solution

Notifications You must be signed in to change notification settings

ErnestWong/SudokuSolver

Repository files navigation

#SudokuSolver

============

Android application that captures image of Sudoku puzzle using camera and processes solution using image processing and OCR technology.

#Screenshots sudoku-before sudoku-solved

#Libraries Used

#Future Optimizations

  • Sodoku solving algorithm

    1. currently using greedy backtracking algorithm- could use different heuristics to improve performance of algorithm.
  • Image processing

    1. Noise reduction currently using connected component labelling algorithm to remove parts of the image which aren't numbers which requires a passthrough of all the pixels in the image.
      Improvement: Could possibly use a more efficient approach to reduce image noise.

    2. Puzzle detection: currently scanning through image from center across all four directions until outer gridlines of puzzle is reached, which is really inefficient.
      Improvement: Could use an algorithm to detect the largest rectangle/square in the image and assume that to be the puzzle.

    3. Continuous feed detection feature: currently only executes image processing when button is pressed.
      Improvement: Could have a feature that continuously detects a sudoku puzzle and overlays the solution onto the preview.

    4. Rotation detection: currently can detect a puzzle with a few degrees of rotation.
      Improvement: Could have a pre-processing feature that detects the angle of the rotation and rotates the image before using the image processing algorithms.

Analytics

About

Captures image of Sudoku puzzle using camera and processes solution

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages