13 #ifndef MLPACK_CORE_TREE_RECTANGLE_TREE_X_TREE_AUXILIARY_INFORMATION_HPP
14 #define MLPACK_CORE_TREE_RECTANGLE_TREE_X_TREE_AUXILIARY_INFORMATION_HPP
23 template<
typename TreeType>
29 normalNodeMaxNumChildren(0),
39 normalNodeMaxNumChildren(node->Parent() ?
41 node->MaxNumChildren()),
42 splitHistory(node->Bound().Dim())
81 splitHistory(std::move(other.splitHistory))
83 other.normalNodeMaxNumChildren = 0;
176 for (
int i = 0; i < dim; i++)
196 other.lastDimension = 0;
199 template<
typename Archive>
209 size_t normalNodeMaxNumChildren;
226 template<
typename Archive>
231 ar &
CreateNVP(normalNodeMaxNumChildren,
"normalNodeMaxNumChildren");
232 ar &
CreateNVP(splitHistory,
"splitHistory");
240 #endif // MLPACK_CORE_TREE_RECTANGLE_TREE_X_TREE_AUXILIARY_INFORMATION_HPP
FirstShim< T > CreateNVP(T &t, const std::string &name, typename boost::enable_if< HasSerialize< T >>::type *=0)
Call this function to produce a name-value pair; this is similar to BOOST_SERIALIZATION_NVP(), but should be used for types that have a Serialize() function (or contain a type that has a Serialize() function) instead of a serialize() function.
SplitHistoryStruct(int dim)
SplitHistoryStruct(SplitHistoryStruct &&other)
SplitHistoryStruct & operator=(const SplitHistoryStruct &other)
The X tree requires that the tree records it's "split history".
std::vector< bool > history
SplitHistoryStruct(const SplitHistoryStruct &other)
void Serialize(Archive &ar, const unsigned int)