'I declare it's marked out just like a large chessboard!' Alice said at last. 'There ought to be some men moving about somewhere—and so there are!'
—Lewis Carroll, Through the Looking-Glass, and What Alice Found there. 1872

Chess Grabber

Create a FEN from a chess diagram picture


Chess Grabber was written by Dion Nicolaas as a hobby project. I started the project when I found out about Chris Greening's Sudoku Grab, an iPhone application that recognizes and solves a Sudoku puzzle it sees through its camera. His description of how it works got me thinking that Chess Grabber could be done, too. It turns out I use a lot of different techniques for Chess Grabber, but I started from there.

When I started the project I knew virtually nothing about image recognition, so there was a lot to learn. Here are some pages that I read.


Thresholding (image processing) - Wikipedia, the free encyclopedia

Chessboard detection

Robust Recognition of Checkerboard Pattern for Deformable Surface Matching in Multiple Views

Automatic Detection of Checkerboards on Blurred and Distorted Images by Martin Rufli e.a.

Pattern recognition

Four Free Neural Network Libraries for Python by Greg Pinero

Divmod Reverend - a simple Bayesian classifier

Improving nearest neighbor rule with a simple adaptive distance measure by Jigang Wang, Predrag Neskovic, Leon N. Cooper

Libraries used

Python Imaging Library (PIL)

CamCanvas API

Bottle: Python Web Framework

Web representation

CSS layouts by Russ Weakly

Web micro-framework Battle! by Richard Jones