[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnugo-devel] breakin fix
From: |
Arend Bayer |
Subject: |
[gnugo-devel] breakin fix |
Date: |
Mon, 12 Jan 2004 13:25:24 +0100 (CET) |
This fixes a bug in the breakin code. I forgot to adjust breakin_depth in
modify_depth_values(), which made the increase/decrease_depth_values()
calls in estimate_territorial_value() (around the call to break_territories())
essentially useless.
This fixes trevora:370 and 9x9:30.
Arend
- adjust breakin_depth in modify_depth_values()
Index: engine/utils.c
===================================================================
RCS file: /cvsroot/gnugo/gnugo/engine/utils.c,v
retrieving revision 1.84
diff -u -p -r1.84 utils.c
--- engine/utils.c 31 Dec 2003 07:06:57 -0000 1.84
+++ engine/utils.c 10 Jan 2004 22:50:21 -0000
@@ -828,6 +828,7 @@ modify_depth_values(int n)
branch_depth += n;
fourlib_depth += n;
ko_depth += n;
+ breakin_depth += n;
}
void
Index: engine/readconnect.c
===================================================================
RCS file: /cvsroot/gnugo/gnugo/engine/readconnect.c,v
retrieving revision 1.60
diff -u -p -r1.60 readconnect.c
--- engine/readconnect.c 10 Nov 2003 21:54:55 -0000 1.60
+++ engine/readconnect.c 10 Jan 2004 22:50:19 -0000
@@ -2485,6 +2485,10 @@ find_connection_moves(int str1, int str2
board_size - I(moves[i]), distances[i], &chars);
pos += chars;
}
+ if (cutoff < HUGE_CONNECTION_DISTANCE) {
+ sprintf(pos, "(cutoff %f)%n", cutoff, &chars);
+ pos += chars;
+ }
sgftreeAddComment(sgf_dumptree, buf);
}
@@ -2669,7 +2673,7 @@ find_break_moves(int str, const char goa
{
float cutoff = HUGE_CONNECTION_DISTANCE;
if (breakin_depth - stackp <= 5)
- cutoff = 1.1 + (breakin_depth - stackp) * 0.15;
+ cutoff = 1.101 + (breakin_depth - stackp) * 0.15;
num_moves = find_connection_moves(str, str2, color_to_move,
&conn1, &conn2, max_dist1, max_dist2,
moves, *total_distance, cutoff);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gnugo-devel] breakin fix,
Arend Bayer <=