Author: Robert Hyatt
Date: 14:26:41 02/29/00
Go up one level in this thread
On February 29, 2000 at 10:02:09, Tim wrote:
>Hello Dr. Hyatt.
>I beleive you forgot this statement in main.c.
>
> crafty_is_white=wtm;
> if (presult == 2) {
> if((From(ponder_move) == From(move)) &&
> (To(ponder_move) == To(move)) &&
> (Piece(ponder_move) == Piece(move)) &&
> (Captured(ponder_move) == Captured(move)) &&
> (Promote(ponder_move) == Promote(move))) {
> value=last_root_value; <--------------------
> presult=1;
> if (!book_move) predicted++;
> }
> else presult=0;
> }
>
>I added above line and tested your program. But it doesn't work perfectly.
>What is wrong?
>
>Thank you.
There is a hole in the timing there. Here is what I did to fix the position
learning stuff:
do {
if (presult != 2) presult=0;
result=0;
display=tree->pos;
if (presult !=2 && (move_number!=1 || !wtm)) presult=Ponder(wtm);
if (presult == 1) value=last_root_value;
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
if (presult==0 || presult==2) {
if (!ics && !xboard) {
if (wtm) printf("White(%d): ",move_number);
else printf("Black(%d): ",move_number);
fflush(stdout);
}
readstat=Read(1,buffer);
if (log_file) {
if (wtm) fprintf(log_file,"White(%d): %s\n",move_number,buffer);
else fprintf(log_file,"Black(%d): %s\n",move_number,buffer);
}
and everything seems to be working, so far as I know...
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.