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

pca_transform_types.h
1 /* file: pca_transform_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 // Definition of PCA transform common types.
19 //--
20 */
21 
22 
23 #ifndef __PCA_TRANSFORM_TYPES_H__
24 #define __PCA_TRANSFORM_TYPES_H__
25 
26 #include "algorithms/algorithm.h"
27 #include "data_management/data/numeric_table.h"
28 #include "data_management/data/homogen_numeric_table.h"
29 #include "services/daal_defines.h"
30 
31 namespace daal
32 {
33 namespace algorithms
34 {
35 namespace pca
36 {
45 namespace transform
46 {
51 enum Method
52 {
53  defaultDense = 0
54 };
55 
60 enum InputId
61 {
62  data = 0,
63  eigenvectors,
64  lastInputId = eigenvectors
65 };
66 
71 enum TransformComponentId
72 {
73  mean = 0x00000001ULL,
74  variance = 0x00000002ULL,
75  eigenvalue = 0x00000004ULL
76 };
77 
82 enum TransformDataInputId
83 {
84  dataForTransform = lastInputId + 1,
85  lastdataForTransformInputId = dataForTransform
86 };
87 
92 enum ResultId
93 {
94  transformedData = 0,
95  lastResultId = transformedData
96 };
97 
98 
102 namespace interface1
103 {
109 class DAAL_EXPORT Input : public daal::algorithms::Input
110 {
111 public:
113  Input();
114 
116  Input(const Input& other);
117 
119  virtual ~Input() {}
120 
126  data_management::NumericTablePtr get(InputId id) const;
127 
133  data_management::KeyValueDataCollectionPtr get(TransformDataInputId id) const;
134 
141  data_management::NumericTablePtr get(TransformDataInputId wid, TransformComponentId id) const;
142 
148  void set(InputId id, const data_management::NumericTablePtr &value);
149 
155  void set(TransformDataInputId id, const data_management::KeyValueDataCollectionPtr &value);
156 
163  void set(TransformDataInputId wid, TransformComponentId id, const data_management::NumericTablePtr &value);
164 
170  virtual services::Status check(const daal::algorithms::Parameter *parameter, int method) const DAAL_C11_OVERRIDE;
171 };
172 
173 
180 class DAAL_EXPORT Result : public daal::algorithms::Result
181 {
182 public:
183  DECLARE_SERIALIZABLE_CAST(Result);
185  Result();
187  virtual ~Result() {}
188 
194  data_management::NumericTablePtr get(ResultId id) const;
195 
202  template <typename algorithmFPType>
203  DAAL_EXPORT services::Status allocate(const daal::algorithms::Input *input, const daal::algorithms::Parameter *parameter, const int method);
204 
205 
211  void set(ResultId id, const data_management::NumericTablePtr &value);
212 
219  virtual services::Status check(const daal::algorithms::Input *input, const daal::algorithms::Parameter *par, int method) const DAAL_C11_OVERRIDE;
220 
221 };
222 typedef services::SharedPtr<daal::algorithms::pca::transform::interface1::Result> ResultPtr;
223 
228 struct DAAL_EXPORT Parameter : public daal::algorithms::Parameter
229 {
234  Parameter(size_t nComponents = 0);
235 
239  size_t nComponents;
240 };
243 } // namespace interface1
244 using interface1::Input;
245 using interface1::Result;
246 using interface1::ResultPtr;
247 using interface1::Parameter;
248 
249 } // namespace daal::algorithms::transform
250 } // namespace daal::algorithms::pca
251 } // namespace daal::algorithms
252 } // namespace daal
253 #endif
daal::algorithms::pca::transform::interface1::Parameter
Parameters for the PCA transformation compute method.
Definition: pca_transform_types.h:228
daal::algorithms::pca::transform::TransformComponentId
TransformComponentId
Definition: pca_transform_types.h:71
daal
Definition: algorithm_base_common.h:31
daal::algorithms::pca::transform::data
Definition: pca_transform_types.h:62
daal::algorithms::pca::transform::eigenvectors
Definition: pca_transform_types.h:63
daal::algorithms::pca::transform::interface1::Input
Input objects for the PCA transformation algorithm in the batch and online processing modes and for t...
Definition: pca_transform_types.h:109
daal::algorithms::pca::transform::eigenvalue
Definition: pca_transform_types.h:75
daal::algorithms::pca::transform::transformedData
Definition: pca_transform_types.h:94
daal::algorithms::pca::transform::Method
Method
Definition: pca_transform_types.h:51
daal_defines.h
daal::algorithms::pca::transform::interface1::Input::~Input
virtual ~Input()
Definition: pca_transform_types.h:119
daal::algorithms::pca::transform::interface1::Result
Provides methods to access final results obtained with the compute() method of the PCA transformation...
Definition: pca_transform_types.h:180
daal::algorithms::pca::transform::interface1::Parameter::nComponents
size_t nComponents
Definition: pca_transform_types.h:239
daal::algorithms::pca::transform::TransformDataInputId
TransformDataInputId
Definition: pca_transform_types.h:82
daal::algorithms::pca::transform::InputId
InputId
Definition: pca_transform_types.h:60
daal::algorithms::pca::transform::mean
Definition: pca_transform_types.h:73
daal::algorithms::math::abs::value
Definition: abs_types.h:86
daal::algorithms::pca::transform::defaultDense
Definition: pca_transform_types.h:53
daal::algorithms::pca::transform::dataForTransform
Definition: pca_transform_types.h:84
daal::algorithms::pca::transform::interface1::Result::~Result
virtual ~Result()
Definition: pca_transform_types.h:187
daal::algorithms::pca::transform::ResultId
ResultId
Definition: pca_transform_types.h:92
daal::algorithms::pca::transform::variance
Definition: pca_transform_types.h:74

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