1 #ifndef SAMPLING_TO_FUNCTION_SELECTOR_H 2 #define SAMPLING_TO_FUNCTION_SELECTOR_H 4 #include "sampling_selector.hpp" 15 template <
typename Context,
typename Config>
30 :
threshold(threshold_), function_strat(function_strat_),
35 : function_strat->
select(node);
SamplingToFunctionSelector(int threshold_, sstrategy_t *function_strat_)
create new selector
node_t * select(node_t *node)
randomly chooses a child of node
selector that chooses random children uniformly
interface for all selection strategies. A selection strategy selects one child of a parent node accor...
basic interface for a node in the tree. Every node has to implement this functions.
node_t * select(node_t *node)
select a child of node
Uses sampling selector until threshold is reached. After that a supplied selection strategy is applie...
virtual int nb_samples() const =0
number of times a selection strategy selected the current node.
int threshold
number of samples before the strategy is switched.
virtual node_t * select(node_t *node)=0
select a child of node