hans-ekbrand / lc0

The rewritten engine, originally for tensorflow. Now all other backends have been ported here.
GNU General Public License v3.0
3 stars 1 forks source link

Support FEN input #17

Open hans-ekbrand opened 1 year ago

hans-ekbrand commented 1 year ago

As mentioned in https://github.com/hans-ekbrand/lc0/issues/15 FEN input is no longer supported. Add such support.

Here is a typical UCI exchange from a GUI when doing analysis

0129 22:12:30.493014 140258316058624 ../../src/chess/uciloop.cc:136] >> position fen rnbqkbnr/ppppppp1/7p/8/3P4/8/PPP1PPPP/RNBQKBNR w AHah - 0 1
0129 22:12:30.493474 140258316058624 ../../src/chess/uciloop.cc:136] >> go infinite
hans-ekbrand commented 1 year ago

This patch only solves the case when there are no moves in the FEN. To actually deal with FEN that includes moves, a more complicated solution is needed.