From 7cf4c42c5bb9fba35998f1a1115c36703849517e Mon Sep 17 00:00:00 2001 From: jjoshua2 Date: Mon, 7 May 2018 19:53:57 -0400 Subject: [PATCH 1/4] Updated optimum time increasing optimum time --- src/UCTSearch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/UCTSearch.cpp b/src/UCTSearch.cpp index 5e5a8816b..19a5801c3 100644 --- a/src/UCTSearch.cpp +++ b/src/UCTSearch.cpp @@ -407,7 +407,7 @@ Move UCTSearch::think(BoardHistory&& new_bh) { // set up timing info Time.init(bh_.cur().side_to_move(), bh_.cur().game_ply()); - m_target_time = (Limits.movetime ? Limits.movetime : Time.optimum()) - cfg_lagbuffer_ms; + m_target_time = (Limits.movetime ? Limits.movetime : (int)(1.5*Time.optimum())) - cfg_lagbuffer_ms; m_max_time = Time.maximum() - cfg_lagbuffer_ms; m_start_time = Limits.timeStarted(); From addc0dc522aa5b685be589d6ed2929464c91ab94 Mon Sep 17 00:00:00 2001 From: jjoshua2 Date: Mon, 7 May 2018 19:54:53 -0400 Subject: [PATCH 2/4] Update Parameters.cpp update to sf current value --- src/Parameters.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Parameters.cpp b/src/Parameters.cpp index ba1ff5673..60bb17555 100644 --- a/src/Parameters.cpp +++ b/src/Parameters.cpp @@ -106,7 +106,7 @@ void Parameters::setup_default_parameters() { cfg_noise = false; cfg_randomize = false; cfg_timemanage = true; - cfg_slowmover = 89; + cfg_slowmover = 84; cfg_logfile_handle = nullptr; cfg_quiet = false; cfg_rng_seed = 0; From bc5cc4b0ec1777c4fa7ef7c6bcb8cb3e75a673e7 Mon Sep 17 00:00:00 2001 From: jjoshua2 Date: Tue, 8 May 2018 10:35:45 -0400 Subject: [PATCH 3/4] Update UCTSearch.cpp ensure not target time not over max time so pruning will still work if max time cuts search off early --- src/UCTSearch.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/UCTSearch.cpp b/src/UCTSearch.cpp index 19a5801c3..bed0ceaa9 100644 --- a/src/UCTSearch.cpp +++ b/src/UCTSearch.cpp @@ -405,10 +405,15 @@ Move UCTSearch::think(BoardHistory&& new_bh) { #endif // set up timing info - Time.init(bh_.cur().side_to_move(), bh_.cur().game_ply()); - m_target_time = (Limits.movetime ? Limits.movetime : (int)(1.5*Time.optimum())) - cfg_lagbuffer_ms; m_max_time = Time.maximum() - cfg_lagbuffer_ms; + + if (Limits.movetime) { + m_target_time = Limits.movetime; + } else { + m_target_time = std::min( (int)(1.5*Time.optimum()), m_max_time ); + } + m_start_time = Limits.timeStarted(); // create a sorted list of legal moves (make sure we From 407942b7ca99063b5e16baa737334100ea861fa7 Mon Sep 17 00:00:00 2001 From: jjoshua2 Date: Tue, 8 May 2018 10:41:22 -0400 Subject: [PATCH 4/4] Update UCTSearch.cpp --- src/UCTSearch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/UCTSearch.cpp b/src/UCTSearch.cpp index bed0ceaa9..369221bdb 100644 --- a/src/UCTSearch.cpp +++ b/src/UCTSearch.cpp @@ -411,7 +411,7 @@ Move UCTSearch::think(BoardHistory&& new_bh) { if (Limits.movetime) { m_target_time = Limits.movetime; } else { - m_target_time = std::min( (int)(1.5*Time.optimum()), m_max_time ); + m_target_time = std::min( (int64_t)(1.5*Time.optimum()), m_max_time ); } m_start_time = Limits.timeStarted();