- Blind mode tutorial
lichess.org
Donate

SF wiki exploration (NNUE training outer flow, i.e. chess interpretation before compression gizmos).

Classical versus NNUE evaluation
Current versions of Stockfish use a strong neural network (NNUE) to evaluate positions. The venerable "Classical" evaluation, which was about 250 Elo points weaker, was removed from the codebase in August 2023.

Both approaches assign a value to a position that is used in alpha-beta (PVS) search to find the best move. The classical evaluation computed this value as a function of various chess concepts, handcrafted by experts, tested and tuned using fishtest. The NNUE evaluation computes this value with a neural network based on basic inputs (e.g. piece positions only). The network is optimized and trained on the evaluations of millions of positions at moderate search depth.

The NNUE evaluation was first introduced in shogi, and ported to Stockfish afterward. It can be evaluated efficiently on CPUs, and exploits the fact that only parts of the neural network need to be updated after a typical chess move. The nodchip repository provided the first version of the needed tools to train and develop the NNUE networks. Today, more advanced training tools are available in the nnue-pytorch repository, while data generation tools are available in a dedicated branch.

On CPUs supporting modern vector instructions (avx2 and similar), the NNUE evaluation results in much stronger playing strength, even if the nodes per second computed by the engine is somewhat lower (roughly 50% of nps is typical).

Notes:

the NNUE evaluation depends on the Stockfish binary and the network parameter file (see the EvalFile UCI option). Not every parameter file is compatible with a given Stockfish binary, but the default value of the EvalFile UCI option is the name of a network that is guaranteed to be compatible with that binary.

to use the NNUE evaluation, the additional data file with neural network parameters needs to be available. Normally, this file is already embedded in the binary or it can be downloaded. The filename for the default (recommended) net can be found as the default value of the EvalFile UCI option, with the format nn-[SHA256 first 12 digits].nnue (for instance, nn-c157e0a5755b.nnue). This file can be downloaded from https://tests.stockfishchess.org/api/nn/[filename] replacing [filename] as needed.

Last updated: 14/01/2024, 14:10

Classical versus NNUE evaluation Current versions of Stockfish use a strong neural network (NNUE) to evaluate positions. The venerable "Classical" evaluation, which was about 250 Elo points weaker, was removed from the codebase in August 2023. Both approaches assign a value to a position that is used in alpha-beta (PVS) search to find the best move. The classical evaluation computed this value as a function of various chess concepts, handcrafted by experts, tested and tuned using fishtest. The NNUE evaluation computes this value with a neural network based on basic inputs (e.g. piece positions only). The network is optimized and trained on the evaluations of millions of positions at moderate search depth. The NNUE evaluation was first introduced in shogi, and ported to Stockfish afterward. It can be evaluated efficiently on CPUs, and exploits the fact that only parts of the neural network need to be updated after a typical chess move. The nodchip repository provided the first version of the needed tools to train and develop the NNUE networks. Today, more advanced training tools are available in the nnue-pytorch repository, while data generation tools are available in a dedicated branch. On CPUs supporting modern vector instructions (avx2 and similar), the NNUE evaluation results in much stronger playing strength, even if the nodes per second computed by the engine is somewhat lower (roughly 50% of nps is typical). Notes: the NNUE evaluation depends on the Stockfish binary and the network parameter file (see the EvalFile UCI option). Not every parameter file is compatible with a given Stockfish binary, but the default value of the EvalFile UCI option is the name of a network that is guaranteed to be compatible with that binary. to use the NNUE evaluation, the additional data file with neural network parameters needs to be available. Normally, this file is already embedded in the binary or it can be downloaded. The filename for the default (recommended) net can be found as the default value of the EvalFile UCI option, with the format nn-[SHA256 first 12 digits].nnue (for instance, nn-c157e0a5755b.nnue). This file can be downloaded from https://tests.stockfishchess.org/api/nn/[filename] replacing [filename] as needed. Last updated: 14/01/2024, 14:10

https://disservin.github.io/stockfish-docs/stockfish-wiki/Useful-data.html#elo-contributions-from-various-evaluation-terms
Elo contributions from various evaluation terms
See spreadsheet at: https://github.com/official-stockfish/Stockfish/files/3828738/Stockfish.Feature.s.Estimated.Elo.worth.1.xlsx

Note: The estimated elo worth for various features might be outdated, or might get outdated soon.

Last updated: 26/01/2024, 15:44

https://disservin.github.io/stockfish-docs/stockfish-wiki/Useful-data.html#elo-contributions-from-various-evaluation-terms Elo contributions from various evaluation terms See spreadsheet at: https://github.com/official-stockfish/Stockfish/files/3828738/Stockfish.Feature.s.Estimated.Elo.worth.1.xlsx Note: The estimated elo worth for various features might be outdated, or might get outdated soon. Last updated: 26/01/2024, 15:44

https://github.com/official-stockfish/nnue-pytorch/wiki/Training-datasets#stockfish-data-generator

The generator works by doing self-play games and collecting positions and their evaluations along the way. For details on usage you can see the docs in the linked branch.

Why games. evaluation of position during games. what does the game outcome bring to the training table. The abliity to use the words self-play?

Is it still Supervised learning with SF scoreing as target data vector (oracle) for NN to fit with generalization optimization?

i will keep reading when energy and courage to be frustrated some more (although that disservin seems to have done us some good servin) from that link. sounds promising.

https://github.com/official-stockfish/nnue-pytorch/wiki/Training-datasets#stockfish-data-generator > The generator works by doing self-play games and collecting positions and their evaluations along the way. For details on usage you can see the docs in the linked branch. Why games. evaluation of position during games. what does the game outcome bring to the training table. The abliity to use the words self-play? Is it still Supervised learning with SF scoreing as target data vector (oracle) for NN to fit with generalization optimization? i will keep reading when energy and courage to be frustrated some more (although that disservin seems to have done us some good servin) from that link. sounds promising.

There is some alien statement from outer space in the middle of that page. which has no previous presentation context I can figure out..

The noob_3moves.epd opening book can be found in the Stockfish book repo.

Might be a memo to self to fill in a paragraph there about some book. or a message in coded words from dev to dev (kidding 50%). It is a suprise from the way it was boding well before that, good introduction of what the high level chess interpretation relevant issues are about the data side specifications of the ML art of training (and some math. of it too, art and math. do not oppose).

There is some alien statement from outer space in the middle of that page. which has no previous presentation context I can figure out.. > The noob_3moves.epd opening book can be found in the Stockfish book repo. Might be a memo to self to fill in a paragraph there about some book. or a message in coded words from dev to dev (kidding 50%). It is a suprise from the way it was boding well before that, good introduction of what the high level chess interpretation relevant issues are about the data side specifications of the ML art of training (and some math. of it too, art and math. do not oppose).

TODO: https://robotmoon.com/nnue-training-data/, inquire linrock about exact datasets used and the process, replicate from zero if needed

HAHA! Good spirit. At least there is a voice there that is thinking in my ball park.

> TODO: https://robotmoon.com/nnue-training-data/, inquire linrock about exact datasets used and the process, replicate from zero if needed HAHA! Good spirit. At least there is a voice there that is thinking in my ball park.

Historical datasets used for Stockfish master network progression.

also a TODO.. but asking the right question.. should be a good starting point.. glad someone is on it.. I wish that person a lot of luck and psychology of certain busy people, how to make them understand that ELO gain is cool, but that understanding what engines do to our chess from human point of view, might enter the scenery. As a wise chess blogger said. We surrender!

now we would like to opmitize interpretablity, and analysitcal value of the analytical intstrument being used like sheep by us, without questionning, just because it can beat the best of us.. maybe it does so in an ugly manner. or maybe we should think about bubbles .. This page is excellent at the top.. It does not propagate urban legend. and puts the questions...

I can exasperate a bit less.. Good luck Disservin.. you need it.

Historical datasets used for Stockfish master network progression. also a TODO.. but asking the right question.. should be a good starting point.. glad someone is on it.. I wish that person a lot of luck and psychology of certain busy people, how to make them understand that ELO gain is cool, but that understanding what engines do to our chess from human point of view, might enter the scenery. As a wise chess blogger said. We surrender! now we would like to opmitize interpretablity, and analysitcal value of the analytical intstrument being used like sheep by us, without questionning, just because it can beat the best of us.. maybe it does so in an ugly manner. or maybe we should think about bubbles .. This page is excellent at the top.. It does not propagate urban legend. and puts the questions... I can exasperate a bit less.. Good luck Disservin.. you need it.

This topic has been archived and can no longer be replied to.