Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Detecting Draws using a Small Hash Table?

Author: Uri Blass

Date: 05:10:50 02/21/02

Go up one level in this thread


On February 21, 2002 at 07:01:12, Sune Fischer wrote:

>On February 21, 2002 at 06:19:47, Uri Blass wrote:
>
>>On February 21, 2002 at 04:59:12, Sune Fischer wrote:
>>
>>>On February 21, 2002 at 00:18:09, Uri Blass wrote:
>>>
>>>>On February 20, 2002 at 19:18:51, Vincent Diepeveen wrote:
>>>>>>no no i do not mean hashtable. i mean ARRAY with hashcodes
>>>>>
>>>>>all you have to do is:
>>>>>
>>>>>  for f=current move to 1   f = f -2;
>>>>>    if( hashcode[f] == currenthash )
>>>>>      return(drawscore);
>>>>
>>>>The question is if there is no small risk of wrong repetition detection.
>>>>In my program wrong repetition detection can happen only because of bugs and in
>>>>this case I guess that hashcode[f] is some compression of the position to 32
>>>>or 64 bit number and it may be the same for different positions.
>>>>
>>>>I guess that in the case of 64 bit number the risk is practically 0.
>>>>
>>>>Uri
>>>
>>>There is no risk to the above method, it works perfectly if you use 64 bit.
>>>
>>>I talked to Bruce Moreland about this, it seems *safer* and easier than what he
>>>proposes at http://www.seanet.com/~brucemo/topics/repetition.htm
>>>
>>>He replyed, that he was worried that it would be too slow to do a O(N) search at
>>>every node. The hashing method requires only a few lookups.
>>>However, rep. detec. is not needed in qsearch and most of the time the search
>>>will break quickly because last or previous move was not a "reversible" move
>>>(you should add a break statement to that code Vincent:).
>>>
>>>Bruce did suggest there could be a problem in the endgame if you get close to
>>>the 50 move rule, then you will be doing a O(50) linear search at every node!!
>>>
>>>-S.
>>
>>O(50) is not so big and it is not going to happen in every node in the
>>search(even in that case I believe that the difference in speed is not more than
>>10%).
>
>Your 10% seems like a wild guess, why not 50%? Do you have 500 conditionals in
>your eval or something?

I admit that 10% was a wild guess but even twice slower in these rare cases when
in most cases it is less than 10% slower is not going to get your program more
than 10 elo weaker.

I do not 500 conditionals in the evaluation.
My evaluation is only piece square table and the main problem is my move
generator.

I generate only slightly more than 150,000 nodes per second in the opening
positions on p800 because my move generator generates information that is not
used today(attack tables)

It may be 200000-300000 nodes in the endgame.

I do not know what is the situation of your program but I guess that it is not
clearly faster(otherwise I could expect better results than the results that it
did in a tournament of new engines in the winboard forum and I am happy that my
stupid program that only has piece square table evaluation and is pronbably only
slightly better than tscp based on my tests got the 3th place out of 10).

My opinion is that almost all the new engines including mine are very weak and
you have more important things to worry about than a faster repetition
detection.


Uri



This page took 0.01 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.