Cargando…

Determining Chess Game State from an Image

Identifying the configuration of chess pieces from an image of a chessboard is a problem in computer vision that has not yet been solved accurately. However, it is important for helping amateur chess players improve their games by facilitating automatic computer analysis without the overhead of manu...

Descripción completa

Detalles Bibliográficos
Autores principales: Wölflein, Georg, Arandjelović, Ognjen
Formato: Online Artículo Texto
Lenguaje:English
Publicado: MDPI 2021
Materias:
Acceso en línea:https://www.ncbi.nlm.nih.gov/pmc/articles/PMC8321354/
http://dx.doi.org/10.3390/jimaging7060094
_version_ 1783730832714760192
author Wölflein, Georg
Arandjelović, Ognjen
author_facet Wölflein, Georg
Arandjelović, Ognjen
author_sort Wölflein, Georg
collection PubMed
description Identifying the configuration of chess pieces from an image of a chessboard is a problem in computer vision that has not yet been solved accurately. However, it is important for helping amateur chess players improve their games by facilitating automatic computer analysis without the overhead of manually entering the pieces. Current approaches are limited by the lack of large datasets and are not designed to adapt to unseen chess sets. This paper puts forth a new dataset synthesised from a 3D model that is an order of magnitude larger than existing ones. Trained on this dataset, a novel end-to-end chess recognition system is presented that combines traditional computer vision techniques with deep learning. It localises the chessboard using a RANSAC-based algorithm that computes a projective transformation of the board onto a regular grid. Using two convolutional neural networks, it then predicts an occupancy mask for the squares in the warped image and finally classifies the pieces. The described system achieves an error rate of 0.23% per square on the test set, 28 times better than the current state of the art. Further, a few-shot transfer learning approach is developed that is able to adapt the inference system to a previously unseen chess set using just two photos of the starting position, obtaining a per-square accuracy of 99.83% on images of that new chess set. The code, dataset, and trained models are made available online.
format Online
Article
Text
id pubmed-8321354
institution National Center for Biotechnology Information
language English
publishDate 2021
publisher MDPI
record_format MEDLINE/PubMed
spelling pubmed-83213542021-08-26 Determining Chess Game State from an Image Wölflein, Georg Arandjelović, Ognjen J Imaging Article Identifying the configuration of chess pieces from an image of a chessboard is a problem in computer vision that has not yet been solved accurately. However, it is important for helping amateur chess players improve their games by facilitating automatic computer analysis without the overhead of manually entering the pieces. Current approaches are limited by the lack of large datasets and are not designed to adapt to unseen chess sets. This paper puts forth a new dataset synthesised from a 3D model that is an order of magnitude larger than existing ones. Trained on this dataset, a novel end-to-end chess recognition system is presented that combines traditional computer vision techniques with deep learning. It localises the chessboard using a RANSAC-based algorithm that computes a projective transformation of the board onto a regular grid. Using two convolutional neural networks, it then predicts an occupancy mask for the squares in the warped image and finally classifies the pieces. The described system achieves an error rate of 0.23% per square on the test set, 28 times better than the current state of the art. Further, a few-shot transfer learning approach is developed that is able to adapt the inference system to a previously unseen chess set using just two photos of the starting position, obtaining a per-square accuracy of 99.83% on images of that new chess set. The code, dataset, and trained models are made available online. MDPI 2021-06-02 /pmc/articles/PMC8321354/ http://dx.doi.org/10.3390/jimaging7060094 Text en © 2021 by the authors. https://creativecommons.org/licenses/by/4.0/Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
spellingShingle Article
Wölflein, Georg
Arandjelović, Ognjen
Determining Chess Game State from an Image
title Determining Chess Game State from an Image
title_full Determining Chess Game State from an Image
title_fullStr Determining Chess Game State from an Image
title_full_unstemmed Determining Chess Game State from an Image
title_short Determining Chess Game State from an Image
title_sort determining chess game state from an image
topic Article
url https://www.ncbi.nlm.nih.gov/pmc/articles/PMC8321354/
http://dx.doi.org/10.3390/jimaging7060094
work_keys_str_mv AT wolfleingeorg determiningchessgamestatefromanimage
AT arandjelovicognjen determiningchessgamestatefromanimage