Sudoku detector using opencv

The following code is a Python program that can be run at the command line ,It takes input image and output name from user :

◾Convert bgr color to gray

◾Using GaussianBlur for decrease noises

2021-12-24_22-00-15

◾Adaptive threshold to obtain binary image

2021-12-24_22-00-23

◾Find contours and filter for largest contour

◾Find shape with 4 points by approxPolyDP

◾Draw contours around the sudoku table

2021-12-24_22-00-33

◾Crop the table and save it as a jpg image

2021-12-24_22-00-43

Webcam Sudoku Detector.py

This python project has an ability to recognize Sudoku table in live webcam.

By pressing the s button, the sudoku image is cropped and saved.

2021-12-24_20-31-28

2021-12-24_20-30-17