Page 5 of 7
Re: tuning for the uninformed
Posted: Thu May 31, 2018 11:20 am
by flok
AlvaroBegue wrote: ↑Tue Nov 28, 2017 8:37 pm
[I downloaded games from CCRL, took positions from those games and analyzed them with my program RuyDos. I saved positions on which the evaluation function was being called after searching 1000 nodes. I then labelled each position by running one very quick SF8-vs-SF8 game.
https://bitbucket.org/alonamaloh/ruy_tu ... th_results
EDIT: In that file each position has been replaced by the position from which quiescence search got its score.
In that file, we can see for example:
6k1/8/p4P1B/3b4/1pp3B1/7P/1R4P1/6K1 b - - 1-0
Now is that 1-0 for win for white or for black? I'm asking as it is now black that can move.
Re: tuning for the uninformed
Posted: Thu May 31, 2018 11:17 pm
by AlvaroBegue
1-0 for white. I use the same format of the "Result" tag in PGN.
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 6:21 pm
by flok
Something I forgot to ask:
for
totalError += pow(value_from_fen - calculateSigmoid(eval_score), 2);
value_from_fen = 1.0 for 1-0, 0.0 for 0-1 and so on
but eval_score, should it be from the point of view of the fen-string? or from white? or...?
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 6:45 pm
by Sven
flok wrote: ↑Wed Jun 26, 2019 6:21 pm
Something I forgot to ask:
for
totalError += pow(value_from_fen - calculateSigmoid(eval_score), 2);
value_from_fen = 1.0 for 1-0, 0.0 for 0-1 and so on
but eval_score, should it be from the point of view of the fen-string? or from white? or...?
Obviously the sigmoid function (and therefore also eval_score) must represent a value from the same viewpoint as value_from_fen. Otherwise you would get a high "error" e.g. if value_from_fen = 1, it is black's turn, and your eval function returns a high score in favor of white so that the sigmoid function returns a value close to 0 (from black viewpoint).
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 7:03 pm
by flok
Sven wrote: ↑Wed Jun 26, 2019 6:45 pm
flok wrote: ↑Wed Jun 26, 2019 6:21 pm
Something I forgot to ask:
for
totalError += pow(value_from_fen - calculateSigmoid(eval_score), 2);
value_from_fen = 1.0 for 1-0, 0.0 for 0-1 and so on
but eval_score, should it be from the point of view of the fen-string? or from white? or...?
Obviously the sigmoid function (and therefore also eval_score) must represent a value from the same viewpoint as value_from_fen. Otherwise you would get a high "error" e.g. if value_from_fen = 1, it is black's turn, and your eval function returns a high score in favor of white so that the sigmoid function returns a value close to 0 (from black viewpoint).
Ok, is what I thought to be honest but as the results are currently garbage, I wondered if I maybe did it wrong.
Thanks!
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 7:18 pm
by Robert Pope
Sven wrote: ↑Wed Jun 26, 2019 6:45 pm
flok wrote: ↑Wed Jun 26, 2019 6:21 pm
Something I forgot to ask:
for
totalError += pow(value_from_fen - calculateSigmoid(eval_score), 2);
value_from_fen = 1.0 for 1-0, 0.0 for 0-1 and so on
but eval_score, should it be from the point of view of the fen-string? or from white? or...?
Obviously the sigmoid function (and therefore also eval_score) must represent a value from the same viewpoint as value_from_fen. Otherwise you would get a high "error" e.g. if value_from_fen = 1, it is black's turn, and your eval function returns a high score in favor of white so that the sigmoid function returns a value close to 0 (from black viewpoint).
It looks to me like you have a scale mismatch:
value_from_fen is in [0,1]
calculateSigmoid(eval_score) is in [-1,1].
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 7:34 pm
by flok
Robert Pope wrote: ↑Wed Jun 26, 2019 7:18 pm
It looks to me like you have a scale mismatch:
value_from_fen is in [0,1]
calculateSigmoid(eval_score) is in [-1,1].
Are you sure? Because this is what the wiki says about it:
"Ri is the result of the game corresponding to position i; 0 for black win, 0.5 for draw and 1 for white win."
(
https://www.chessprogramming.org/Texel% ... ing_Method)
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 7:47 pm
by Ratosh
Eval value is always as white POV.
Re: tuning for the uninformed
Posted: Wed Jun 26, 2019 8:05 pm
by flok
Ratosh wrote: ↑Wed Jun 26, 2019 7:47 pm
Eval value is always as white POV.
That is different from what Sven says?
Re: tuning for the uninformed
Posted: Thu Jun 27, 2019 3:06 pm
by flok
flok wrote: ↑Wed Jun 26, 2019 7:03 pm
Ok, is what I thought to be honest but as the results are currently garbage, I wondered if I maybe did it wrong.
Example:
what / start-value / value-after-tuning
Code: Select all
tune_bishop 325 -22
tune_bishop_count 25 3
tune_bishop_open_diagonal 25 95
tune_isolated_pawns 10 -1
tune_king_attacks 1 0
tune_knight 325 -6
tune_mobility 1 -1
tune_pawn 100 -29
tune_queen 975 44
tune_rook 500 61
tune_rook_on_open_file 15 -101
tune_too_many_pawns -10 5
tune_zero_pawns -10 5
(
https://github.com/flok99/Micah/tree/mo ... g_threaded)