Author: Vasik Rajlich
Date: 05:03:57 12/14/05
Go up one level in this thread
On December 14, 2005 at 06:30:02, Chan Rasjid wrote: >On December 14, 2005 at 04:44:15, Steve Maughan wrote: > >>Vasik, >> >>>The problem is when the hash entry ages. >> >>This is easy to get around - just store the distance to mate from the *position* >>(i.e. not the root) in the hash table. >> >>In pseudo code: >> >>procedure push_hash(position) >>begin >> if winning_mate_value_in_hash then >> hash_draft_depth += position's_ply_from_root >> else if losing_mate_value_in_hash then >> hash_draft_depth -= position's_ply_from_root >> store(position) >>end; >> > >procedure probe_hash(position) >>begin >> if found_in_table(poistion) then >> begin >> get_hash(position) >> if winning_mate_value_in_hash then >> hash_draft_depth -= position's_ply_from_root >> else if losing_mate_value_in_hash then >> hash_draft_depth += position's_ply_from_root >> end >>end; >> >>I hope this helps! >> >>Regards, >> >>Steve > >I think this is what Dr. Hyatt meant - store exact-score +- ply? >It is as in your code. > >Could Vasik mean something need to be done in some cases for mate entries >in TT. I have no clue anything need to be done even if we do not clean TT after >a game. > >In a normal search, Snailchess always return whenever a mate score is found. >Getting the shortest mate here seems illogical as long as it is a mate-score >for a position and hashed. Only the general search probe may use them for >cut-off and they need not be the shortest-dist-to-mate. Comparing 2 mate-scores >may not be accurate (shortest) but it should not be a problem. When a plus-mate >is confirmed at root, we call root_mate_search() and this is one of the cleanest >and easy call that can eliminate all search intricacies with not the slightest >drawback. I think this should be applicable even for very top programs. Weak >snailchess never ever fail to complete the game with checkmate with this style. > >I don't know the case of Rykba. > >Rasjid It's a question of searching at the root with either search_root (-shortest_mate, +shortest_mate, ...) or search_root (-longest_mate, +longest_mate, ...) The latter is very slightly more efficient, but the former has better mating technique which some users apparently like :) Vas
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.