Hello All,
The following 8-piece endgame just arose in a Raubfisch X40a3-Cfish match:
[d]4b3/8/6k1/6p1/p6p/K3B1P1/8/8 w 01
Virtually all humans immediately see that this is a draw. White will exchange pawns and then sac his Bishop for Black's dark-squared pawn, leading to a King versus King, Bishop, and pawn endgame draw. However, at this position, Raubfisch scored it -1.79 while Cfish scored it -2.30! I'm playing with 5-man Nalimov TBs.
Since opposite color bishop endgames with more than 6-7 pieces occur frequently, shouldn't programmers code their engines to know when such positions are draws? Then, the materially weaker side could learn to draw games they'd otherwise lose, while materially stronger sides could score wins by avoiding these draws.
Both of the above engines are Stockfish derivatives, suggesting that the strongest A-B engine also lacks this coding. So, are programmers counting on users to have 6-man TBs for engine probing?
Many moves were played since the above position. At move 130, after endless shuffling of bishops, Raubfisch scored it as a small white disadvantage while Cfish still scored it -2.30 until going over 40 plies, when the evaluation dropped to 0.00. They then drew a couple moves later.
All the best,
Steve
Opposite Color Bishop Endgames
Moderators: hgm, Rebel, chrisw
-
- Posts: 2488
- Joined: Wed Mar 08, 2006 9:40 pm
- Location: Eden Prairie, Minnesota
- Full name: Stephen Ham
-
- Posts: 708
- Joined: Mon Jan 16, 2012 6:34 am
Re: Opposite Color Bishop Endgames
If OCB is easy to code, programmers would have coded since 20 years ago.
If you think it is easy to code, you can code yourself.
Stockfish is open source!!!
If you think it is easy to code, you can code yourself.
Stockfish is open source!!!
-
- Posts: 4889
- Joined: Thu Mar 09, 2006 6:34 am
- Location: Pen Argyl, Pennsylvania
Re: Opposite Color Bishop Endgames
hmm... that are not using tablebases? 6 Man used below :Stephen Ham wrote: ↑Fri May 10, 2019 6:48 am Hello All,
The following 8-piece endgame just arose in a Raubfisch X40a3-Cfish match:
[d]4b3/8/6k1/6p1/p6p/K3B1P1/8/8 w 01
Virtually all humans immediately see that this is a draw. White will exchange pawns and then sac his Bishop for Black's dark-squared pawn, leading to a King versus King, Bishop, and pawn endgame draw. However, at this position, Raubfisch scored it -1.79 while Cfish scored it -2.30! I'm playing with 5-man Nalimov TBs.
Since opposite color bishop endgames with more than 6-7 pieces occur frequently, shouldn't programmers code their engines to know when such positions are draws? Then, the materially weaker side could learn to draw games they'd otherwise lose, while materially stronger sides could score wins by avoiding these draws.
Both of the above engines are Stockfish derivatives, suggesting that the strongest A-B engine also lacks this coding. So, are programmers counting on users to have 6-man TBs for engine probing?
Many moves were played since the above position. At move 130, after endless shuffling of bishops, Raubfisch scored it as a small white disadvantage while Cfish still scored it -2.30 until going over 40 plies, when the evaluation dropped to 0.00. They then drew a couple moves later.
All the best,
Steve
Code: Select all
dep score nodes time (not shown: tbhits knps seldep)
82 0.00 23.2M 0:14.14 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
81 0.00 21.9M 0:13.34 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
80 0.00 20.3M 0:12.32 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
79 0.00 18.5M 0:11.23 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
78 0.00 17.1M 0:10.32 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
77 0.00 15.3M 0:09.33 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
76 0.00 13.8M 0:08.45 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
75 0.00 12.2M 0:07.41 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
74 0.00 11.5M 0:07.03 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5 Bd7 Bg3 Kxh6
73 0.00 10.4M 0:06.22 gxh4 g4 h5+ Kg7 h6+ Kh7 Bf4 Bc6 Be5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 Ka3 Bd7 Bc7 Be8 Bd6 Ke4 h5 Kf5 h6
14 -0.49 22001 0:00.01 gxh4 g4 Bf2 Bc6 Bg3 Kf5 Kb4 Bd7 Ka3 Be8 Kb4 Bc6 Ka3 Bd7 Bc7 Be8
13 -0.34 14237 0:00.01 gxh4 g4 Bf2 Bc6 Bg3 Kf5 Bd6 Bd7 Kb4 Be8 Bg3 Kg6 h5+ Kg5 h6
12 -0.46 9190 0:00.01 gxh4 g4 Bf2 Bc6 Bg3 Kf5 Bd6 Bd7 Bc7 Be8 Bd6 Ke4
11 -0.56 5895 0:00.01 gxh4 g4 Bf2 Bc6 Bg3 Kf5 Bd6 Ke4 h5 Kf5 h6
10 -0.57 2477 0:00.00 gxh4 g4 Bf4 Kh5 Bg3 Bb5 Bf2 Bd7 Kb4 Bc6 Bg3 Kg6 Bd6
9 -0.60 1327 0:00.00 gxh4 g4 Bf4 Kh5 Bg3 Bb5 Bf2 Bc6 Kb4 Be8
8 -0.69 879 0:00.00 gxh4 g4 Bf4 Kh5 Bg3 Bb5 Bf2 Bd7 Kb4 Bc6
7 -0.66 555 0:00.00 gxh4 g4 Bf4 Kh5 Bg3 Bd7
6 -0.67 243 0:00.00 gxh4 g4 Bf2 Kh5 Kb4 a3 Kxa3
5 -0.70 166 0:00.00 gxh4 g4 Bf2 Kh5 Kb4
4 -0.54 102 0:00.00 gxh4 g4 Bf2 Kh5
3 -0.59 62 0:00.00 gxh4 g4 Bf4
2 -0.70 35 0:00.00 gxh4 gxh4
1 -0.70 17 0:00.00 gxh4
-
- Posts: 434
- Joined: Fri Dec 16, 2016 11:04 am
- Location: France
- Full name: Richard Delorme
Re: Opposite Color Bishop Endgames
In Amoeba the opposite bishop code made my program weaker by a few Elo.
Richard Delorme
-
- Posts: 27842
- Joined: Fri Mar 10, 2006 10:06 am
- Location: Amsterdam
- Full name: H G Muller
Re: Opposite Color Bishop Endgames
One should remember that the design goal of engines is in general not to be good at chess, but just to have a high Elo. If worse programs score better in games, it is preferred to make them worse.
-
- Posts: 2488
- Joined: Wed Mar 08, 2006 9:40 pm
- Location: Eden Prairie, Minnesota
- Full name: Stephen Ham
Re: Opposite Color Bishop Endgames
Hi HG,
Those are indeed words of wisdom. That's why I post here, to learn such wisdom.
I knew that was true years ago when engines were much more primitive. But I didn't know until now that coding for opposite color bishops still didn't exist in modern chess engines.
Thank you.
All the best,
-Steve-
-
- Posts: 12563
- Joined: Wed Mar 08, 2006 8:57 pm
- Location: Redmond, WA USA
Re: Opposite Color Bishop Endgames
In some chess engines. There are engines with intricate bishop code, where opposite colors, bad bishops, bishop pairs, etc. are all taken into account.Stephen Ham wrote: ↑Fri May 10, 2019 9:22 pm But I didn't know until now that coding for opposite color bishops still didn't exist in modern chess engines.
There are also chess engines that will only under-promote to knight, but not bishop or rook.
Earns Elo, but I absolutely hate it.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
-
- Posts: 434
- Joined: Fri Dec 16, 2016 11:04 am
- Location: France
- Full name: Richard Delorme
Re: Opposite Color Bishop Endgames
I have some trouble to understand you, to be good at chess IS to have a high Elo. In the case of opposite color bishops, it costs Elo because, quite often, avoiding a drawn game leads to a lost one.
Richard Delorme
-
- Posts: 12563
- Joined: Wed Mar 08, 2006 8:57 pm
- Location: Redmond, WA USA
Re: Opposite Color Bishop Endgames
It is also true that every evaluation term has a cost associated with calculating it. If the time spent calculating the new evaluation term is more expensive in terms of Elo than the gain in strength from applying the term, then many programmers will simply remove the term from the evaluation.
One that I wish every program had is wall detection, like the old Crafty 20.0 {last version to support it, written by Jeremiah Pennery IIRC}.
If it is painful to evaluate with it, then there could be a UCI or Winboard option to turn it on and off.
But it is really useful for a broad class of chess problems with blocked boards.
For me, I have lots of compute power and plenty of time. I want the right answer. I guess the same is true of every correspondence chess player as well as every chess problem solver. But chess engines are designed for people to play high speed blitz on some server and gain ranking points. Nobody will even look at the games. It's just a number people want to tag on their handle.
I consider that a great perversion. But I realize that I am in the minority.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
-
- Posts: 41593
- Joined: Sun Feb 26, 2006 10:52 am
- Location: Auckland, NZ
Re: Opposite Color Bishop Endgames
gbanksnz at gmail.com