Skip to content

Commit

Permalink
Towards release 1.0 of the Fathom tool.
Browse files Browse the repository at this point in the history
  • Loading branch information
basil00 committed Dec 6, 2015
1 parent 12faf8a commit 70d0091
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 14 deletions.
39 changes: 29 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,35 @@ are:
* To make it easy to create stand-alone applications that use the Syzygy
tablebases;

API
---
Tool
----

Fathom includes a stand-alone command-line syzygy probing tool `fathom`. To
probe a position, simply run the command:

fathom --path=<path-to-TB-files> "FEN-string"

The tool will print out a PGN representation of the probe result, including:

* Result: "1-0" (white wins), "1/2-1/2" (draw), or "0-1" (black wins)
* The Win-Draw-Loss (WDL) value for the next move: "Win", "Draw", "Loss",
"CursedWin" (win but 50-move draw) or "BlessedLoss" (loss but 50-move draw)
* The Distance-To-Zero (DTZ) value (in plys) for the next move
* WinningMoves: The list of all winning moves
* DrawingMoves: The list of all drawing moves
* LosingMoves: The list of all losing moves
* A pseudo "principle variation" of Syzygy vs. Syzygy for the input position.

For more information, run the following command:

fathom --help

Pre-compiled versions of `fathom` (for all platforms) are available from here:

* https://github.com/basil00/Fathom/releases

Programming API
---------------

Fathom provides a simple API. There are three main function calls:

Expand All @@ -25,14 +52,6 @@ to provide any additional functionality (e.g. move generation) unlike the
traditional `tbprobe` code. However, chess engines can opt to replace some
of the functionality of Fathom for better performance (see below).

Tool
----

Fathom includes a stand-alone command-line syzygy probing tool `fathom`.
Run the following command for more information:

fathom --help

Chess Engines
-------------

Expand Down
18 changes: 14 additions & 4 deletions src/Makefile → src/apps/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,31 @@ ifeq ($(UNAME),Darwin)
endif
CC=clang
STRIP=strip
CFLAGS=-std=gnu99 -O2 -Wall -D TB_NO_THREADS -D TB_NO_HW_POP_COUNT
CFLAGS=-std=gnu99 -O2 -Wall -D TB_NO_THREADS -D TB_NO_HW_POP_COUNT -I..

main: $(TARGET)

fathom.linux:
$(CC) $(CFLAGS) fathom.c tbprobe.c -o fathom.linux
$(CC) $(CFLAGS) fathom.c ../tbprobe.c -o fathom.linux
$(STRIP) fathom.linux

fathom.macosx:
$(CC) $(CFLAGS) fathom.c tbprobe.c -o fathom.macosx
$(CC) $(CFLAGS) fathom.c ../tbprobe.c -o fathom.macosx
$(STRIP) fathom.macosx

fathom.windows: CC=x86_64-w64-mingw32-gcc
fathom.windows: STRIP=x86_64-w64-mingw32-strip
fathom.windows:
$(CC) $(CFLAGS) fathom.c tbprobe.c -o fathom.exe
$(CC) $(CFLAGS) fathom.c ../tbprobe.c -o fathom.exe
$(STRIP) fathom.exe

INSTALL=Fathom-1.0
PACKAGE=Fathom-1.0.zip
release:
mkdir $(INSTALL)
cp fathom.linux $(INSTALL)
cp fathom.macosx $(INSTALL)
cp fathom.exe $(INSTALL)
zip -r $(PACKAGE) $(INSTALL)
rm -rf $(INSTALL)

File renamed without changes.

0 comments on commit 70d0091

Please sign in to comment.