22 #ifndef __LOGIT_BOOST_PREDICT_H__
23 #define __LOGIT_BOOST_PREDICT_H__
25 #include "algorithms/algorithm.h"
26 #include "algorithms/boosting/boosting_predict.h"
27 #include "algorithms/boosting/logitboost_model.h"
28 #include "algorithms/boosting/logitboost_predict_types.h"
69 template<
typename algorithmFPType, Method method, CpuType cpu>
70 class DAAL_EXPORT BatchContainer :
public PredictionContainerIface
77 BatchContainer(daal::services::Environment::env *daalEnv);
83 services::Status compute() DAAL_C11_OVERRIDE;
106 template<
typename algorithmFPType = DAAL_ALGORITHM_FP_TYPE, Method method = defaultDense>
107 class Batch :
public boosting::prediction::Batch
110 typedef boosting::prediction::Batch super;
112 typedef algorithms::logitboost::prediction::Input InputType;
113 typedef algorithms::logitboost::Parameter ParameterType;
114 typedef typename super::ResultType ResultType;
117 ParameterType parameter;
123 Batch(
size_t nClasses)
126 parameter.nClasses = nClasses;
135 Batch(
const Batch<algorithmFPType, method> &other) : boosting::prediction::Batch(other),
136 input(other.input), parameter(other.parameter)
147 InputType * getInput() DAAL_C11_OVERRIDE {
return &input; }
153 virtual int getMethod() const DAAL_C11_OVERRIDE {
return(
int)method; }
160 services::SharedPtr<Batch<algorithmFPType, method> > clone()
const
162 return services::SharedPtr<Batch<algorithmFPType, method> >(cloneImpl());
166 virtual Batch<algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
168 return new Batch<algorithmFPType, method>(*this);
171 services::Status allocateResult() DAAL_C11_OVERRIDE
173 services::Status s = _result->allocate<algorithmFPType>(&input, 0, 0);
174 _res = _result.get();
181 _ac =
new __DAAL_ALGORITHM_CONTAINER(batch, BatchContainer, algorithmFPType, method)(&_env);
187 using interface1::BatchContainer;
188 using interface1::Batch;
daal::algorithms::logitboost::prediction::Method
Method
Definition: logitboost_predict.h:50
daal
Definition: algorithm_base_common.h:31
daal::algorithms::logitboost::prediction::interface1::Batch::parameter
ParameterType parameter
Definition: logitboost_predict.h:117
daal::algorithms::logitboost::prediction::interface1::Batch::input
InputType input
Definition: logitboost_predict.h:116
daal::algorithms::logitboost::prediction::interface1::Batch::clone
services::SharedPtr< Batch< algorithmFPType, method > > clone() const
Definition: logitboost_predict.h:160
daal::algorithms::PredictionContainerIface
Abstract interface class that provides virtual methods to access and run implementations of the algor...
Definition: prediction.h:40
daal::algorithms::logitboost::prediction::interface1::Batch::Batch
Batch(size_t nClasses)
Definition: logitboost_predict.h:123
daal::batch
Definition: daal_defines.h:106
daal::algorithms::logitboost::prediction::interface1::Batch::getMethod
virtual int getMethod() const DAAL_C11_OVERRIDE
Definition: logitboost_predict.h:153
daal::algorithms::classifier::prediction::prediction
Definition: classifier_predict_types.h:76
daal::algorithms::logitboost::prediction::interface1::BatchContainer
Provides methods to run implementations of the LogitBoost algorithm. This class is associated with da...
Definition: logitboost_predict.h:70
daal::algorithms::logitboost::prediction::interface1::Batch
Predicts LogitBoost classification results.
Definition: logitboost_predict.h:107
daal::algorithms::logitboost::prediction::interface1::Batch::Batch
Batch(const Batch< algorithmFPType, method > &other)
Definition: logitboost_predict.h:135
daal::algorithms::logitboost::prediction::interface1::Batch::getInput
InputType * getInput() DAAL_C11_OVERRIDE
Definition: logitboost_predict.h:147
daal::algorithms::logitboost::prediction::defaultDense
Definition: logitboost_predict.h:52