C++ API Reference for Intel® Data Analytics Acceleration Library 2018 Update 3

kmeans_init_distributed.h
1 /* file: kmeans_init_distributed.h */
2 /*******************************************************************************
3 * Copyright 2014-2018 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 initializing the K-Means algorithm
19 // in the distributed processing mode
20 //--
21 */
22 
23 #ifndef __KMEANS_INIT_DISTRIBITED_H__
24 #define __KMEANS_INIT_DISTRIBITED_H__
25 
26 #include "algorithms/algorithm.h"
27 #include "data_management/data/numeric_table.h"
28 #include "services/daal_defines.h"
29 #include "algorithms/kmeans/kmeans_init_types.h"
30 
31 namespace daal
32 {
33 namespace algorithms
34 {
35 namespace kmeans
36 {
37 namespace init
38 {
39 
40 namespace interface1
41 {
56 template<ComputeStep step, typename algorithmFPType, Method method, CpuType cpu>
57 class DAAL_EXPORT DistributedContainer;
58 
63 template<typename algorithmFPType, Method method, CpuType cpu>
64 class DAAL_EXPORT DistributedContainer<step1Local, algorithmFPType, method, cpu> : public
65  daal::algorithms::AnalysisContainerIface<distributed>
66 {
67 public:
73  DistributedContainer(daal::services::Environment::env *daalEnv);
75  virtual ~DistributedContainer();
80  virtual services::Status compute() DAAL_C11_OVERRIDE;
85  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
86 };
87 
92 template<typename algorithmFPType, Method method, CpuType cpu>
93 class DAAL_EXPORT DistributedContainer<step2Master, algorithmFPType, method, cpu> : public
94  daal::algorithms::AnalysisContainerIface<distributed>
95 {
96 public:
102  DistributedContainer(daal::services::Environment::env *daalEnv);
104  virtual ~DistributedContainer();
109  virtual services::Status compute() DAAL_C11_OVERRIDE;
114  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
115 };
116 
122 template<typename algorithmFPType, Method method, CpuType cpu>
123 class DAAL_EXPORT DistributedContainer<step2Local, algorithmFPType, method, cpu> : public
124  daal::algorithms::AnalysisContainerIface<distributed>
125 {
126 public:
132  DistributedContainer(daal::services::Environment::env *daalEnv);
134  virtual ~DistributedContainer();
139  virtual services::Status compute() DAAL_C11_OVERRIDE;
144  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
145 };
146 
152 template<typename algorithmFPType, Method method, CpuType cpu>
153 class DAAL_EXPORT DistributedContainer<step3Master, algorithmFPType, method, cpu> : public
154  daal::algorithms::AnalysisContainerIface<distributed>
155 {
156 public:
162  DistributedContainer(daal::services::Environment::env *daalEnv);
164  virtual ~DistributedContainer();
169  virtual services::Status compute() DAAL_C11_OVERRIDE;
174  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
175 };
176 
182 template<typename algorithmFPType, Method method, CpuType cpu>
183 class DAAL_EXPORT DistributedContainer<step4Local, algorithmFPType, method, cpu> : public
184  daal::algorithms::AnalysisContainerIface<distributed>
185 {
186 public:
192  DistributedContainer(daal::services::Environment::env *daalEnv);
194  virtual ~DistributedContainer();
199  virtual services::Status compute() DAAL_C11_OVERRIDE;
204  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
205 };
206 
212 template<typename algorithmFPType, Method method, CpuType cpu>
213 class DAAL_EXPORT DistributedContainer<step5Master, algorithmFPType, method, cpu> : public
214  daal::algorithms::AnalysisContainerIface<distributed>
215 {
216 public:
222  DistributedContainer(daal::services::Environment::env *daalEnv);
224  virtual ~DistributedContainer();
229  virtual services::Status compute() DAAL_C11_OVERRIDE;
234  virtual services::Status finalizeCompute() DAAL_C11_OVERRIDE;
235 };
236 
254 template<ComputeStep step, typename algorithmFPType = DAAL_ALGORITHM_FP_TYPE, Method method = defaultDense>
255 class DAAL_EXPORT Distributed;
256 
274 template<typename algorithmFPType, Method method>
275 class DAAL_EXPORT Distributed<step1Local, algorithmFPType, method> : public daal::algorithms::Analysis<distributed>
276 {
277 public:
278  typedef algorithms::kmeans::init::Input InputType;
279  typedef algorithms::kmeans::init::Parameter ParameterType;
280  typedef algorithms::kmeans::init::Result ResultType;
281  typedef algorithms::kmeans::init::PartialResult PartialResultType;
282 
289  Distributed(size_t nClusters, size_t nRowsTotal, size_t offset = 0) : parameter(nClusters, offset)
290  {
291  initialize();
292  parameter.nRowsTotal = nRowsTotal;
293  }
294 
300  Distributed(const Distributed<step1Local, algorithmFPType, method> &other) : parameter(other.parameter)
301  {
302  initialize();
303  input.set(data, other.input.get(data));
304  }
305 
310  virtual int getMethod() const DAAL_C11_OVERRIDE { return(int) method; }
311 
316  ResultPtr getResult()
317  {
318  return _result;
319  }
320 
325  services::Status setResult(const ResultPtr& result)
326  {
327  DAAL_CHECK(result, services::ErrorNullResult)
328  _result = result;
329  _res = _result.get();
330  return services::Status();
331  }
332 
337  PartialResultPtr getPartialResult()
338  {
339  return _partialResult;
340  }
341 
346  services::Status setPartialResult(const PartialResultPtr& partialRes)
347  {
348  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
349  _partialResult = partialRes;
350  _pres = _partialResult.get();
351  return services::Status();
352  }
353 
357  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
358  {
359  return services::Status();
360  }
361 
367  services::SharedPtr<Distributed<step1Local, algorithmFPType, method> > clone() const
368  {
369  return services::SharedPtr<Distributed<step1Local, algorithmFPType, method> >(cloneImpl());
370  }
371 
372 protected:
373  virtual Distributed<step1Local, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
374  {
375  return new Distributed<step1Local, algorithmFPType, method>(*this);
376  }
377 
378  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
379  {
380  _result.reset(new ResultType());
381  services::Status s = _result->allocate<algorithmFPType>(_pres, _par, (int) method);
382  _res = _result.get();
383  return s;
384  }
385 
386  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
387  {
388  _partialResult.reset(new PartialResultType());
389  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int) method);
390  _pres = _partialResult.get();
391  return s;
392  }
393 
394  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
395  {
396  return services::Status();
397  }
398 
399  void initialize()
400  {
401  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step1Local, algorithmFPType, method)(&_env);
402  _in = &input;
403  _par = &parameter;
404  }
405 
406 public:
407  InputType input;
408  ParameterType parameter;
410 private:
411  PartialResultPtr _partialResult;
412  ResultPtr _result;
413 };
414 
432 template<typename algorithmFPType, Method method>
433 class DAAL_EXPORT Distributed<step2Master, algorithmFPType, method>: public daal::algorithms::Analysis<distributed>
434 {
435 public:
436  typedef algorithms::kmeans::init::DistributedStep2MasterInput InputType;
437  typedef algorithms::kmeans::init::Parameter ParameterType;
438  typedef algorithms::kmeans::init::Result ResultType;
439  typedef algorithms::kmeans::init::PartialResult PartialResultType;
440 
446  Distributed(size_t nClusters, size_t offset = 0) : parameter(nClusters, offset)
447  {
448  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step2Master, algorithmFPType, method)(&_env);
449  _in = &input;
450  _par = &parameter;
451  }
452 
457  virtual int getMethod() const DAAL_C11_OVERRIDE { return(int) method; }
458 
463  ResultPtr getResult()
464  {
465  return _result;
466  }
467 
471  services::Status setResult(const ResultPtr& result)
472  {
473  DAAL_CHECK(result, services::ErrorNullResult)
474  _result = result;
475  _res = _result.get();
476  return services::Status();
477  }
478 
483  PartialResultPtr getPartialResult()
484  {
485  return _partialResult;
486  }
487 
492  services::Status setPartialResult(const PartialResultPtr& partialRes)
493  {
494  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
495  _partialResult = partialRes;
496  _pres = _partialResult.get();
497  return services::Status();
498  }
499 
503  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
504  {
505  services::Status s;
506  if(_partialResult)
507  {
508  s |= _partialResult->check(_par, method);
509  if (!s) { return s; }
510  }
511  else
512  {
513  return services::Status(services::ErrorNullResult);
514  }
515 
516  if(_result)
517  {
518  s |= _result->check(&input, _par, method);
519  }
520  else
521  {
522  return services::Status(services::ErrorNullResult);
523  }
524  return s;
525  }
526 
532  services::SharedPtr<Distributed<step2Master, algorithmFPType, method> > clone() const
533  {
534  return services::SharedPtr<Distributed<step2Master, algorithmFPType, method> >(cloneImpl());
535  }
536 
537 protected:
538  virtual Distributed<step2Master, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
539  {
540  return new Distributed<step2Master, algorithmFPType, method>(*this);
541  }
542 
543  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
544  {
545  _result.reset(new ResultType());
546  services::Status s = _result->allocate<algorithmFPType>(_pres, _par, (int)method);
547  _res = _result.get();
548  return s;
549  }
550 
551  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
552  {
553  _partialResult.reset(new PartialResultType());
554  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int)method);
555  if(!s) return s;
556  _pres = _partialResult.get();
557  if(!_res)
558  {
559  _result.reset(new ResultType());
560  s |= _result->allocate<algorithmFPType>(&input, _par, (int)method);
561  _res = _result.get();
562  }
563  return s;
564  }
565 
566  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
567  {
568  return services::Status();
569  }
570 
571  void initialize()
572  {
573  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step2Master, algorithmFPType, method)(&_env);
574  _in = &input;
575  _par = &parameter;
576  }
577 
578 public:
579  InputType input;
580  ParameterType parameter;
582 private:
583  PartialResultPtr _partialResult;
584  ResultPtr _result;
585 };
586 
608 template<typename algorithmFPType, Method method>
609 class DAAL_EXPORT Distributed<step2Local, algorithmFPType, method> : public daal::algorithms::Analysis<distributed>
610 {
611 public:
612  typedef algorithms::kmeans::init::DistributedStep2LocalPlusPlusInput InputType;
613  typedef algorithms::kmeans::init::DistributedStep2LocalPlusPlusParameter ParameterType;
614  typedef algorithms::kmeans::init::DistributedStep2LocalPlusPlusPartialResult PartialResultType;
615 
621  Distributed(size_t nClusters, bool bFirstIteration) : parameter(nClusters, bFirstIteration)
622  {
623  initialize();
624  }
625 
631  Distributed(const Distributed<step2Local, algorithmFPType, method> &other) : parameter(other.parameter), input(other.input)
632  {
633  initialize();
634  }
635 
640  virtual int getMethod() const DAAL_C11_OVERRIDE{ return(int)method; }
641 
646  DistributedStep2LocalPlusPlusPartialResultPtr getPartialResult()
647  {
648  return _partialResult;
649  }
650 
655  services::Status setPartialResult(const DistributedStep2LocalPlusPlusPartialResultPtr& partialRes)
656  {
657  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
658  _partialResult = partialRes;
659  _pres = _partialResult.get();
660  return services::Status();
661  }
662 
666  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
667  {
668  return services::Status();
669  }
670 
676  services::SharedPtr<Distributed<step2Local, algorithmFPType, method> > clone() const
677  {
678  return services::SharedPtr<Distributed<step2Local, algorithmFPType, method> >(cloneImpl());
679  }
680 
681 protected:
682  virtual Distributed<step2Local, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
683  {
684  return new Distributed<step2Local, algorithmFPType, method>(*this);
685  }
686 
687  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
688  {
689  return services::Status();
690  }
691 
692  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
693  {
694  _partialResult.reset(new DistributedStep2LocalPlusPlusPartialResult());
695  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int)method);
696  _pres = _partialResult.get();
697  return s;
698  }
699 
700  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
701  {
702  _partialResult->initialize(&input, _par, (int)method);
703  return services::Status();
704  }
705 
706  void initialize()
707  {
708  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step2Local, algorithmFPType, method)(&_env);
709  _in = &input;
710  _par = &parameter;
711  }
712 
713 public:
714  InputType input;
715  ParameterType parameter;
717 private:
718  DistributedStep2LocalPlusPlusPartialResultPtr _partialResult;
719 };
720 
741 template<typename algorithmFPType, Method method>
742 class DAAL_EXPORT Distributed<step3Master, algorithmFPType, method> : public daal::algorithms::Analysis<distributed>
743 {
744 public:
745  typedef algorithms::kmeans::init::DistributedStep3MasterPlusPlusInput InputType;
746  typedef algorithms::kmeans::init::Parameter ParameterType;
747  typedef algorithms::kmeans::init::DistributedStep3MasterPlusPlusPartialResult PartialResultType;
748 
753  Distributed(size_t nClusters) : parameter(nClusters)
754  {
755  initialize();
756  }
757 
763  Distributed(const Distributed<step3Master, algorithmFPType, method> &other) : parameter(other.parameter), input(other.input)
764  {
765  initialize();
766  }
767 
772  virtual int getMethod() const DAAL_C11_OVERRIDE{ return(int)method; }
773 
778  DistributedStep3MasterPlusPlusPartialResultPtr getPartialResult()
779  {
780  return _partialResult;
781  }
782 
787  services::Status setPartialResult(const DistributedStep3MasterPlusPlusPartialResultPtr& partialRes)
788  {
789  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
790  _partialResult = partialRes;
791  _pres = _partialResult.get();
792  return services::Status();
793  }
794 
798  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
799  {
800  return services::Status();
801  }
802 
808  services::SharedPtr<Distributed<step3Master, algorithmFPType, method> > clone() const
809  {
810  return services::SharedPtr<Distributed<step3Master, algorithmFPType, method> >(cloneImpl());
811  }
812 
813 protected:
814  virtual Distributed<step3Master, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
815  {
816  return new Distributed<step3Master, algorithmFPType, method>(*this);
817  }
818 
819  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
820  {
821  return services::Status();
822  }
823 
824  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
825  {
826  _partialResult.reset(new PartialResultType());
827  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int)method);
828  _pres = _partialResult.get();
829  return s;
830  }
831 
832  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
833  {
834  _partialResult->initialize(&input, _par, (int)method);
835  return services::Status();
836  }
837 
838  void initialize()
839  {
840  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step3Master, algorithmFPType, method)(&_env);
841  _in = &input;
842  _par = &parameter;
843  }
844 
845 public:
846  InputType input;
847  ParameterType parameter;
849 private:
850  DistributedStep3MasterPlusPlusPartialResultPtr _partialResult;
851 };
852 
873 template<typename algorithmFPType, Method method>
874 class DAAL_EXPORT Distributed<step4Local, algorithmFPType, method> : public daal::algorithms::Analysis<distributed>
875 {
876 public:
877  typedef algorithms::kmeans::init::DistributedStep4LocalPlusPlusInput InputType;
878  typedef algorithms::kmeans::init::Parameter ParameterType;
879  typedef algorithms::kmeans::init::DistributedStep4LocalPlusPlusPartialResult PartialResultType;
880 
885  Distributed(size_t nClusters) : parameter(nClusters)
886  {
887  initialize();
888  }
889 
895  Distributed(const Distributed<step4Local, algorithmFPType, method> &other) : parameter(other.parameter), input(other.input)
896  {
897  initialize();
898  }
899 
904  virtual int getMethod() const DAAL_C11_OVERRIDE{ return(int)method; }
905 
910  DistributedStep4LocalPlusPlusPartialResultPtr getPartialResult()
911  {
912  return _partialResult;
913  }
914 
919  services::Status setPartialResult(const DistributedStep4LocalPlusPlusPartialResultPtr& partialRes)
920  {
921  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
922  _partialResult = partialRes;
923  _pres = _partialResult.get();
924  return services::Status();
925  }
926 
930  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
931  {
932  return services::Status();
933  }
934 
940  services::SharedPtr<Distributed<step4Local, algorithmFPType, method> > clone() const
941  {
942  return services::SharedPtr<Distributed<step4Local, algorithmFPType, method> >(cloneImpl());
943  }
944 
945 protected:
946  virtual Distributed<step4Local, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
947  {
948  return new Distributed<step4Local, algorithmFPType, method>(*this);
949  }
950 
951  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
952  {
953  return services::Status();
954  }
955 
956  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
957  {
958  _partialResult.reset(new PartialResultType());
959  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int)method);
960  _pres = _partialResult.get();
961  return s;
962  }
963 
964  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
965  {
966  return services::Status();
967  }
968 
969  void initialize()
970  {
971  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step4Local, algorithmFPType, method)(&_env);
972  _in = &input;
973  _par = &parameter;
974  }
975 
976 public:
977  InputType input;
978  ParameterType parameter;
980 private:
981  DistributedStep4LocalPlusPlusPartialResultPtr _partialResult;
982 };
983 
1004 template<typename algorithmFPType, Method method>
1005 class DAAL_EXPORT Distributed<step5Master, algorithmFPType, method> : public daal::algorithms::Analysis<distributed>
1006 {
1007 public:
1008  typedef algorithms::kmeans::init::DistributedStep5MasterPlusPlusInput InputType;
1009  typedef algorithms::kmeans::init::Parameter ParameterType;
1010  typedef algorithms::kmeans::init::Result ResultType;
1011  typedef algorithms::kmeans::init::DistributedStep5MasterPlusPlusPartialResult PartialResultType;
1012 
1017  Distributed(size_t nClusters) : parameter(nClusters)
1018  {
1019  initialize();
1020  }
1021 
1027  Distributed(const Distributed<step5Master, algorithmFPType, method> &other) : parameter(other.parameter), input(other.input)
1028  {
1029  initialize();
1030  }
1031 
1036  virtual int getMethod() const DAAL_C11_OVERRIDE{ return(int)method; }
1037 
1042  ResultPtr getResult()
1043  {
1044  return _result;
1045  }
1046 
1051  services::Status setResult(const ResultPtr& result)
1052  {
1053  DAAL_CHECK(result, services::ErrorNullResult)
1054  _result = result;
1055  _res = _result.get();
1056  return services::Status();
1057  }
1058 
1063  DistributedStep5MasterPlusPlusPartialResultPtr getPartialResult()
1064  {
1065  return _partialResult;
1066  }
1067 
1072  services::Status setPartialResult(const DistributedStep5MasterPlusPlusPartialResultPtr& partialRes)
1073  {
1074  DAAL_CHECK(partialRes, services::ErrorNullPartialResult);
1075  _partialResult = partialRes;
1076  _pres = _partialResult.get();
1077  return services::Status();
1078  }
1079 
1083  services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
1084  {
1085  return services::Status();
1086  }
1087 
1093  services::SharedPtr<Distributed<step5Master, algorithmFPType, method> > clone() const
1094  {
1095  return services::SharedPtr<Distributed<step5Master, algorithmFPType, method> >(cloneImpl());
1096  }
1097 
1098 protected:
1099  virtual Distributed<step5Master, algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
1100  {
1101  return new Distributed<step5Master, algorithmFPType, method>(*this);
1102  }
1103 
1104  virtual services::Status allocateResult() DAAL_C11_OVERRIDE
1105  {
1106  _result.reset(new ResultType());
1107  services::Status s = _result->allocate<algorithmFPType>(_pres, _par, (int)method);
1108  _res = _result.get();
1109  return s;
1110  }
1111 
1112  virtual services::Status allocatePartialResult() DAAL_C11_OVERRIDE
1113  {
1114  _partialResult.reset(new PartialResultType());
1115  services::Status s = _partialResult->allocate<algorithmFPType>(&input, _par, (int)method);
1116  _pres = _partialResult.get();
1117  return s;
1118  }
1119 
1120  virtual services::Status initializePartialResult() DAAL_C11_OVERRIDE
1121  {
1122  return services::Status();
1123  }
1124 
1125  void initialize()
1126  {
1127  Analysis<distributed>::_ac = new __DAAL_ALGORITHM_CONTAINER(distributed, DistributedContainer, step5Master, algorithmFPType, method)(&_env);
1128  _in = &input;
1129  _par = &parameter;
1130  }
1131 
1132 public:
1133  InputType input;
1134  ParameterType parameter;
1136 private:
1137  DistributedStep5MasterPlusPlusPartialResultPtr _partialResult;
1138  ResultPtr _result;
1139 };
1140 } // namespace interface1
1141 using interface1::DistributedContainer;
1142 using interface1::Distributed;
1143 } // namespace daal::algorithms::kmeans::init
1144 } // namespace daal::algorithms::kmeans
1145 } // namespace daal::algorithms
1146 } // namespace daal
1147 #endif
daal::step2Local
Definition: daal_defines.h:122
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >::Distributed
Distributed(const Distributed< step3Master, algorithmFPType, method > &other)
Definition: kmeans_init_distributed.h:763
daal::algorithms::kmeans::init::data
Definition: kmeans_init_types.h:83
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >::Distributed
Distributed(const Distributed< step2Local, algorithmFPType, method > &other)
Definition: kmeans_init_distributed.h:631
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >::Distributed
Distributed(size_t nClusters)
Definition: kmeans_init_distributed.h:753
daal::algorithms::kmeans::init::interface1::Distributed< step5Master, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step5Master, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:1093
daal
Definition: algorithm_base_common.h:31
daal::step5Master
Definition: daal_defines.h:124
daal::algorithms::kmeans::init::interface1::Distributed< step4Local, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the 4th step of the distributed processing mod...
Definition: kmeans_init_distributed.h:874
daal::algorithms::AnalysisContainerIface
Abstract interface class that provides virtual methods to access and run implementations of the analy...
Definition: analysis.h:53
daal::algorithms::kmeans::init::interface1::Distributed< step4Local, algorithmFPType, method >::setPartialResult
services::Status setPartialResult(const DistributedStep4LocalPlusPlusPartialResultPtr &partialRes)
Definition: kmeans_init_distributed.h:919
daal::algorithms::kmeans::init::interface1::Distributed< step5Master, algorithmFPType, method >::Distributed
Distributed(const Distributed< step5Master, algorithmFPType, method > &other)
Definition: kmeans_init_distributed.h:1027
daal::algorithms::kmeans::init::interface1::Distributed< step4Local, algorithmFPType, method >::getPartialResult
DistributedStep4LocalPlusPlusPartialResultPtr getPartialResult()
Definition: kmeans_init_distributed.h:910
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >::setPartialResult
services::Status setPartialResult(const DistributedStep3MasterPlusPlusPartialResultPtr &partialRes)
Definition: kmeans_init_distributed.h:787
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::checkFinalizeComputeParams
services::Status checkFinalizeComputeParams() DAAL_C11_OVERRIDE
Definition: kmeans_init_distributed.h:357
daal::algorithms::kmeans::init::interface1::Distributed< step2Master, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the 2nd step of the distributed processing mod...
Definition: kmeans_init_distributed.h:433
daal::algorithms::kmeans::init::interface1::Distributed< step2Master, algorithmFPType, method >::Distributed
Distributed(size_t nClusters, size_t offset=0)
Definition: kmeans_init_distributed.h:446
daal::services::ErrorNullPartialResult
Definition: error_indexes.h:105
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::parameter
ParameterType parameter
Definition: kmeans_init_distributed.h:408
daal_defines.h
daal::step3Master
Definition: daal_defines.h:123
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >::getPartialResult
DistributedStep3MasterPlusPlusPartialResultPtr getPartialResult()
Definition: kmeans_init_distributed.h:778
daal::algorithms::kmeans::init::interface1::Distributed
class DAAL_EXPORT Distributed
Computes initial clusters for the K-Means algorithm in the distributed processing mode...
Definition: kmeans_init_distributed.h:255
daal::distributed
Definition: daal_defines.h:107
daal::algorithms::kmeans::init::interface1::Distributed< step4Local, algorithmFPType, method >::Distributed
Distributed(const Distributed< step4Local, algorithmFPType, method > &other)
Definition: kmeans_init_distributed.h:895
daal::algorithms::kmeans::init::interface1::Distributed< step2Master, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step2Master, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:532
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the 2nd step of the distributed processing mod...
Definition: kmeans_init_distributed.h:609
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::setPartialResult
services::Status setPartialResult(const PartialResultPtr &partialRes)
Definition: kmeans_init_distributed.h:346
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::input
InputType input
Definition: kmeans_init_distributed.h:407
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the 3rd step of the distributed processing mod...
Definition: kmeans_init_distributed.h:742
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::Distributed
Distributed(const Distributed< step1Local, algorithmFPType, method > &other)
Definition: kmeans_init_distributed.h:300
daal::algorithms::kmeans::init::interface1::Distributed< step3Master, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step3Master, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:808
daal::algorithms::kmeans::init::interface1::Distributed< step5Master, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the 5th step of the distributed processing mod...
Definition: kmeans_init_distributed.h:1005
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >
Computes initial clusters for the K-Means algorithm in the first step of the distributed processing m...
Definition: kmeans_init_distributed.h:275
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::Distributed
Distributed(size_t nClusters, size_t nRowsTotal, size_t offset=0)
Definition: kmeans_init_distributed.h:289
daal::step4Local
Definition: daal_defines.h:120
daal::algorithms::kmeans::init::interface1::DistributedContainer
class DAAL_EXPORT DistributedContainer
Provides methods to run implementations of initialization of the K-Means algorithm. This class is associated with the daal::algorithms::kmeans::init::Distributed class and supports the method of computing initial clusters for the K-Means algorithm in the distributed processing mode.
Definition: kmeans_init_distributed.h:57
daal::algorithms::Analysis
Provides methods for execution of operations over data, such as computation of Summary Statistics est...
Definition: analysis.h:68
daal::algorithms::kmeans::init::interface1::Distributed< step5Master, algorithmFPType, method >::getPartialResult
DistributedStep5MasterPlusPlusPartialResultPtr getPartialResult()
Definition: kmeans_init_distributed.h:1063
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::getResult
ResultPtr getResult()
Definition: kmeans_init_distributed.h:316
daal::step1Local
Definition: daal_defines.h:117
daal::step2Master
Definition: daal_defines.h:118
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step2Local, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:676
daal::algorithms::implicit_als::training::offset
Definition: implicit_als_training_types.h:148
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >::getPartialResult
DistributedStep2LocalPlusPlusPartialResultPtr getPartialResult()
Definition: kmeans_init_distributed.h:646
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::getPartialResult
PartialResultPtr getPartialResult()
Definition: kmeans_init_distributed.h:337
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::setResult
services::Status setResult(const ResultPtr &result)
Definition: kmeans_init_distributed.h:325
daal::algorithms::kmeans::init::interface1::Distributed< step5Master, algorithmFPType, method >::setPartialResult
services::Status setPartialResult(const DistributedStep5MasterPlusPlusPartialResultPtr &partialRes)
Definition: kmeans_init_distributed.h:1072
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::getMethod
virtual int getMethod() const DAAL_C11_OVERRIDE
Definition: kmeans_init_distributed.h:310
daal::algorithms::kmeans::init::interface1::Distributed< step1Local, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step1Local, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:367
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >::setPartialResult
services::Status setPartialResult(const DistributedStep2LocalPlusPlusPartialResultPtr &partialRes)
Definition: kmeans_init_distributed.h:655
daal::services::ErrorNullResult
Definition: error_indexes.h:96
daal::algorithms::kmeans::init::interface1::Distributed< step2Local, algorithmFPType, method >::Distributed
Distributed(size_t nClusters, bool bFirstIteration)
Definition: kmeans_init_distributed.h:621
daal::algorithms::kmeans::init::interface1::Distributed< step4Local, algorithmFPType, method >::clone
services::SharedPtr< Distributed< step4Local, algorithmFPType, method > > clone() const
Definition: kmeans_init_distributed.h:940

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