Skip to content

Pygin v58

Choose a tag to compare

@IchNukeDichWeg IchNukeDichWeg released this 03 Aug 22:51
· 377 commits to main since this release

v58 -- the first HCE/NNUE hybrid, and the first net that pays. The neural
net now replaces the hand-crafted evaluation inside the main search, while
qsearch stand-pat stays HCE. Three nets before this one measured at parity or
worse; what changed was not the network but how it was trained.

Elo   | +19.11 +/- 7.8 (95%)   normalized +30.96
SPRT  | GSPRT[0,4] LLR +2.950 vs +/-2.944 -> ACCEPT H1  (stopped early)
Conf  | TIMED 50+0.20, x86, Threads=1, Hash=192MB
Games | N: 3423  W: 1057  L: 868  D: 1498   (52.76%)
Penta | [71, 358, 691, 477, 105]   1,702 pairs, pair ratio 1.36
Split | screen 1,000 pairs (+17.56) -> pooled tranche 702 pairs
Base  | vs Old Engine/57, SUBSET_SEED 57, UHO_4060_v4, ledger +305 -> +324
Bench | 1,074,820 nodes (was 1,145,629 -- the net changes every node count)

The net

  • USE_NNUE is armed on nnue_v4_6f910e35bb1e.nnue. The net evaluates
    inside negamax; qsearch stand-pat stays on the hand-crafted eval, and the
    eval cache is depth-gated so the two scales never cross.
  • The gain is the training schedule, not the architecture. v3 read
    +0.52 +/- 6.8 on this same instrument -- statistically nothing. v4
    changed neither the dataset nor a single dimension of the network: a cosine
    learning-rate schedule in place of a flat one took held-out validation loss
    0.074417 -> 0.066663, and that is the entire +19.
  • It is not bought with speed. Identical dimensions mean identical cost
    per evaluation, so v4 runs at exactly v3's NPS. The engine still hands the
    net roughly 30% of its single-thread NPS, and the +19.11 is measured net of
    that -- the judgement is worth more than the nodes it costs.

Safety

  • NNUE_REQUIRE_SIMD keeps the net off scalar builds. Without NEON or
    AVX2 the evaluation tail runs ~3x slower again and the trade stops paying,
    so on such a CPU the engine refuses to arm the net and plays the HCE.
  • The release binary bundles the net. There is no silent HCE fallback: a
    build that cannot find its net fails loudly at startup rather than quietly
    playing weaker.

Known limits

  • An arm64 confirmation is owed. v3 measured +5.70 +/- 4.6 on arm64
    against +0.52 on x86, so the spread between architectures is real, and only
    x86 has been measured for v4. The risk direction is favourable -- arm64 read
    higher for v3 -- but it is not yet measured.
  • Label depth is the next lever. Labels come from 5,000-node searches while
    the engine plays at 1.75M, so the net is being taught by a much weaker version
    of the thing it is trying to become.

(Corrected after publication: this section originally called the net
"data-limited, not epoch-limited". That diagnosis was wrong. A follow-up epoch
sweep closed the question in the other direction, finding 8 epochs to be the
minimum rather than the 40 this net was trained for: 6/.063989, 8/.063676,
12/.063858, 16/.064264, 40/.066663. The v5 net then took validation loss down
another 4.5% from there and measured +3.09 +/- 4.5, a null, with the LLR
flat across the whole run. Near the floor, validation loss is a weak predictor
of Elo, so a lower number is not by itself a reason to ship a net. The label
depth conclusion survives; the reasoning that reached it did not.)

Full Changelog: v56...v58