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

data_source.h
1 /* file: data_source.h */
2 /*******************************************************************************
3 * Copyright 2014-2017 Intel Corporation
4 * All Rights Reserved.
5 *
6 * If this software was obtained under the Intel Simplified Software License,
7 * the following terms apply:
8 *
9 * The source code, information and material ("Material") contained herein is
10 * owned by Intel Corporation or its suppliers or licensors, and title to such
11 * Material remains with Intel Corporation or its suppliers or licensors. The
12 * Material contains proprietary information of Intel or its suppliers and
13 * licensors. The Material is protected by worldwide copyright laws and treaty
14 * provisions. No part of the Material may be used, copied, reproduced,
15 * modified, published, uploaded, posted, transmitted, distributed or disclosed
16 * in any way without Intel's prior express written permission. No license under
17 * any patent, copyright or other intellectual property rights in the Material
18 * is granted to or conferred upon you, either expressly, by implication,
19 * inducement, estoppel or otherwise. Any license under such intellectual
20 * property rights must be express and approved by Intel in writing.
21 *
22 * Unless otherwise agreed by Intel in writing, you may not remove or alter this
23 * notice or any other notice embedded in Materials by Intel or Intel's
24 * suppliers or licensors in any way.
25 *
26 *
27 * If this software was obtained under the Apache License, Version 2.0 (the
28 * "License"), the following terms apply:
29 *
30 * You may not use this file except in compliance with the License. You may
31 * obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
32 *
33 *
34 * Unless required by applicable law or agreed to in writing, software
35 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
36 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
37 *
38 * See the License for the specific language governing permissions and
39 * limitations under the License.
40 *******************************************************************************/
41 
42 /*
43 //++
44 // Declaration and implementation of the base data source class.
45 //--
46 */
47 
48 #ifndef __DATA_SOURCE_H__
49 #define __DATA_SOURCE_H__
50 
51 
52 #include "data_management/data/data_dictionary.h"
53 #include "data_management/data/numeric_table.h"
54 #include "data_management/data/homogen_numeric_table.h"
55 #include "data_management/data/aos_numeric_table.h"
56 #include "data_management/data/soa_numeric_table.h"
57 
58 #include "data_management/data_source/data_source_utils.h"
59 
60 namespace daal
61 {
62 namespace data_management
63 {
64 
65 namespace interface1
66 {
76 class DataSourceIface
77 {
78 public:
83  enum DataSourceStatus
84  {
85  readyForLoad = 1,
86  waitingForRows = 2,
87  endOfData = 3,
88  notReady = 4
89  };
90 
95  enum DictionaryCreationFlag
96  {
97  notDictionaryFromContext = 1,
98  doDictionaryFromContext = 2
99  };
100 
105  enum NumericTableAllocationFlag
106  {
107  notAllocateNumericTable = 1,
108  doAllocateNumericTable = 2
109  };
110 
111 public:
116  DAAL_DEPRECATED_VIRTUAL virtual DataSourceDictionary *getDictionary() = 0;
117 
122  virtual DataSourceDictionaryPtr getDictionarySharedPtr() = 0;
123 
127  virtual services::Status setDictionary(DataSourceDictionary *dict) = 0;
128 
132  virtual services::Status createDictionaryFromContext() = 0;
133 
138  virtual DataSourceStatus getStatus() = 0;
139 
144  virtual size_t getNumberOfColumns() = 0;
145 
150  virtual size_t getNumericTableNumberOfColumns() = 0;
151 
156  virtual size_t getNumberOfAvailableRows() = 0;
157 
161  virtual services::Status allocateNumericTable() = 0;
162 
167  virtual NumericTablePtr &getNumericTable() = 0;
168 
172  virtual void freeNumericTable() = 0;
173 
178  virtual size_t loadDataBlock(size_t maxRows) = 0;
179 
186  virtual size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows) = 0;
187 
193  virtual size_t loadDataBlock(size_t maxRows, NumericTable *nt) = 0;
194 
202  virtual size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows, NumericTable *nt) = 0;
203 
207  virtual size_t loadDataBlock() = 0;
208 
213  virtual size_t loadDataBlock(NumericTable *nt) = 0;
214 };
215 
220 class DataSource : public DataSourceIface
221 {
222 public:
223  DataSource() : _dict(), _errors(new services::ErrorCollection()), _initialMaxRows(10), _autoNumericTableFlag(doAllocateNumericTable), _autoDictionaryFlag(doDictionaryFromContext) {}
224 
225  virtual ~DataSource() {}
226 
227  DAAL_DEPRECATED_VIRTUAL DataSourceDictionary *getDictionary() DAAL_C11_OVERRIDE
228  {
229  services::Status s = checkDictionary();
230  if(!s)
231  return NULL;
232  return _dict.get();
233  }
234 
235  DataSourceDictionaryPtr getDictionarySharedPtr() DAAL_C11_OVERRIDE
236  {
237  services::Status s = checkDictionary();
238  if(!s)
239  return DataSourceDictionaryPtr();
240  return _dict;
241  }
242 
243  services::Status setDictionary(DataSourceDictionary *dict) DAAL_C11_OVERRIDE
244  {
245  if(_dict)
246  return services::throwIfPossible(services::Status(services::ErrorDictionaryAlreadyAvailable));
247 
248  services::Status s = dict->checkDictionary();
249  if(!s)
250  return services::throwIfPossible(s);
251 
252  _dict.reset(dict, services::EmptyDeleter());
253  return services::Status();
254  }
255 
256  services::Status createDictionaryFromContext() DAAL_C11_OVERRIDE
257  {
258  return services::throwIfPossible(services::Status(services::ErrorMethodNotSupported));
259  }
260 
261  size_t loadDataBlock(size_t maxRows) DAAL_C11_OVERRIDE
262  {
263  services::Status s = checkDictionary();
264  s.add(checkNumericTable());
265  if(!s)
266  {
267  this->_status.add(services::throwIfPossible(s));
268  return 0;
269  }
270  return loadDataBlock(maxRows, this->DataSource::_spnt.get());
271  }
272 
273  size_t loadDataBlock(size_t maxRows, NumericTable *nt) DAAL_C11_OVERRIDE
274  {
275  this->_status.add(services::throwIfPossible(services::ErrorMethodNotSupported));
276  return 0;
277  }
278 
279  size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows) DAAL_C11_OVERRIDE
280  {
281  services::Status s = checkDictionary();
282  if(s)
283  s.add(checkNumericTable());
284  if(!s)
285  {
286  this->_status.add(services::throwIfPossible(s));
287  return 0;
288  }
289  return loadDataBlock(maxRows, rowOffset, fullRows, this->DataSource::_spnt.get());
290  }
291 
292  size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows, NumericTable *nt) DAAL_C11_OVERRIDE
293  {
294  this->_status.add(services::throwIfPossible(services::ErrorMethodNotSupported));
295  return 0;
296  }
297 
298  size_t loadDataBlock() DAAL_C11_OVERRIDE
299  {
300  services::Status s = checkDictionary();
301  if(s)
302  {
303  s.add(checkNumericTable());
304  }
305  if(!s)
306  {
307  this->_status.add(services::throwIfPossible(s));
308  return 0;
309  }
310  return loadDataBlock(this->DataSource::_spnt.get());
311  }
312 
313  size_t loadDataBlock(NumericTable *nt) DAAL_C11_OVERRIDE
314  {
315  this->_status.add(services::throwIfPossible(services::ErrorMethodNotSupported));
316  return 0;
317  }
318 
319  NumericTablePtr &getNumericTable() DAAL_C11_OVERRIDE
320  {
321  checkNumericTable();
322  return _spnt;
323  }
324 
325  size_t getNumberOfColumns() DAAL_C11_OVERRIDE
326  {
327  checkDictionary();
328  return _dict ? _dict->getNumberOfFeatures() : 0;
329  }
330 
335  services::Status status() const
336  {
337  services::Status s = _status;
338  /*if(_spnt.get())
339  s.add(_spnt->status());*/
340  return s;
341  }
342 
348  DAAL_DEPRECATED services::SharedPtr<services::ErrorCollection> getErrors()
349  {
350  return status().getCollection();
351  }
352 
353  virtual size_t getNumericTableNumberOfColumns() DAAL_C11_OVERRIDE
354  {
355  return getNumberOfColumns();
356  }
357 
358 protected:
359  DataSourceDictionaryPtr _dict;
360  NumericTablePtr _spnt;
361 
362  NumericTableAllocationFlag _autoNumericTableFlag;
363  DictionaryCreationFlag _autoDictionaryFlag;
364  services::Status _status;
365  services::SharedPtr<services::ErrorCollection> _errors;
366  size_t _initialMaxRows;
367 
371  services::Status checkNumericTable()
372  {
373  if( _spnt.get() == NULL )
374  {
375  if( _autoNumericTableFlag == notAllocateNumericTable )
376  return services::throwIfPossible(services::Status(services::ErrorNumericTableNotAllocated));
377  return allocateNumericTable();
378  }
379  return services::Status();
380  }
381 
385  services::Status checkDictionary()
386  {
387  if( _dict == 0 )
388  {
389  if( _autoDictionaryFlag == notDictionaryFromContext )
390  return services::throwIfPossible(services::Status(services::ErrorDictionaryNotAvailable));
391  return createDictionaryFromContext();
392  }
393  return services::Status();
394  }
395 
405  template<typename NumericTableType> services::Status allocateNumericTableImpl(services::SharedPtr<NumericTableType> &nt);
406 
416  template<typename FPType> services::Status allocateNumericTableImpl(services::SharedPtr<HomogenNumericTable<FPType> > &nt);
417 
418  size_t getStructureSize()
419  {
420  size_t structureSize = 0;
421  size_t nFeatures = _dict->getNumberOfFeatures();
422  for(size_t i = 0; i < nFeatures; i++)
423  {
424  data_feature_utils::IndexNumType indexNumType = (*_dict)[i].ntFeature.indexType;
425  structureSize += (*_dict)[i].ntFeature.typeSize;
426  }
427  return structureSize;
428  }
429 
430  virtual services::Status setNumericTableDictionary(NumericTablePtr nt)
431  {
432  if (!nt) return services::throwIfPossible(services::Status(services::ErrorNullNumericTable));
433  NumericTableDictionaryPtr ntDict = nt->getDictionarySharedPtr();
434  if (!ntDict) return services::throwIfPossible(services::Status(services::ErrorDictionaryNotAvailable));
435 
436  size_t nFeatures = ntDict->getNumberOfFeatures();
437 
438  for(size_t i = 0; i < nFeatures; i++)
439  {
440  (*ntDict)[i] = (*_dict)[i].ntFeature;
441  }
442  return services::Status();
443  }
444 };
445 
446 template<typename NumericTableType>
447 inline services::Status DataSource::allocateNumericTableImpl(services::SharedPtr<NumericTableType> &nt)
448 {
449  nt = services::SharedPtr<NumericTableType>();
450  return services::Status();
451 }
452 
453 template<>
454 inline services::Status DataSource::allocateNumericTableImpl(AOSNumericTablePtr &nt)
455 {
456  size_t nFeatures = _dict->getNumberOfFeatures();
457  size_t structureSize = getStructureSize();
458  services::Status s;
459  nt = AOSNumericTable::create(structureSize, nFeatures, 0, &s);
460  if (!s) return s;
461  s |= setNumericTableDictionary(nt);
462  return s;
463 }
464 
465 template<>
466 inline services::Status DataSource::allocateNumericTableImpl(SOANumericTablePtr &nt)
467 {
468  nt = SOANumericTablePtr();
469  return services::Status();
470 }
471 
472 template<typename FPType>
473 inline services::Status DataSource::allocateNumericTableImpl(services::SharedPtr<HomogenNumericTable<FPType> > &nt)
474 {
475  size_t nFeatures = getNumericTableNumberOfColumns();
476  services::Status s;
477  nt = HomogenNumericTable<FPType>::create(nFeatures, 0, NumericTableIface::doNotAllocate, &s);
478  if (!s) return s;
479  s |= setNumericTableDictionary(nt);
480  return s;
481 }
482 
483 
488 template< typename _numericTableType, typename _summaryStatisticsType = DAAL_SUMMARY_STATISTICS_TYPE >
489 class DataSourceTemplate : public DataSource
490 {
491 public:
492  typedef _numericTableType numericTableType;
493 
494 public:
495  DataSourceTemplate( NumericTableAllocationFlag doAllocateNumericTable,
496  DictionaryCreationFlag doCreateDictionaryFromContext ) : DataSource()
497  {
498  DataSource::_autoNumericTableFlag = doAllocateNumericTable;
499  DataSource::_autoDictionaryFlag = doCreateDictionaryFromContext;
500  }
501 
502  virtual ~DataSourceTemplate() {}
503 
504 protected:
505  services::Status allocateNumericTable() DAAL_C11_OVERRIDE
506  {
507  if( _spnt.get() != NULL )
508  return services::throwIfPossible(services::Status(services::ErrorNumericTableAlreadyAllocated));
509 
510  services::Status s = checkDictionary();
511  if(!s)
512  return s;
513 
514  services::SharedPtr<numericTableType> nt;
515 
516  s |= allocateNumericTableImpl( nt );
517  _spnt = nt;
518 
519  services::SharedPtr<HomogenNumericTable<_summaryStatisticsType> > ssNt;
520 
521  s |= allocateNumericTableImpl( ssNt );
522  _spnt->basicStatistics.set(NumericTable::minimum, ssNt);
523 
524  s |= allocateNumericTableImpl( ssNt );
525  _spnt->basicStatistics.set(NumericTable::maximum, ssNt);
526 
527  s |= allocateNumericTableImpl( ssNt );
528  _spnt->basicStatistics.set(NumericTable::sum, ssNt);
529 
530  s |= allocateNumericTableImpl( ssNt );
531  _spnt->basicStatistics.set(NumericTable::sumSquares, ssNt);
532  return s;
533  }
534 
535  void freeNumericTable() DAAL_C11_OVERRIDE
536  {
537  _spnt = NumericTablePtr();
538  }
539 
540  services::Status resizeNumericTableImpl(const size_t linesToLoad, NumericTable* nt)
541  {
542  if(!nt)
543  return services::Status(services::ErrorNullInputNumericTable);
544 
545  if(!_dict)
546  return services::Status(services::ErrorDictionaryNotAvailable);
547 
548  size_t nFeatures = getNumericTableNumberOfColumns();
549 
550  if (nt->getNumberOfColumns() < nFeatures) {
551  nt->getDictionarySharedPtr()->setNumberOfFeatures(nFeatures);
552  }
553 
554  nt->resize(0);
555  nt->resize(linesToLoad);
556 
557  const size_t nCols = nt->getNumberOfColumns();
558 
559  nt->allocateBasicStatistics();
560 
561  NumericTablePtr ntMin = nt->basicStatistics.get(NumericTable::minimum );
562  NumericTablePtr ntMax = nt->basicStatistics.get(NumericTable::maximum );
563  NumericTablePtr ntSum = nt->basicStatistics.get(NumericTable::sum );
564  NumericTablePtr ntSumSq = nt->basicStatistics.get(NumericTable::sumSquares);
565 
566  if( ntMin->getNumberOfColumns() != nCols || ntMin->getNumberOfRows() != 1 )
567  {
568  if( ntMin->getNumberOfColumns() != nCols )
569  {
570  ntMin->getDictionarySharedPtr()->setNumberOfFeatures(nCols);
571  }
572  ntMin->resize(1);
573  }
574 
575  if( ntMax->getNumberOfColumns() != nCols || ntMax->getNumberOfRows() != 1 )
576  {
577  if( ntMax->getNumberOfColumns() != nCols )
578  {
579  ntMax->getDictionarySharedPtr()->setNumberOfFeatures(nCols);
580  }
581  ntMax->resize(1);
582  }
583 
584  if( ntSum->getNumberOfColumns() != nCols || ntSum->getNumberOfRows() != 1 )
585  {
586  if( ntSum->getNumberOfColumns() != nCols )
587  {
588  ntSum->getDictionarySharedPtr()->setNumberOfFeatures(nCols);
589  }
590  ntSum->resize(1);
591  }
592 
593  if( ntSumSq->getNumberOfColumns() != nCols || ntSumSq->getNumberOfRows() != 1 )
594  {
595  if( ntSumSq->getNumberOfColumns() != nCols )
596  {
597  ntSumSq->getDictionarySharedPtr()->setNumberOfFeatures(nCols);
598  }
599  ntSumSq->resize(1);
600  }
601  return services::Status();
602  }
603 
604  services::Status updateStatistics(size_t ntRowIndex, NumericTable *nt, size_t offset = 0)
605  {
606  if(!nt)
607  return services::Status(services::ErrorNullInputNumericTable);
608 
609  NumericTablePtr ntMin = nt->basicStatistics.get(NumericTable::minimum );
610  NumericTablePtr ntMax = nt->basicStatistics.get(NumericTable::maximum );
611  NumericTablePtr ntSum = nt->basicStatistics.get(NumericTable::sum );
612  NumericTablePtr ntSumSq = nt->basicStatistics.get(NumericTable::sumSquares);
613 
614  BlockDescriptor<_summaryStatisticsType> blockMin;
615  BlockDescriptor<_summaryStatisticsType> blockMax;
616  BlockDescriptor<_summaryStatisticsType> blockSum;
617  BlockDescriptor<_summaryStatisticsType> blockSumSq;
618 
619  ntMin->getBlockOfRows(0, 1, readWrite, blockMin);
620  ntMax->getBlockOfRows(0, 1, readWrite, blockMax);
621  ntSum->getBlockOfRows(0, 1, readWrite, blockSum);
622  ntSumSq->getBlockOfRows(0, 1, readWrite, blockSumSq);
623 
624  _summaryStatisticsType *minimum = blockMin.getBlockPtr();
625  _summaryStatisticsType *maximum = blockMax.getBlockPtr();
626  _summaryStatisticsType *sum = blockSum.getBlockPtr();
627  _summaryStatisticsType *sumSquares = blockSumSq.getBlockPtr();
628 
629  size_t nCols = nt->getNumberOfColumns();
630 
631  if( minimum == NULL || maximum == NULL || sum == NULL || sumSquares == NULL )
632  {
633  ntMin->releaseBlockOfRows(blockMin);
634  ntMax->releaseBlockOfRows(blockMax);
635  ntSum->releaseBlockOfRows(blockSum);
636  ntSumSq->releaseBlockOfRows(blockSumSq);
637  return services::Status(services::ErrorIncorrectInputNumericTable);
638  }
639 
640  BlockDescriptor<_summaryStatisticsType> block;
641  nt->getBlockOfRows( ntRowIndex + offset, 1, readOnly, block );
642  _summaryStatisticsType *row = block.getBlockPtr();
643 
644  if( ntRowIndex != 0 )
645  {
646  for( size_t i = 0; i < nCols; i++ )
647  {
648  if( minimum[i] > row[i] ) { minimum[i] = row[i]; }
649  if( maximum[i] < row[i] ) { maximum[i] = row[i]; }
650  sum[i] += row[i];
651  sumSquares[i] += row[i] * row[i];
652  }
653  }
654  else
655  {
656  for( size_t i = 0; i < nCols; i++ )
657  {
658  minimum[i] = row[i];
659  maximum[i] = row[i];
660  sum[i] = row[i];
661  sumSquares[i] = row[i] * row[i];
662  }
663  }
664 
665  nt->releaseBlockOfRows( block );
666  ntMin->releaseBlockOfRows( blockMin );
667  ntMax->releaseBlockOfRows( blockMax );
668  ntSum->releaseBlockOfRows( blockSum );
669  ntSumSq->releaseBlockOfRows( blockSumSq );
670  return services::Status();
671  }
672 
673  services::Status combineSingleStatistics(NumericTable *ntSrc, NumericTable *ntDst, bool wasEmpty, NumericTable::BasicStatisticsId id)
674  {
675  if( ntSrc == NULL || ntDst == NULL )
676  return services::Status(services::ErrorNullInputNumericTable);
677 
678  NumericTablePtr ntSrcStat = ntSrc->basicStatistics.get(id);
679  NumericTablePtr ntDstStat = ntDst->basicStatistics.get(id);
680 
681  BlockDescriptor<_summaryStatisticsType> blockSrc;
682  BlockDescriptor<_summaryStatisticsType> blockDst;
683 
684  ntSrcStat->getBlockOfRows(0, 1, readOnly, blockSrc);
685  ntDstStat->getBlockOfRows(0, 1, readWrite, blockDst);
686 
687  const _summaryStatisticsType *src = blockSrc.getBlockPtr();
688  _summaryStatisticsType *dst = blockDst.getBlockPtr();
689 
690  if( src == NULL || dst == NULL )
691  {
692  ntSrcStat->releaseBlockOfRows(blockSrc);
693  ntDstStat->releaseBlockOfRows(blockDst);
694  return services::Status(services::ErrorIncorrectInputNumericTable);
695  }
696 
697  const size_t nColsSrc = ntSrc->getNumberOfColumns();
698  const size_t nCols = ntDst->getNumberOfColumns();
699 
700  if (nCols != nColsSrc)
701  {
702  ntSrcStat->releaseBlockOfRows(blockSrc);
703  ntDstStat->releaseBlockOfRows(blockDst);
704  return services::Status(services::ErrorIncorrectInputNumericTable);
705  }
706 
707  if( wasEmpty )
708  {
709  for( size_t i = 0; i < nCols; i++ )
710  {
711  dst[i] = src[i];
712  }
713  }
714  else
715  {
716  if (id == NumericTable::minimum)
717  {
718  for( size_t i = 0; i < nCols; i++ )
719  {
720  if (dst[i] > src[i])
721  {
722  dst[i] = src[i];
723  }
724  }
725  }
726  else
727  if (id == NumericTable::maximum)
728  {
729  for( size_t i = 0; i < nCols; i++ )
730  {
731  if (dst[i] < src[i])
732  {
733  dst[i] = src[i];
734  }
735  }
736  }
737  else
738  if (id == NumericTable::sum)
739  {
740  for( size_t i = 0; i < nCols; i++ )
741  {
742  dst[i] += src[i];
743  }
744  }
745  else
746  if (id == NumericTable::sumSquares)
747  {
748  for( size_t i = 0; i < nCols; i++ )
749  {
750  dst[i] += src[i];
751  }
752  }
753  }
754 
755  ntSrcStat->releaseBlockOfRows( blockSrc );
756  ntDstStat->releaseBlockOfRows( blockDst );
757  return services::Status();
758  }
759 
760  services::Status combineStatistics(NumericTable *ntSrc, NumericTable *ntDst, bool wasEmpty)
761  {
762  services::Status s;
763  s.add(combineSingleStatistics(ntSrc, ntDst, wasEmpty, NumericTable::minimum));
764  s.add(combineSingleStatistics(ntSrc, ntDst, wasEmpty, NumericTable::maximum));
765  s.add(combineSingleStatistics(ntSrc, ntDst, wasEmpty, NumericTable::sum));
766  s.add(combineSingleStatistics(ntSrc, ntDst, wasEmpty, NumericTable::sumSquares));
767  return s;
768  }
769 };
771 } // namespace interface1
772 using interface1::DataSourceIface;
773 using interface1::DataSource;
774 using interface1::DataSourceTemplate;
775 
776 }
777 }
778 #endif
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows) DAAL_C11_OVERRIDE
Definition: data_source.h:279
daal::data_management::interface1::DataSource::getDictionary
DAAL_DEPRECATED_VIRTUAL DataSourceDictionary * getDictionary() DAAL_C11_OVERRIDE
Definition: data_source.h:227
daal::data_management::interface1::DataSource::checkDictionary
services::Status checkDictionary()
Definition: data_source.h:385
daal::services::ErrorDictionaryAlreadyAvailable
Definition: error_indexes.h:175
daal::services::ErrorNullInputNumericTable
Definition: error_indexes.h:107
daal
Definition: algorithm_base_common.h:57
daal::services::ErrorIncorrectInputNumericTable
Definition: error_indexes.h:101
daal::data_management::interface1::DataSourceIface
Abstract interface class that defines the interface for a data management component responsible for r...
Definition: data_source.h:76
daal::data_management::interface1::DataSourceIface::allocateNumericTable
virtual services::Status allocateNumericTable()=0
daal::services::ErrorNumericTableNotAllocated
Definition: error_indexes.h:179
daal::data_management::interface1::DataSource::status
services::Status status() const
Definition: data_source.h:335
daal::data_management::interface1::DataSourceIface::createDictionaryFromContext
virtual services::Status createDictionaryFromContext()=0
daal::data_management::interface1::DataSourceIface::getNumberOfAvailableRows
virtual size_t getNumberOfAvailableRows()=0
daal::data_management::interface1::NumericTable::getDictionarySharedPtr
virtual NumericTableDictionaryPtr getDictionarySharedPtr() const DAAL_C11_OVERRIDE
Definition: numeric_table.h:658
daal::data_management::interface1::DataSourceIface::loadDataBlock
virtual size_t loadDataBlock()=0
daal::data_management::interface1::DataSourceIface::DictionaryCreationFlag
DictionaryCreationFlag
Specifies whether a Data Dictionary is created from the context of a Data Source. ...
Definition: data_source.h:95
daal::algorithms::low_order_moments::maximum
Definition: low_order_moments_types.h:114
daal::data_management::interface1::DataSource
Implements the abstract DataSourceIface interface.
Definition: data_source.h:220
daal::data_management::interface1::DataSourceIface::notAllocateNumericTable
Definition: data_source.h:107
daal::data_management::interface1::NumericTable::getNumberOfColumns
size_t getNumberOfColumns() const
Definition: numeric_table.h:677
daal::data_management::interface1::DataSourceIface::freeNumericTable
virtual void freeNumericTable()=0
daal::algorithms::low_order_moments::minimum
Definition: low_order_moments_types.h:113
daal::data_management::interface1::DataSource::getDictionarySharedPtr
DataSourceDictionaryPtr getDictionarySharedPtr() DAAL_C11_OVERRIDE
Definition: data_source.h:235
daal::data_management::interface1::DataSource::getNumberOfColumns
size_t getNumberOfColumns() DAAL_C11_OVERRIDE
Definition: data_source.h:325
daal::data_management::interface1::DataSourceTemplate::allocateNumericTable
services::Status allocateNumericTable() DAAL_C11_OVERRIDE
Definition: data_source.h:505
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock(size_t maxRows) DAAL_C11_OVERRIDE
Definition: data_source.h:261
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock(NumericTable *nt) DAAL_C11_OVERRIDE
Definition: data_source.h:313
daal::data_management::interface1::DataSourceIface::doAllocateNumericTable
Definition: data_source.h:108
daal::data_management::interface1::DataSourceTemplate
Implements the abstract DataSourceIface interface.
Definition: data_source.h:489
daal::data_management::interface1::NumericTableIface::minimum
Definition: numeric_table.h:322
daal::data_management::interface1::NumericTable::allocateBasicStatistics
virtual services::Status allocateBasicStatistics() DAAL_C11_OVERRIDE
daal::algorithms::low_order_moments::sumSquares
Definition: low_order_moments_types.h:116
daal::data_management::interface1::DataSource::checkNumericTable
services::Status checkNumericTable()
Definition: data_source.h:371
daal::algorithms::covariance::sum
Definition: covariance_types.h:104
daal::data_management::interface1::HomogenNumericTable::create
static services::SharedPtr< HomogenNumericTable< DataType > > create(NumericTableDictionaryPtr ddictForHomogenNumericTable, services::Status *stat=NULL)
Definition: homogen_numeric_table.h:117
daal::data_management::interface1::NumericTable
Class for a data management component responsible for representation of data in the numeric format...
Definition: numeric_table.h:600
daal::data_management::interface1::DataSourceTemplate::freeNumericTable
void freeNumericTable() DAAL_C11_OVERRIDE
Definition: data_source.h:535
daal::data_management::interface1::DataSourceIface::setDictionary
virtual services::Status setDictionary(DataSourceDictionary *dict)=0
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock() DAAL_C11_OVERRIDE
Definition: data_source.h:298
daal::data_management::interface1::NumericTableIface::doNotAllocate
Definition: numeric_table.h:311
daal::data_management::interface1::NumericTable::resize
virtual services::Status resize(size_t nrows) DAAL_C11_OVERRIDE
Definition: numeric_table.h:662
daal::data_management::interface1::DataSource::getErrors
DAAL_DEPRECATED services::SharedPtr< services::ErrorCollection > getErrors()
Definition: data_source.h:348
daal::services::ErrorNumericTableAlreadyAllocated
Definition: error_indexes.h:178
daal::data_management::interface1::DataSourceIface::doDictionaryFromContext
Definition: data_source.h:98
daal::data_management::interface1::DataSourceIface::DataSourceStatus
DataSourceStatus
Specifies the status of the Data Source.
Definition: data_source.h:83
daal::data_management::interface1::NumericTableIface::maximum
Definition: numeric_table.h:323
daal::data_management::interface1::DataSourceIface::getNumericTable
virtual NumericTablePtr & getNumericTable()=0
daal::data_management::interface1::NumericTableIface::BasicStatisticsId
BasicStatisticsId
Enumeration to specify estimates of basic statistics stored.
Definition: numeric_table.h:320
daal::data_management::interface1::DataSourceIface::readyForLoad
Definition: data_source.h:85
daal::data_management::interface1::AOSNumericTable::create
static services::SharedPtr< AOSNumericTable > create(size_t structSize=0, size_t ncol=0, size_t nrow=0, services::Status *stat=NULL)
daal::data_management::interface1::DataSourceIface::getNumberOfColumns
virtual size_t getNumberOfColumns()=0
daal::data_management::interface1::DataSource::createDictionaryFromContext
services::Status createDictionaryFromContext() DAAL_C11_OVERRIDE
Definition: data_source.h:256
daal::services::ErrorDictionaryNotAvailable
Definition: error_indexes.h:176
daal::data_management::interface1::DataSourceIface::notDictionaryFromContext
Definition: data_source.h:97
daal::data_management::interface1::DataSourceIface::waitingForRows
Definition: data_source.h:86
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock(size_t maxRows, size_t rowOffset, size_t fullRows, NumericTable *nt) DAAL_C11_OVERRIDE
Definition: data_source.h:292
daal::data_management::interface1::DataSource::getNumericTable
NumericTablePtr & getNumericTable() DAAL_C11_OVERRIDE
Definition: data_source.h:319
daal::data_management::interface1::DataSourceIface::getDictionary
virtual DAAL_DEPRECATED_VIRTUAL DataSourceDictionary * getDictionary()=0
daal::data_management::interface1::DataSourceIface::endOfData
Definition: data_source.h:87
daal::data_management::interface1::DataSource::getNumericTableNumberOfColumns
virtual size_t getNumericTableNumberOfColumns() DAAL_C11_OVERRIDE
Definition: data_source.h:353
daal::data_management::interface1::DataSourceIface::getDictionarySharedPtr
virtual DataSourceDictionaryPtr getDictionarySharedPtr()=0
daal::data_management::interface1::DataSourceIface::NumericTableAllocationFlag
NumericTableAllocationFlag
Specifies whether a Numeric Table is allocated inside of the Data Source object.
Definition: data_source.h:105
daal::data_management::interface1::DataSource::allocateNumericTableImpl
services::Status allocateNumericTableImpl(services::SharedPtr< NumericTableType > &nt)
Definition: data_source.h:447
daal::data_management::interface1::NumericTableIface::sum
Definition: numeric_table.h:324
daal::algorithms::implicit_als::training::offset
Definition: implicit_als_training_types.h:174
daal::data_management::interface1::DataSource::loadDataBlock
size_t loadDataBlock(size_t maxRows, NumericTable *nt) DAAL_C11_OVERRIDE
Definition: data_source.h:273
daal::data_management::interface1::DataSourceIface::getStatus
virtual DataSourceStatus getStatus()=0
daal::data_management::interface1::NumericTableIface::sumSquares
Definition: numeric_table.h:325
daal::data_management::interface1::DataSourceIface::getNumericTableNumberOfColumns
virtual size_t getNumericTableNumberOfColumns()=0
daal::services::ErrorNullNumericTable
Definition: error_indexes.h:139
daal::data_management::interface1::DataSource::setDictionary
services::Status setDictionary(DataSourceDictionary *dict) DAAL_C11_OVERRIDE
Definition: data_source.h:243
daal::data_management::interface1::DataSourceIface::notReady
Definition: data_source.h:88
daal::data_management::interface1::HomogenNumericTable
Class that provides methods to access data stored as a contiguous array of homogeneous feature vector...
Definition: homogen_numeric_table.h:76
daal::services::ErrorMethodNotSupported
Definition: error_indexes.h:95
daal::data_management::interface1::Dictionary
Class that represents a dictionary of a data set and provides methods to work with the data dictionar...
Definition: data_dictionary.h:184

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