How could it not be best? You have to cooperate to repeat, unless you have no choice in the matter. If you have no choice, then it is a draw. If you do have a choice, you should exercise it the first time the repetition is seen.jayakiran wrote:I see - hmm. But, that assumes that me and my opponent played our best so far until before the search-root. Is that an okay assumption to make in practice?
One example would be that my opponent blundered and let me repeat the position once - but won't allow it a second time? I know that's quite unlikely with chess engines....
Repetitions in the Search Tree
Moderators: hgm, Rebel, chrisw
-
- Posts: 20943
- Joined: Mon Feb 27, 2006 7:30 pm
- Location: Birmingham, AL
Re: Repetitions in the Search Tree
-
- Posts: 464
- Joined: Sat Feb 28, 2015 4:37 pm
- Location: Argentina
Re: Repetitions in the Search Tree
In for example 5/0 with time advantage being the opponnent near to lost by time, the 2nd repetition could be used to make him lose a little more time.bob wrote:How could it not be best? You have to cooperate to repeat, unless you have no choice in the matter. If you have no choice, then it is a draw. If you do have a choice, you should exercise it the first time the repetition is seen.jayakiran wrote:I see - hmm. But, that assumes that me and my opponent played our best so far until before the search-root. Is that an okay assumption to make in practice?
One example would be that my opponent blundered and let me repeat the position once - but won't allow it a second time? I know that's quite unlikely with chess engines....
I couldnt imagine another situation to use it for the moment.
Re: Repetitions in the Search Tree
I'm puzzled: if I always use score 0 and not do any searching when there's a history-hit in my history std::unordered_set, then I get this (from the starting position):
That 4th ply is worrying me; a2-a4?!
Code: Select all
info depth 1 seldepth 1 score cp 40 time 1 nodes 27 pv e2e4
info depth 2 seldepth 2 score cp 0 time 1 nodes 115 pv e2e4 e7e5 f1b5
info depth 3 seldepth 3 score cp 34 time 2 nodes 242 pv e2e4 e7e5 d2d4
info depth 4 seldepth 4 score cp 5 time 10 nodes 940 pv a2a4 e7e5 e2e4 a7a6
info depth 5 seldepth 5 score cp 31 time 61 nodes 5336 pv e2e3 e7e5 d1g4 h7h5 a2a4 h5g4
info depth 6 seldepth 6 score cp 29 time 152 nodes 12522 pv d2d4 e7e6 d1d3 h7h5 d3h7 h8h7 h7h8 d6h2
info depth 7 seldepth 7 score cp 33 time 310 nodes 24620 pv d2d4 e7e6 e2e4 b8c6 b1c3 f8d6 d1f3 c6d4 f3f7
info depth 8 seldepth 8 score cp 29 time 607 nodes 47067 pv d2d4 e7e6 d1d3 b8c6 b1c3 f8d6 d4d5 c6b4 d5e6
info depth 9 seldepth 9 score cp 22 time 1469 nodes 108242 pv d2d4 e7e6 d1d3 d8f6 b1c3 f8d6 d4d5 g8e7 g1f3 e6d5 c3d5 e7d5 d3d5
-
- Posts: 778
- Joined: Sat Jul 01, 2006 7:11 am
Re: Repetitions in the Search Tree
I would worry more about the 5th ply. It looks like your program thinks dropping its Queen is good. Might there be a problem with printing or storing the PV?flok wrote:I'm puzzled: if I always use score 0 and not do any searching when there's a history-hit in my history std::unordered_set, then I get this (from the starting position):
That 4th ply is worrying me; a2-a4?!Code: Select all
info depth 1 seldepth 1 score cp 40 time 1 nodes 27 pv e2e4 info depth 2 seldepth 2 score cp 0 time 1 nodes 115 pv e2e4 e7e5 f1b5 info depth 3 seldepth 3 score cp 34 time 2 nodes 242 pv e2e4 e7e5 d2d4 info depth 4 seldepth 4 score cp 5 time 10 nodes 940 pv a2a4 e7e5 e2e4 a7a6 info depth 5 seldepth 5 score cp 31 time 61 nodes 5336 pv e2e3 e7e5 d1g4 h7h5 a2a4 h5g4 info depth 6 seldepth 6 score cp 29 time 152 nodes 12522 pv d2d4 e7e6 d1d3 h7h5 d3h7 h8h7 h7h8 d6h2 info depth 7 seldepth 7 score cp 33 time 310 nodes 24620 pv d2d4 e7e6 e2e4 b8c6 b1c3 f8d6 d1f3 c6d4 f3f7 info depth 8 seldepth 8 score cp 29 time 607 nodes 47067 pv d2d4 e7e6 d1d3 b8c6 b1c3 f8d6 d4d5 c6b4 d5e6 info depth 9 seldepth 9 score cp 22 time 1469 nodes 108242 pv d2d4 e7e6 d1d3 d8f6 b1c3 f8d6 d4d5 g8e7 g1f3 e6d5 c3d5 e7d5 d3d5
Re: Repetitions in the Search Tree
I reverted the 1-history-hit thing and this problem happens also without it. So in some change a bug was introduced.
Bring on the bisect!
Thanks, I had not noticed it.
----
Ok it was a too restrictive LMR setting.
info depth 9 seldepth 9 score cp 29 time 5676 nodes 417544 pv d2d4 d7d5 c1f4 c8f5 e2e3 f5c2 d1c2 a7a6 f4c7 d8c7
I wonder about that a7a6 though. I looked at the moves in xboard (great help) but I have no idea if it is sane or not.
Bring on the bisect!
Thanks, I had not noticed it.
----
Ok it was a too restrictive LMR setting.
info depth 9 seldepth 9 score cp 29 time 5676 nodes 417544 pv d2d4 d7d5 c1f4 c8f5 e2e3 f5c2 d1c2 a7a6 f4c7 d8c7
I wonder about that a7a6 though. I looked at the moves in xboard (great help) but I have no idea if it is sane or not.
Re: Repetitions in the Search Tree
Uch. In my previous post I talked about revision 2565.
Just tried rev 2483:
Revision 2205 too:
sigh
Just tried rev 2483:
Code: Select all
info depth 7 seldepth 7 score cp 20 time 1347 nodes 165262 pv d2d4 d7d5 c1f4 b8c6 b1c3 [b]a7a6[/b] d1d4
info depth 8 seldepth 8 score cp 14 time 2985 nodes 346492 pv d2d4 d7d5 d1d3 d8d6 d3b5 c7c6 b5d3 [b]a7a6[/b] h1h2
info depth 9 seldepth 9 score cp 13 time 5479 nodes 616912 pv d2d4 d7d5 d1d3 d8d6 e2e4 b8c6 e4e5 d6b4 b1c3 c6d4 d3h7
Code: Select all
info depth 1 seldepth 1 score cp 40 time 3 nodes 21 pv e2e4
info depth 2 seldepth 2 score cp 0 time 5 nodes 158 pv e2e4 e7e5 f1b5
info depth 3 seldepth 3 score cp 34 time 10 nodes 472 pv e2e4 e7e5 d2d4
info depth 4 seldepth 4 score cp 30 time 50 nodes 3416 pv d2d4 e7e5 d4e5
info depth 5 seldepth 5 score cp 19 time 194 nodes 20543 pv e2e3 d7d5 c2c3 c8d7
info depth 6 seldepth 6 score cp 21 time 604 nodes 65752 pv e2e3 d7d5 f1d3
info depth 7 seldepth 7 score cp 9 time 1997 nodes 210546 pv e2e3 d7d5 b1c3
info depth 8 seldepth 8 score cp 14 time 4910 nodes 517304 pv e2e4 d7d5 e4e5 a7a6
info depth 9 seldepth 9 score cp 20 time 20359 nodes 2060685 pv d2d4 e7e6 g1f3 d8f6 e2e4 b8c6 b1c3 f8b4