Evaluation

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

User avatar
Look
Posts: 366
Joined: Thu Jun 05, 2014 2:14 pm
Location: Iran
Full name: Mehdi Amini

Re: Evaluation

Post by Look »

For the moment both kings seem safe. After some moves black has a deadly attack on white's castle. You may get the moves from a top engines running on strong hardware. Carefully analyse the position.
Farewell.
Daniel Anulliero
Posts: 759
Joined: Fri Jan 04, 2013 4:55 pm
Location: Nice

Re: Evaluation

Post by Daniel Anulliero »

Henk wrote: Mon Jul 05, 2021 12:27 pm Don't know how to make engine understand that this position is lost for white.
Should I assign a huge bonus to the knight on f4. But that would be different if white had a knight on g3.

[d] r1b2rk1/p4ppp/2p2q2/4p3/2BpPn2/5N2/PPP2PPP/R3QRK1 w - - 2 16
Joke ON:
My Isa engine see a win on time in 40 moves here
Joke OFF

😉
Isa download :
Henk
Posts: 7220
Joined: Mon May 27, 2013 10:31 am

Re: Evaluation

Post by Henk »

[d]4rr1k/1p4p1/2bb1qnp/p1p1pp2/8/2PP1N2/PPBB1PPP/1R1QR1K1 w - -

Another wrong static evaluation. White is lost here but Skipper giving +0.5.
Because it's whites turn. White has a rook on a half open file. Black has a weakness on h6.
??
Joost Buijs
Posts: 1563
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: Evaluation

Post by Joost Buijs »

Henk wrote: Thu Jul 08, 2021 9:53 am [d]4rr1k/1p4p1/2bb1qnp/p1p1pp2/8/2PP1N2/PPBB1PPP/1R1QR1K1 w - -

Another wrong static evaluation. White is lost here but Skipper giving +0.5.
Because it's whites turn. White has a rook on a half open file. Black has a weakness on h6.
??
The pawn on h6 is maybe a target, but it is not weak. Look how much space black has compared to white, you should count that too.
You probably have to add some evaluation features, another problem with Skipper is it's speed, that makes it tactically weak.
I don't know anything about C#, even if it's twice as slow as C you should easily get 1 mn/s on a single core with a pretty simple implementation.
User avatar
xr_a_y
Posts: 1871
Joined: Sat Nov 25, 2017 2:28 pm
Location: France

Re: Evaluation

Post by xr_a_y »

Henk wrote: Thu Jul 08, 2021 9:53 am [d]4rr1k/1p4p1/2bb1qnp/p1p1pp2/8/2PP1N2/PPBB1PPP/1R1QR1K1 w - -

Another wrong static evaluation. White is lost here but Skipper giving +0.5.
Because it's whites turn. White has a rook on a half open file. Black has a weakness on h6.
??
Using a net Minic says -227

Using HCE I have -157

Code: Select all

info string Info  2021-07-08 11:09:19-811: Game phase    0.898039
info string Info  2021-07-08 11:09:19-811: ScalingFactor 1
info string Info  2021-07-08 11:09:19-811: Material      -6 3
info string Info  2021-07-08 11:09:19-811: Positional    -27 -26
info string Info  2021-07-08 11:09:19-811: Development   -23 8
info string Info  2021-07-08 11:09:19-811: Mobility      -65 -30
info string Info  2021-07-08 11:09:19-811: Pawn          -13 -51
info string Info  2021-07-08 11:09:19-811: Attack        -33 -32
info string Info  2021-07-08 11:09:19-812: eval -157 phase 0.898039
User avatar
lithander
Posts: 881
Joined: Sun Dec 27, 2020 2:40 am
Location: Bremen, Germany
Full name: Thomas Jahn

Re: Evaluation

Post by lithander »

Joost Buijs wrote: Thu Jul 08, 2021 10:38 am You probably have to add some evaluation features,
Sure, if you add more features like in the example of Minic and they all point in the same direction (negative) the evaluation becomes clearer and probably more accurate.

But if Henk's evaluation is currently misjudging many positions I would not add features but try to simplify and temporarily remove all the terms that contribute to a "wrong" evaluation often. Even PSTs alone would suffice to judge the trend here (black is winning) correctly. My PSTs give it a -49 for example.

Can you view the individual terms of your evaluation like Minic does? That way you could find out which evaluation term points in the "wrong" direction.

And instead of doing that by hand and on individual positions you could write some test benchmark that evaluates the quality of the individual evaluation terms on a set of annotated (e.g. you know the proper score from stockfish) test-positions. Then you know which of your evaluation terms are not contributing as they should and need to be improved or removed.
Minimal Chess (simple, open source, C#) - Youtube & Github
Leorik (competitive, in active development, C#) - Github & Lichess
Henk
Posts: 7220
Joined: Mon May 27, 2013 10:31 am

Re: Evaluation

Post by Henk »

[d]r1bq1rk1/pppp1ppp/2n2n2/6B1/1b2PP2/2N5/PPP3PP/R2QKBNR b KQ f3 0 7

When I add space for the f-pawn I get this. Last move was f2-f4?
So it's related to kingsafety.
User avatar
mvanthoor
Posts: 1784
Joined: Wed Jul 03, 2019 4:42 pm
Location: Netherlands
Full name: Marcel Vanthoor

Re: Evaluation

Post by mvanthoor »

lithander wrote: Thu Jul 08, 2021 11:56 am But if Henk's evaluation is currently misjudging many positions I would not add features but try to simplify and temporarily remove all the terms that contribute to a "wrong" evaluation often. Even PSTs alone would suffice to judge the trend here (black is winning) correctly. My PSTs give it a -49 for example.
Rustic says -102, and it's frantically trying to defend the king-side position for white... and it has PST's only.

Code: Select all

info score cp -50 depth 1 seldepth 5 time 0 nodes 93 nps 0 pv a1d1
info score cp -61 depth 2 seldepth 10 time 0 nodes 1243 nps 0 pv a1d1 c6c5
info score cp -57 depth 3 seldepth 12 time 1 nodes 4525 nps 4525000 pv a1d1 f4h3 g1h1 h3f4
info score cp -62 depth 4 seldepth 15 time 9 nodes 38207 nps 4245222 pv g2g3 f4h3 g1g2 a8b8 a1b1
info score cp -67 depth 5 seldepth 18 time 29 nodes 165976 nps 5723310 pv e1a5 f8e8 a5c7 f4h3 g1h1 h3f4
info score cp -57 depth 6 seldepth 21 time 109 nodes 525769 nps 4823569 hashfull 1 pv g2g3 f4h3 g1g2 a8b8 a1b1 b8b7 e1e2
info score cp -75 depth 7 seldepth 23 time 853 nodes 3633654 nps 4259852 hashfull 10 pv g1h1 c8g4 f3d2 g4e6 c4e6 f6e6 d2f3
info score cp -82 depth 8 seldepth 26 time 5191 nodes 21955599 nps 4229551 hashfull 60 pv e1a5 f6g6 g2g3 g6g4 f3d2 a8b8 a1b1 f4h3 g1h1
info score cp -102 depth 9 seldepth 26 time 17257 nodes 70081403 nps 4061042 hashfull 191 pv h2h4 a8b8 a1b1 c8g4 e1d1 g4f3 d1f3 b8b4 c4b3 f6h4
info score cp -102 depth 10 seldepth 27 time 57927 nodes 228180920 nps 3939112 hashfull 534 pv e1d1 a8b8 b2b3 c8h3 f3e1 f6g6 d1f3 b8d8 f3g3 h3g4
Author of Rustic, an engine written in Rust.
Releases | Code | Docs | Progress | CCRL