From f6ea541ce762b190c7d68f221a24b555ebf0c80b Mon Sep 17 00:00:00 2001 From: tslil Date: Sat, 5 Sep 2026 09:54:11 +0100 Subject: training rework, best weights so far* After quite a bit of experimentation it would appear that a far better way to train on self-play data in this setup is to randomise not the moves but the opening. The new selfplay and match binaries have lost the epsilon parameter and now play a random opening of some length before switching to pure, deterministic engine inference. This also resulted in a cleanup of nn_train.py. As an added bonus, in this configuration it makes sense to harvest training data from both sides in self-play and consequently the two sides are given distinct game ids (this was almost surely an oversight in the original version of TD(lambda) that i had). I also noticed that rand32 was not using the top 32bits of xorshitf*. *Under default settings nn_train.py produces a 5x5 weight set that doesn't lose a single game to any other cttei that i cared to look at, when measured using `racetrack` (which has a diverse balanced opening book). --- include/xorshift64.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/xorshift64.h') diff --git a/include/xorshift64.h b/include/xorshift64.h index 2b13f60..120e337 100644 --- a/include/xorshift64.h +++ b/include/xorshift64.h @@ -30,7 +30,7 @@ extern uint64_t xors; } #define RANDOM64 (xors * 0x2545F4914F6CDD1D) -#define RANDOM32 ((uint32_t)RANDOM64) +#define RANDOM32 ((uint32_t)(RANDOM64>>32)) static inline uint64_t rand64(void) { XORSHIFT64; -- cgit v1.3.1