sunfish icon indicating copy to clipboard operation
sunfish copied to clipboard

How to train NNUE model?

Open swim2sun opened this issue 1 year ago • 2 comments

Thank you for your work—this is an excellent project! I'm particularly interested in the NNUE version. I noticed that the code loads a pre-trained model. Could you please explain how the model was trained?

swim2sun avatar Aug 27 '24 14:08 swim2sun

Yes. I also would like to know how the .pickle file was generated. The Stockfish nnue project generates .nnue file and not .pickle file.

agnelvishal avatar Jan 10 '25 11:01 agnelvishal

I'm afraid I don't have the code anymore. But it was trained on cclr data: https://lczero.org/blog/2018/09/a-standard-dataset/ This data is not enhanced with evaluations, so it just uses win/loss/draw labels. Probably using mse-loss like alpha-zero. I tried a lot of different compact architectures, as you can see in my w&b below. However, sadly I never got it fast enough to be stronger than the original sunfish :( Image

thomasahle avatar Feb 24 '25 22:02 thomasahle