-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Objective pawn eval #4218
Objective pawn eval #4218
Conversation
5468cc3
to
29467f6
Compare
Great idea! |
29467f6
to
210bb9f
Compare
I personally like this PR in the sense that it puts more emphasis on the WDL model. If the latter is accurate, indeed a more objective pawn eval is obtained. There are still two things that slightly bother me:
|
src/uci.cpp
Outdated
} | ||
|
||
int win_rate_model(Value v, int ply) { | ||
// Return the win rate in per mille units rounded to the nearest value | ||
return int(0.5 + 1000*win_rate_model(v, ply)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return int(0.5 + 1000*win_rate_model(v, ply)); | |
return int(0.5 + 1000*win_rate_model_double(v, ply)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OMG that's a bug.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.
It seems that this method works well for small evals (e.g. the starting position has eval ~30). However for big evals it is rather counter intuitive. If I remove the white queen then master has an eval of ~ -1200 but this method has an eval of ~ -4500. Of course SF will win against god with a queen ahead, so this high negative eval simply reflects the fact that the game is lost. |
This is a cool idea. Centipawn would then directly mean elo difference starting in that position? It would give some more meaning to "average centipawn loss". |
This appears to be the case. But I am not sure is this is bad. For example the eval is currently clamped to 8000cp. I observed in many games that if this value is reached then SF is close to announcing mate. So there is a smooth transition from the eval to mate scores.
Personally I regret that the win rate model depends on the ply. Logically it can and should only depend on the board. One may try to replace ply by game phase, but according to Vondele this gives a less good fit. |
210bb9f
to
b654765
Compare
There was an interesting suggestion by zz4032 on Discord to let WDL depend on number of pieces instead of ply. Don't know if that would work equally well though (i.e. give an accurate model). |
b654765
to
2efa546
Compare
Formula: s=w+d/2 (w,d,l obtained from the win rate model) eval_cp=400*log10(s/(1-s))
2efa546
to
0062234
Compare
I am going to close this. After thinking it over I decided it is probably too controversial. |
I think it is interesting, but yes, I'm sure especially the larger values would surprise people. This would also make it a little more difficult to derive the win_rate_model from pgns that contain search evals. |
This is an alternative proposal to #4216
Formula:
s=w+d/2 (w,d,l obtained from the win rate model)
eval_cp=400*log10(s/(1-s))