12 #ifndef MLPACK_METHODS_DECISION_TREE_MULTIPLE_RANDOM_DIMENSION_SPLIT_HPP 13 #define MLPACK_METHODS_DECISION_TREE_MULTIPLE_RANDOM_DIMENSION_SPLIT_HPP 25 template<
size_t NumDimensions = 3>
34 for (
size_t i = 0; i < NumDimensions; ++i)
45 for (
size_t j = 0; j < i; ++j)
47 if (values[j] == value)
58 values[NumDimensions] = std::numeric_limits<size_t>::max();
73 size_t End()
const {
return size_t(-1); }
85 size_t values[NumDimensions + 1];
This dimension selection policy allows the selection from a few random dimensions.
MultipleRandomDimensionSelect(const size_t dimensions)
Instantiate the MultipleRandomDimensionSelect object.
size_t Next()
Get the next index.
int RandInt(const int hiExclusive)
Generates a uniform random integer.
size_t End() const
Get the last random value.
size_t Begin()
Get the first random value.