Neural network architectures HalfKP vs HalfKA

Discussion of chess software programming and technical issues.

Moderator: Ras

User avatar
Fabio Gobbato
Posts: 219
Joined: Fri Apr 11, 2014 10:45 am
Full name: Fabio Gobbato

Neural network architectures HalfKP vs HalfKA

Post by Fabio Gobbato »

Is there a real advantage of using HalfKA over HalfKP?
Aren't the additional pieces for the kings redundant?
The test of Stockfish (https://github.com/official-stockfish/S ... abe82e0838) is not meaningful because it changes also the network size.
Has someone already tested the two different architectures? With what results?
Thank you.
AndrewGrant
Posts: 1957
Joined: Tue Apr 19, 2016 6:08 am
Location: U.S.A
Full name: Andrew Grant

Re: Neural network architectures HalfKP vs HalfKA

Post by AndrewGrant »

It is not redundant. If you think of KP as "King x Pawn, King x Knight, ... King x Queen", KA adds the additional "King x King", which is a set of inputs based on the King positions relative to each other. You could also do the King x Itself, which adds a more PSQT-like input.

I have not had success with KA over KP. It is near equal to slightly worse for me, and ultimately takes longer to train, so there is little to no value in it for me.