Two LMR versions (for starters) and one Advanced, my current system. I am interested in feedback naturally but most in similar LMR pseudo code from others. Which with permission I can put on my web site. Could be a good learning experience.
http://rebel13.nl/rebel13/blog/lmr%20advanced.html
LMR - [for starters] - [Advance] and [Expert]
Moderators: hgm, Rebel, chrisw
-
- Posts: 7025
- Joined: Thu Aug 18, 2011 12:04 pm
- Full name: Ed Schröder
-
- Posts: 4840
- Joined: Sun Aug 10, 2008 3:15 pm
- Location: Philippines
Re: LMR - [for starters] - [Advance] and [Expert]
Interesting.Rebel wrote:Two LMR versions (for starters) and one Advanced, my current system. I am interested in feedback naturally but most in similar LMR pseudo code from others. Which with permission I can put on my web site. Could be a good learning experience.
http://rebel13.nl/rebel13/blog/lmr%20advanced.html
Code: Select all
a=depth; b=movecount; if (b>63) b=63;
In
Code: Select all
if (score > ALPHA+margin) R--;
-
- Posts: 7025
- Joined: Thu Aug 18, 2011 12:04 pm
- Full name: Ed Schröder
Re: LMR - [for starters] - [Advance] and [Expert]
The first.Ferdy wrote:Interesting.Rebel wrote:Two LMR versions (for starters) and one Advanced, my current system. I am interested in feedback naturally but most in similar LMR pseudo code from others. Which with permission I can put on my web site. Could be a good learning experience.
http://rebel13.nl/rebel13/blog/lmr%20advanced.htmlIs the movecount the moves that were already made or the sequence of the sorted move list?Code: Select all
a=depth; b=movecount; if (b>63) b=63;
Evaluation score, changed the page, that was indeed a bit unclear.InWhat composes the score?Code: Select all
if (score > ALPHA+margin) R--;
-
- Posts: 895
- Joined: Mon Jan 15, 2007 11:23 am
- Location: Warsza
Re: LMR - [for starters] - [Advance] and [Expert]
have You tried dividing history by eight at the beginning of a new search and zeroing it only when the game starts?
Pawel Koziol
http://www.pkoziol.cal24.pl/rodent/rodent.htm
http://www.pkoziol.cal24.pl/rodent/rodent.htm
-
- Posts: 2204
- Joined: Sat Jan 18, 2014 10:24 am
- Location: Andorra
Re: LMR - [for starters] - [Advance] and [Expert]
Thanks! I can add for example that late moves in endgames can be reduced a bit more, at least for Andscacs.
Daniel José - http://www.andscacs.com
-
- Posts: 7025
- Joined: Thu Aug 18, 2011 12:04 pm
- Full name: Ed Schröder
Re: LMR - [for starters] - [Advance] and [Expert]
Makes sense, will try.PK wrote:have You tried dividing history by eight at the beginning of a new search and zeroing it only when the game starts?
-
- Posts: 7025
- Joined: Thu Aug 18, 2011 12:04 pm
- Full name: Ed Schröder
Re: LMR - [for starters] - [Advance] and [Expert]
I know what you mean, create a second more tight "lmr_tab" for the endgame due to the decreasing number of legal moves. Or something like that.cdani wrote:Thanks! I can add for example that late moves in endgames can be reduced a bit more, at least for Andscacs.
-
- Posts: 349
- Joined: Sat Aug 06, 2016 8:31 pm
- Location: United States
Re: LMR - [for starters] - [Advance] and [Expert]
In your pseudocode, does "move produces a better score" mean a beta cutoff, i.e, score >= beta (that's where I currently increment my history table) or score > alpha? Thanks.
-
- Posts: 433
- Joined: Fri Jan 16, 2015 4:02 pm
Re: LMR - [for starters] - [Advance] and [Expert]
Thank you for the ideas, Ed. By comparison my LMR logic is very primitive. All my attempts to improve further have failed, but I see a lot of good ideas in your post.
Code: Select all
// Late move reduction: search best moves with full depth, reduce remaining moves.
lmr := int32(0)
if !sideIsChecked && depth > lmrDepthLimit && !critical {
// Reduce quiet moves and bad captures more at high depths and after many quiet moves.
// Large numMoves means it's likely not a CUT node. Large depth means reductions are less risky.
if move.IsQuiet() {
lmr = 2 + min(depth, numMoves)/6
} else if seeSign(pos, move) {
lmr = 1 + min(depth, numMoves)/6
}
}
zurichess - http://www.zurichess.xyz
-
- Posts: 7025
- Joined: Thu Aug 18, 2011 12:04 pm
- Full name: Ed Schröder
Re: LMR - [for starters] - [Advance] and [Expert]
Score > alpha works a little bit better for me.zenpawn wrote:In your pseudocode, does "move produces a better score" mean a beta cutoff, i.e, score >= beta (that's where I currently increment my history table) or score > alpha? Thanks.