File rule_evaluation_decomposable_single.hpp

namespace boosting
class DecomposableSingleOutputRuleEvaluationFactory : public boosting::ISparseDecomposableRuleEvaluationFactory
#include <rule_evaluation_decomposable_single.hpp>

Allows to create instances of the class ISparseDecomposableRuleEvaluationFactory that allow to calculate the predictions of single-output rules, which predict for a single output.

Public Functions

DecomposableSingleOutputRuleEvaluationFactory(float64 l1RegularizationWeight, float64 l2RegularizationWeight)
Parameters:
  • l1RegularizationWeight – The weight of the L1 regularization that is applied for calculating the scores to be predicted by rules

  • l2RegularizationWeight – The weight of the L2 regularization that is applied for calculating the scores to be predicted by rules

virtual std::unique_ptr<IRuleEvaluation<DenseDecomposableStatisticVector>> create(const DenseDecomposableStatisticVector &statisticVector, const CompleteIndexVector &indexVector) const override

Creates a new instance of the class IRuleEvaluation that allows to calculate the predictions of rules that predict for all available outputs, based on the gradients and Hessians that are stored by a DenseDecomposableStatisticVector.

Parameters:
  • statisticVector – A reference to an object of type DenseDecomposableStatisticVector. This vector is only used to identify the function that is able to deal with this particular type of vector via function overloading

  • indexVector – A reference to an object of the type CompleteIndexVector that provides access to the indices of the outputs for which the rules may predict

Returns:

An unique pointer to an object of type IRuleEvaluation that has been created

virtual std::unique_ptr<IRuleEvaluation<DenseDecomposableStatisticVector>> create(const DenseDecomposableStatisticVector &statisticVector, const PartialIndexVector &indexVector) const override

Creates a new instance of the class IRuleEvaluation that allows to calculate the predictions of rules that predict for a subset of the available outputs, based on the gradients and Hessians that are stored by a DenseDecomposableStatisticVector.

Parameters:
  • statisticVector – A reference to an object of type DenseDecomposableStatisticVector. This vector is only used to identify the function that is able to deal with this particular type of vector via function overloading

  • indexVector – A reference to an object of the type PartialIndexVector that provides access to the indices of the outputs for which the rules may predict

Returns:

An unique pointer to an object of type IRuleEvaluation that has been created

virtual std::unique_ptr<IRuleEvaluation<SparseDecomposableStatisticVector>> create(const SparseDecomposableStatisticVector &statisticVector, const CompleteIndexVector &indexVector) const override

Creates a new instance of the class IRuleEvaluation that allows to calculate the predictions of rules that predict for all available outputs, based on the gradients and Hessians that are stored by a SparseDecomposableStatisticVector.

Parameters:
  • statisticVector – A reference to an object of type SparseDecomposableStatisticVector. This vector is only used to identify the function that is able to deal with this particular type of vector via function overloading

  • indexVector – A reference to an object of the type CompleteIndexVector that provides access to the indices of the outputs for which the rules may predict

Returns:

An unique pointer to an object of type IRuleEvaluation that has been created

virtual std::unique_ptr<IRuleEvaluation<SparseDecomposableStatisticVector>> create(const SparseDecomposableStatisticVector &statisticVector, const PartialIndexVector &indexVector) const override

Creates a new instance of the class IRuleEvaluation that allows to calculate the predictions of rules that predict for a subset of the available outputs, based on the gradients and Hessians that are stored by a SparseDecomposableStatisticVector.

Parameters:
  • statisticVector – A reference to an object of type SparseDecomposableStatisticVector. This vector is only used to identify the function that is able to deal with this particular type of vector via function overloading

  • indexVector – A reference to an object of the type PartialIndexVector that provides access to the indices of the outputs for which the rules may predict

Returns:

An unique pointer to an object of type IRuleEvaluation that has been created

Private Members

const float64 l1RegularizationWeight_
const float64 l2RegularizationWeight_