Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Depth in Hash table

Author: Robert Hyatt

Date: 13:54:41 02/15/01

Go up one level in this thread


On February 15, 2001 at 15:14:42, Frank Phillips wrote:

>On February 14, 2001 at 23:10:07, Robert Hyatt wrote:
>
>[snip]
>>>>That is right, but _be careful_.  Note that in Crafty, a check extension is
>>>>done when the check is played, rather than at the next ply after determining it
>>>>is in check there.  The main thing is to simply be sure that you are consistent
>>>>in the 'depth' value you use for probing and for storing.  IE if you store a
>>>>modified depth value, then you need to modify it before you do the corresponding
>>>>probe to get consistent results.
>>>
>>>If I have understood this at all, Crafty adds the extensions to depth at each
>>>iteration of Search() before calling Search(), so that depth could be greater
>>>leaving Search() than when it entered if the total extension for a move is more
>>>than 2 ply?
>>>
>>
>>No.  First, extensions at one ply are limited to a maximum value of one ply.
>>Otherwise you have a problem with non-termination.  I do the check extension
>>as I do for the reason that my q-search is very simply, and I would prefer to
>>not reach the q-search 'in check' since it doesn't understand that.  With the
>>current approach, the _first_ ply of qsearch is guaranteed to not have the side
>>on move in check, because otherwise it would have been extended at the previous
>>ply and we would still be in Search() and not in Quiesce().
>>
>>This also handles the 1-reply extension cleaner since the check extension is
>>done at the previous ply and the 1-reply extension is done at the in-check ply.
>>
>>
>>
>>>Anyone like me who hacked fractional extensions onto code that treats depth
>>>0,1,2,3,etc and carry over any residual extension the next call of Search() in a
>>>separate variable, rather than adding it to depth, need to add this to depth at
>>>that next iteration before probing the hash or storing a hash value - correct?
>>>
>>>Frank
>>
>>
>>This is how I do it in Crafty.  I maintain "depth" in search, and update a
>>variable "extension" that starts out as -1 ply and gets incremented as
>>extensions are triggered, but it is capped at 0.
>
>Thanks Bob, I overlooked the Min(extensions,0) code.
>But this means that you only carry over residual extensions if it less than a
>ply.  For example:
>
>extensions == 45, Crafty decrements depth, but carries 45 to the next ply.
>But if extensions == 90, Crafty does not decrement depth and does _not_ carry
>any extension (in this case 30) over to the next ply, which of course obeys
>strictly your no more than one ply per ply extension rule.
>
>Apologies for the simple questions, but I have got myself confused :-)
>
>Frank


That is correct. Carrying the fractional stuff forward has the chance to extend
every ply, which will result in horrible bogs in the search.  Extending one
ply per ply is dangerous.  Going more is impossibly dangerous.



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.