pub trait SelectionFunction: Fn(f32, i32, i32, f32, f32) -> f32 { }Expand description
Evaluates a child node during the tree selection phase.
This function determines whether the current node should be prioritized. It typically implements an exploration/exploitation balance formula such as UCB1.
§Arguments
score- The score value of the child node (w).node_visits- The number of visits to the currently evaluated child node (n).parent_visits- The total number of visits to the parent node (N).policy- The exploration policy value.c- The exploration constant used to adjust the ratio (often sqrt(2)).
§Returns
Returns a floating-point score representing the node’s priority
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".