diff --git a/src/mlpack/methods/random_forest/random_forest.hpp b/src/mlpack/methods/random_forest/random_forest.hpp index 23673a9592..f3aea15896 100644 --- a/src/mlpack/methods/random_forest/random_forest.hpp +++ b/src/mlpack/methods/random_forest/random_forest.hpp @@ -179,7 +179,8 @@ class RandomForest const double minimumGainSplit = 1e-7, const size_t maximumDepth = 0, DimensionSelectionType dimensionSelector = - DimensionSelectionType()); + DimensionSelectionType(), + bool warmStart = false); /** * Train the random forest on the given labeled training data with the given @@ -211,7 +212,8 @@ class RandomForest const double minimumGainSplit = 1e-7, const size_t maximumDepth = 0, DimensionSelectionType dimensionSelector = - DimensionSelectionType()); + DimensionSelectionType(), + bool warmStart = false); /** * Train the random forest on the given weighted labeled training data with @@ -241,7 +243,8 @@ class RandomForest const double minimumGainSplit = 1e-7, const size_t maximumDepth = 0, DimensionSelectionType dimensionSelector = - DimensionSelectionType()); + DimensionSelectionType(), + bool warmStart = false); /** * Train the random forest on the given weighted labeled training data with @@ -274,7 +277,8 @@ class RandomForest const double minimumGainSplit = 1e-7, const size_t maximumDepth = 0, DimensionSelectionType dimensionSelector = - DimensionSelectionType()); + DimensionSelectionType(), + bool warmStart = false); /** * Predict the class of the given point. If the random forest has not been diff --git a/src/mlpack/methods/random_forest/random_forest_impl.hpp b/src/mlpack/methods/random_forest/random_forest_impl.hpp index d79b252791..da2c6ef470 100644 --- a/src/mlpack/methods/random_forest/random_forest_impl.hpp +++ b/src/mlpack/methods/random_forest/random_forest_impl.hpp @@ -160,7 +160,8 @@ double RandomForest< const size_t minimumLeafSize, const double minimumGainSplit, const size_t maximumDepth, - DimensionSelectionType dimensionSelector) + DimensionSelectionType dimensionSelector, + bool warmStart) { // Pass off to Train(). data::DatasetInfo info; // Ignored by Train(). @@ -192,7 +193,8 @@ double RandomForest< const size_t minimumLeafSize, const double minimumGainSplit, const size_t maximumDepth, - DimensionSelectionType dimensionSelector) + DimensionSelectionType dimensionSelector, + bool warmStart) { // Pass off to Train(). arma::rowvec weights; // Ignored by Train(). @@ -223,7 +225,8 @@ double RandomForest< const size_t minimumLeafSize, const double minimumGainSplit, const size_t maximumDepth, - DimensionSelectionType dimensionSelector) + DimensionSelectionType dimensionSelector, + bool warmStart) { // Pass off to Train(). data::DatasetInfo info; // Ignored by Train(). @@ -255,7 +258,8 @@ double RandomForest< const size_t minimumLeafSize, const double minimumGainSplit, const size_t maximumDepth, - DimensionSelectionType dimensionSelector) + DimensionSelectionType dimensionSelector, + bool warmStart) { // Pass off to Train(). return Train(dataset, datasetInfo, labels, numClasses, weights,