If using easy_train.py then at least 3.7 is required.
Otherwise versions around 3.6 should also work, but updating is recommended.
Python 3.11 was also tested and works well.
If you're using easy_train.py then at least GCC 9.2 is required for compiling the data loader, Stockfish, and c-chess-cli. This a defensive version requirement as older versions were known to cause problems with Stockfish.
If you're not using easy_train.py then no automatic compilation will take place; use what you wish.
If you're on Windows the best way is to probably use MSYS2. It would also make it easy to install Make (next step).
For compiling Stockfish and c-chess-cli. Not strictly necessary if you're not using easy_train.py, but recommended.
Necessary for compiling the data loader.
python -m venv trainer
pip install -r requirements.txt
PyTorch with CUDA 11.8 will be automatically installed, along with the matching CuPy version.
This requires a C++17 compiler and cmake.
Windows:
compile_data_loader.bat
Linux/Mac:
sh compile_data_loader.bat
Hard way: wiki
Easier way: wiki
TODO: Move to wiki. Add setup for easy_train.py
tensorboard --logdir=logs
Then, go to http://localhost:6006/
TODO: Move to wiki
python run_games.py --concurrency 16 --stockfish_exe ./stockfish.master --c_chess_exe ./c-chess-cli --ordo_exe ./ordo --book_file_name ./noob_3moves.epd run96
Automatically converts all .ckpt
found under run96
to .nnue
and runs games to find the best net. Games are played using c-chess-cli
and nets are ranked using ordo
.
This script runs in a loop, and will monitor the directory for new checkpoints. Can be run in parallel with the training, if idle cores are available.
- Sopel - for the amazing fast sparse data loader
- connormcmonigle - https://github.com/connormcmonigle/seer-nnue, and loss function advice.
- syzygy - http://www.talkchess.com/forum3/viewtopic.php?f=7&t=75506
- https://github.com/DanielUranga/TensorFlowNNUE
- https://hxim.github.io/Stockfish-Evaluation-Guide/
- dkappe - Suggesting ranger (https://github.com/lessw2020/Ranger-Deep-Learning-Optimizer)