C++ API Reference for Intel® Data Analytics Acceleration Library 2019 Update 5

decision_tree_regression_predict_types.h
1 /* file: decision_tree_regression_predict_types.h */
2 /*******************************************************************************
3 * Copyright 2014-2019 Intel Corporation.
4 *
5 * This software and the related documents are Intel copyrighted materials, and
6 * your use of them is governed by the express license under which they were
7 * provided to you (License). Unless the License provides otherwise, you may not
8 * use, modify, copy, publish, distribute, disclose or transmit this software or
9 * the related documents without Intel's prior written permission.
10 *
11 * This software and the related documents are provided as is, with no express
12 * or implied warranties, other than those that are expressly stated in the
13 * License.
14 *******************************************************************************/
15 
16 /*
17 //++
18 // Implementation of the Decision tree regression algorithm interface
19 //--
20 */
21 
22 #ifndef __DECISION_TREE_REGRESSION_PREDICT_TYPES_H__
23 #define __DECISION_TREE_REGRESSION_PREDICT_TYPES_H__
24 
25 #include "algorithms/algorithm.h"
26 #include "data_management/data/data_serialize.h"
27 #include "algorithms/decision_tree/decision_tree_regression_model.h"
28 #include "algorithms/regression/regression_predict_types.h"
29 
30 namespace daal
31 {
32 namespace algorithms
33 {
34 
38 namespace decision_tree
39 {
40 
44 namespace regression
45 {
46 
56 namespace prediction
57 {
58 
63 enum Method
64 {
65  defaultDense = 0
66 };
67 
72 enum NumericTableInputId
73 {
74  data = algorithms::regression::prediction::data,
75  lastNumericTableInputId = data
76 };
77 
82 enum ModelInputId
83 {
84  model = algorithms::regression::prediction::model,
85  lastModelInputId = model
86 };
87 
92 enum ResultId
93 {
94  prediction = algorithms::regression::prediction::prediction,
95  lastResultId = prediction
96 };
97 
101 namespace interface1
102 {
103 
108 class DAAL_EXPORT Input : public algorithms::regression::prediction::Input
109 {
110 public:
111  Input();
112  Input(const Input &other);
113 
119  data_management::NumericTablePtr get(NumericTableInputId id) const;
120 
126  ModelPtr get(ModelInputId id) const;
127 
133  void set(NumericTableInputId id, const data_management::NumericTablePtr & ptr);
134 
140  void set(ModelInputId id, const ModelPtr & value);
141 
147  services::Status check(const daal::algorithms::Parameter * parameter, int method) const DAAL_C11_OVERRIDE;
148 };
149 
154 class DAAL_EXPORT Result : public algorithms::regression::prediction::Result
155 {
156 public:
157  DECLARE_SERIALIZABLE_CAST(Result);
158  Result();
159 
165  data_management::NumericTablePtr get(ResultId id) const;
166 
172  void set(ResultId id, const data_management::NumericTablePtr &value);
173 
180  template <typename algorithmFPType>
181  DAAL_EXPORT services::Status allocate(const daal::algorithms::Input * input, const daal::algorithms::Parameter * par, const int method);
182 
189  services::Status check(const daal::algorithms::Input * input, const daal::algorithms::Parameter * par, int method) const DAAL_C11_OVERRIDE;
190 
191 protected:
193  template<typename Archive, bool onDeserialize>
194  services::Status serialImpl(Archive *arch)
195  {
196  return daal::algorithms::Result::serialImpl<Archive, onDeserialize>(arch);
197  }
198 };
199 
200 typedef services::SharedPtr<Result> ResultPtr;
201 typedef services::SharedPtr<const Result> ResultConstPtr;
202 
203 } // namespace interface1
204 
205 using interface1::Input;
206 using interface1::Result;
207 using interface1::ResultPtr;
208 using interface1::ResultConstPtr;
209 
210 } // namespace prediction
212 } // namespace regression
213 } // namespace decision_tree
214 } // namespace algorithms
215 } // namespace daal
216 
217 #endif
daal::algorithms::decision_tree::regression::prediction::ModelInputId
ModelInputId
Available identifiers of input models for making decision tree model-based prediction.
Definition: decision_tree_regression_predict_types.h:82
daal::algorithms::decision_tree::regression::prediction::prediction
Definition: decision_tree_regression_predict_types.h:94
daal::algorithms::decision_tree::regression::prediction::NumericTableInputId
NumericTableInputId
Available identifiers of input numeric tables for making decision tree model-based prediction...
Definition: decision_tree_regression_predict_types.h:72
daal
Definition: algorithm_base_common.h:31
daal::algorithms::decision_tree::regression::prediction::data
Definition: decision_tree_regression_predict_types.h:74
daal::algorithms::decision_tree::regression::prediction::interface1::Input
Provides an interface for input objects for making Decision tree model-based prediction.
Definition: decision_tree_regression_predict_types.h:108
daal::algorithms::decision_tree::regression::prediction::defaultDense
Definition: decision_tree_regression_predict_types.h:65
daal::algorithms::decision_tree::regression::prediction::model
Definition: decision_tree_regression_predict_types.h:84
daal::algorithms::regression::prediction::prediction
Definition: regression_predict_types.h:72
daal::algorithms::regression::prediction::data
Definition: regression_predict_types.h:52
daal::algorithms::decision_tree::regression::prediction::ResultId
ResultId
Available identifiers of the result for making decision tree model-based prediction.
Definition: decision_tree_regression_predict_types.h:92
daal::algorithms::decision_tree::regression::prediction::Method
Method
Available methods for making Decision tree model-based prediction.
Definition: decision_tree_regression_predict_types.h:63
daal::algorithms::math::abs::value
Definition: abs_types.h:86
daal::algorithms::decision_tree::regression::prediction::interface1::Result
Provides interface for the result of decision tree model-based prediction.
Definition: decision_tree_regression_predict_types.h:154
daal::algorithms::regression::prediction::model
Definition: regression_predict_types.h:62

For more complete information about compiler optimizations, see our Optimization Notice.