13#ifndef MLPACK_METHODS_DECISION_TREE_ALL_CATEGORICAL_SPLIT_HPP
14#define MLPACK_METHODS_DECISION_TREE_ALL_CATEGORICAL_SPLIT_HPP
27template<
typename FitnessFunction>
32 template<
typename ElemType>
57 template<
bool UseWeights,
typename VecType,
typename WeightVecType>
59 const double bestGain,
61 const size_t numCategories,
62 const arma::Row<size_t>& labels,
63 const size_t numClasses,
64 const WeightVecType& weights,
65 const size_t minimumLeafSize,
66 const double minimumGainSplit,
67 arma::Col<typename VecType::elem_type>& classProbabilities,
76 template<
typename ElemType>
77 static size_t NumChildren(
const arma::Col<ElemType>& classProbabilities,
87 template<
typename ElemType>
89 const ElemType& point,
90 const arma::Col<ElemType>& classProbabilities,
98#include "all_categorical_split_impl.hpp"
The AllCategoricalSplit is a splitting function that will split categorical features into many childr...
static double SplitIfBetter(const double bestGain, const VecType &data, const size_t numCategories, const arma::Row< size_t > &labels, const size_t numClasses, const WeightVecType &weights, const size_t minimumLeafSize, const double minimumGainSplit, arma::Col< typename VecType::elem_type > &classProbabilities, AuxiliarySplitInfo< typename VecType::elem_type > &aux)
Check if we can split a node.
static size_t CalculateDirection(const ElemType &point, const arma::Col< ElemType > &classProbabilities, const AuxiliarySplitInfo< ElemType > &)
Calculate the direction a point should percolate to.
static size_t NumChildren(const arma::Col< ElemType > &classProbabilities, const AuxiliarySplitInfo< ElemType > &)
Return the number of children in the split.
Linear algebra utility functions, generally performed on matrices or vectors.
The core includes that mlpack expects; standard C++ includes and Armadillo.