Page 1 of 1

LMP

Posted: Tue Jul 09, 2019 3:27 pm
by flok
Hi,

What is LMP and how does it work/is it implemented?
LMP, late move pruning not reduction.
I see mentions of it here and there but it is not described on the wiki.

Re: LMP

Posted: Tue Jul 09, 2019 4:12 pm
by JVMerlino
Late Move Pruning can just as easily be thought of as "Maximally Aggressive Late Move Reduction". Instead of, as in LMR, reducing the remaining depth of a move by some amount depending on how late it is in the move order, you simply reduce the remaining depth to 0, no matter what the remaining depth is. I'm not 100% sure, but I believe some implementations drop straight to q-search at this point, while others abandon the line altogether.

The factors that go into the decision to prune a move are quite varied among engines that implement LMP. Since LMP is potentially more dangerous than LMR, it should be thoroughly tested.

Re: LMP

Posted: Tue Jul 09, 2019 7:34 pm
by Gerd Isenberg
flok wrote:
Tue Jul 09, 2019 3:27 pm
Hi,

What is LMP and how does it work/is it implemented?
LMP, late move pruning not reduction.
I see mentions of it here and there but it is not described on the wiki.
Mentioned on the Futility Pruning page as Move Count Based Pruning aka Late Move Pruning (LMP) with reference post by Tom King.

Re: LMP

Posted: Tue Jul 09, 2019 7:56 pm
by Henk
If you already have a good move you can prune everything
So need not be dangereuses
Of course iT failed in skipper engine
Probably because search narrowed too Much

Man this phone scrumbling my message

Re: LMP

Posted: Tue Jul 09, 2019 8:07 pm
by Dann Corbit
Henk wrote:
Tue Jul 09, 2019 7:56 pm
If you already have a good move you can prune everything
So need not be dangereuses
Of course iT failed in skipper engine
Probably because search narrowed too Much

Man this phone scrumbling my message
Caveat:
From:
https://en.wikiquote.org/wiki/Emanuel_L ... ite_note-2

"t is necessary always to bear in mind these prudential rules, viz.: having a good move, to seek for a better." Dominico Ercole del Rio, The Incomparable Game of Chess, trans. J.S. Bingham (London 1820), 35-36. Note Bingham incorrectly credits Ercole del Rio with work that was authored by Domenico Lorenzo Ponziani

Re: LMP

Posted: Tue Jul 09, 2019 8:21 pm
by Henk
Assuming infinite budget

I score low on perfectionism so no need to discussie with me

Re: LMP

Posted: Tue Jul 09, 2019 8:32 pm
by Dann Corbit
Henk wrote:
Tue Jul 09, 2019 8:21 pm
Assuming infinite budget

I score low on perfectionism so no need to discussie with me
As soon as we move beyond alpha-beta in pruning, perfection has gone out the window.
Null move pruning is unsound. But darned if it doesn't work.
It was Rybka that invented the "drop straight into qsearch idea" and we must admit, it worked pretty well, especially at the time.
I remember Anthony Cozzie being somewhat astonished by the technique.

It is a good idea to prune a lot. The best engines have a branching factor below 2.
But we should not prune too much either.
Naturally, it's a delicate balance. Eloquently described for another game by Kenny Rogers:

"Every gambler knows
The secret to survivin'
Is knowin' what to throw away
And knowin' what to keep"

Re: LMP

Posted: Tue Jul 09, 2019 8:51 pm
by AndrewGrant
flok wrote:
Tue Jul 09, 2019 3:27 pm
Hi,

What is LMP and how does it work/is it implemented?
LMP, late move pruning not reduction.
I see mentions of it here and there but it is not described on the wiki.
For Ethereal ...

Code: Select all

// Step 12B. Late Move Pruning / Move Count Pruning. If we have
// tried many quiets in this position already, and we don't expect
// anything from this move, we can skip all the remaining quiets
if (   depth <= LateMovePruningDepth
    && quiets >= LateMovePruningCounts[improving][depth])
    skipQuiets = 1;

Code: Select all

static const int LateMovePruningDepth = 8;
static const int LateMovePruningCounts[2][9] = {
    {  0,  3,  4,  6, 10, 14, 19, 25, 31},
    {  0,  5,  7, 11, 17, 26, 36, 48, 63},
};

Re: LMP

Posted: Wed Jul 10, 2019 7:16 am
by chrisw
Dann Corbit wrote:
Tue Jul 09, 2019 8:32 pm
Henk wrote:
Tue Jul 09, 2019 8:21 pm
Assuming infinite budget

I score low on perfectionism so no need to discussie with me
As soon as we move beyond alpha-beta in pruning, perfection has gone out the window.
There never was any perfection, since the default is to prune at the horizon (depth).
Pruning sacrifices some of the (otherwise full) width for more depth. Perfection is unattainable but trading width for depth appears to be the way to minimise imperfections. Maybe.

Null move pruning is unsound. But darned if it doesn't work.
stopping the search by running out of time is unsound too.

It was Rybka that invented the "drop straight into qsearch idea" and we must admit, it worked pretty well, especially at the time.
I remember Anthony Cozzie being somewhat astonished by the technique.

It is a good idea to prune a lot. The best engines have a branching factor below 2.
But we should not prune too much either.
Naturally, it's a delicate balance. Eloquently described for another game by Kenny Rogers:

"Every gambler knows
The secret to survivin'
Is knowin' what to throw away
And knowin' what to keep"