Detect if there exists any chess board in the image Get a bounding box of the (most prominent) chess board Check if the board image is rotated by 0, 90, 180, or 270 degrees Finally detect the FEN by ...