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

regression_training_online.h
1 /* file: regression_training_online.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 interface for linear regression model-based training
19 // in the online processing mode
20 //--
21 */
22 
23 #ifndef __REGRESSION_TRAINING_ONLINE_H__
24 #define __REGRESSION_TRAINING_ONLINE_H__
25 
26 #include "algorithms/regression/regression_training_types.h"
27 
28 namespace daal
29 {
30 namespace algorithms
31 {
32 namespace regression
33 {
34 namespace training
35 {
36 
37 namespace interface1
38 {
53 class DAAL_EXPORT Online : public Training<online>
54 {
55 public:
56  typedef algorithms::regression::training::Input InputType;
57  typedef algorithms::regression::training::Result ResultType;
58  typedef algorithms::regression::training::PartialResult PartialResultType;
59 
60  virtual ~Online() {}
61  virtual InputType* getInput() = 0;
62 
69  services::Status setPartialResult(const PartialResultPtr& partialResult)
70  {
71  _partialResult = partialResult;
72  _pres = _partialResult.get();
73  return services::Status();
74  }
75 
82  services::Status setResult(const ResultPtr& res)
83  {
84  DAAL_CHECK(res, services::ErrorNullResult)
85  _result = res;
86  _res = _result.get();
87  return services::Status();
88  }
89 
94  PartialResultPtr getPartialResult() { return _partialResult; }
95 
100  ResultPtr getResult() { return _result; }
101 
102 protected:
103  PartialResultPtr _partialResult;
104  ResultPtr _result;
105 }; // class : public Online
107 } // namespace interface1
108 using interface1::Online;
109 
110 }
111 }
112 }
113 }
114 #endif
daal::algorithms::regression::training::interface1::Online::getPartialResult
PartialResultPtr getPartialResult()
Definition: regression_training_online.h:94
daal
Definition: algorithm_base_common.h:31
daal::algorithms::regression::training::interface1::Online
Provides methods for the regression model-based training in the online processing mode...
Definition: regression_training_online.h:53
daal::algorithms::regression::training::interface1::Online::setPartialResult
services::Status setPartialResult(const PartialResultPtr &partialResult)
Definition: regression_training_online.h:69
daal::algorithms::regression::training::interface1::Online::setResult
services::Status setResult(const ResultPtr &res)
Definition: regression_training_online.h:82
daal::services::ErrorNullResult
Definition: error_indexes.h:96
daal::algorithms::regression::training::interface1::Online::getResult
ResultPtr getResult()
Definition: regression_training_online.h:100
daal::algorithms::Training
Provides methods to train models that depend on the data provided. For example, these methods enable ...
Definition: training.h:60

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