Skip to content

Commit

Permalink
Tune speculative pruning margins
Browse files Browse the repository at this point in the history
Based on ~115k games with the auto tuner. Causes _massive_ pruning
compared to original values. Apparently this is still better than the
inevtibale misses that this induces in the search.
  • Loading branch information
bsamseth committed Aug 21, 2024
1 parent 8a6c964 commit 7ee80e3
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions engine/src/opts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,46 +23,46 @@ pub struct Opts {
pub threads: usize,

// Time control options:
#[uci(default = "40", kind = "spin", min = "1", max = "100")]
#[uci(kind = "spin", min = "1", max = "100", default = "40")]
pub tc_default_moves_to_go: usize,
#[uci(default = "95", kind = "spin", min = "1", max = "100")]
#[uci(kind = "spin", min = "1", max = "100", default = "95")]
pub tc_time_buffer_percentage: usize,
#[uci(default = "25", kind = "spin", min = "0", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "25")]
pub tc_min_search_time_ms: usize,

// Search speculation options:
//
/// Futility margin max depth.
#[uci(default = "5", kind = "spin", min = "1", max = "5")]
#[uci(kind = "spin", min = "1", max = "5", default = "5")]
pub futility_margin_max_depth: Depth,
/// Futility margin base in centipawns.
#[uci(default = "250", kind = "spin", min = "100", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "17")]
pub futility_margin_base: Value,
/// Futility margin per-depth in centipawns.
#[uci(default = "300", kind = "spin", min = "50", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "100")]
pub futility_margin_per_depth: Value,
/// Razor margin base in centipawns.
#[uci(default = "450", kind = "spin", min = "100", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "323")]
pub razor_margin_base: Value,
/// Razor margin per-depth in centipawns.
#[uci(default = "300", kind = "spin", min = "50", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "249")]
pub razor_margin_per_depth: Value,
/// Delta pruning margin in centipawns.
#[uci(default = "250", kind = "spin", min = "0", max = "1000")]
#[uci(kind = "spin", min = "0", max = "1000", default = "12")]
pub delta_margin: Value,
/// Internal iterative deepening depth reduction.
#[uci(default = "2", kind = "spin", min = "1", max = "5")]
#[uci(kind = "spin", min = "1", max = "5", default = "2")]
pub iid_depth_reduction: Depth,
/// Internal iterative deepening lower depth limit.
#[uci(default = "5", kind = "spin", min = "5", max = "10")]
#[uci(kind = "spin", min = "5", max = "10", default = "5")]
pub iid_depth_lower_bound: Depth,

// Move ordering options:
//
/// How many centipawns bonus to give to moves that are the most frequent in history stats.
/// Other moves will be given a bonus scaled linearly on how frequent they are compared to the
/// most frequent move square.
#[uci(default = "10", kind = "spin", min = "0", max = "100")]
#[uci(kind = "spin", min = "0", max = "100", default = "10")]
pub max_history_stats_impact: usize,
}

Expand Down

0 comments on commit 7ee80e3

Please sign in to comment.