File predictor_probability_label_wise.hpp

namespace boosting
class ILabelWiseProbabilityPredictorConfig
#include <predictor_probability_label_wise.hpp>

Defines an interface for all classes that allow to configure a predictor that predicts label-wise probabilities for given query examples by transforming the regression scores that are predicted for each label individually into probabilities.

Subclassed by boosting::LabelWiseProbabilityPredictorConfig

Public Functions

inline virtual ~ILabelWiseProbabilityPredictorConfig()
virtual bool isProbabilityCalibrationModelUsed() const = 0

Returns whether a model for the calibration of probabilities is used, if available, or not.

Returns:

True, if a model for the calibration of probabilities is used, if available, false otherwise

virtual ILabelWiseProbabilityPredictorConfig &setUseProbabilityCalibrationModel(bool useProbabilityCalibrationModel) = 0

Sets whether a model for the calibration of probabilities should be used, if available, or not.

Parameters:

useProbabilityCalibrationModel – True, if a model for the calibration of probabilities should be used, if available, false otherwise

Returns:

A reference to an object of type ILabelWiseProbabilityPredictorConfig that allows further configuration of the predictor

class LabelWiseProbabilityPredictorConfig : public boosting::ILabelWiseProbabilityPredictorConfig, public IProbabilityPredictorConfig
#include <predictor_probability_label_wise.hpp>

Allows to configure a predictor that predicts label-wise probabilities for given query examples by transforming the regression scores that are predicted for each label individually into probabilities.

summing up the scores that are provided by individual rules of an existing rule-based model and transforming the aggregated scores into probabilities in [0, 1] according to a certain transformation function that is applied to each label individually.

Public Functions

LabelWiseProbabilityPredictorConfig(const std::unique_ptr<ILossConfig> &lossConfigPtr, const std::unique_ptr<IMultiThreadingConfig> &multiThreadingConfigPtr)
Parameters:
  • lossConfigPtr – A reference to an unique pointer that stores the configuration of the loss function

  • multiThreadingConfigPtr – A reference to an unique pointer that stores the configuration of the multi-threading behavior that should be used to predict for several query examples in parallel

virtual bool isProbabilityCalibrationModelUsed() const override

Returns whether a model for the calibration of probabilities is used, if available, or not.

Returns:

True, if a model for the calibration of probabilities is used, if available, false otherwise

virtual ILabelWiseProbabilityPredictorConfig &setUseProbabilityCalibrationModel(bool useProbabilityCalibrationModel) override

Sets whether a model for the calibration of probabilities should be used, if available, or not.

Parameters:

useProbabilityCalibrationModel – True, if a model for the calibration of probabilities should be used, if available, false otherwise

Returns:

A reference to an object of type ILabelWiseProbabilityPredictorConfig that allows further configuration of the predictor

std::unique_ptr<IProbabilityPredictorFactory> createPredictorFactory(const IRowWiseFeatureMatrix &featureMatrix, uint32 numLabels) const override

See also

IProbabilityPredictorConfig::createPredictorFactory

bool isLabelVectorSetNeeded() const override

See also

IPredictorConfig::isLabelVectorSetNeeded

Private Members

std::unique_ptr<IMarginalProbabilityCalibrationModel> noMarginalProbabilityCalibrationModelPtr_
const std::unique_ptr<ILossConfig> &lossConfigPtr_
const std::unique_ptr<IMultiThreadingConfig> &multiThreadingConfigPtr_