Developer Guide for Intel® Data Analytics Acceleration Library 2016 Update 4

Generic Interfaces

Numeric tables provide interfaces for data management, such as memory allocation and deallocation, and respective memory access methods, dictionary management, and table size management.

The life cycle of a numeric table consists of the following major steps:

  1. Initialize
  2. Operate
  3. Deinitialize

The following diagram shows possible flows and transitions between the states of the numeric table for each step. The description of these steps applies to different types of numeric tables supported in the library, such as CSR, with appropriate changes in the method names and respective arguments.


Numeric Table Lifecycle

Initialize

Intel DAAL provides several constructors for numeric tables to cover a variety of table initialization scenarios. The constructors require the numbers of rows and columns for the table or a dictionary. If you do not have the dictionary or sizes of the numeric table at the time of construction, you can use the constructor with default values and sizes. The following scenarios are available for use of constructors:

To allocate or reallocate the memory after construction of the numeric table, use service methods:

Operate

After initialization or re-initialization of a numeric table, you can use the following methods for the numeric table to access the data:

Deinitialize

After you complete your work with a data resource, the appropriate memory is deallocated implicitly in the destructor of the numeric table. For more control over allocation/deallocation of the memory, you can deallocate the memory explicitly by the freeDataMemory() method. This method deallocates the memory internally allocated by the library or sets the pointer to the user allocated memory to zero if the numeric table stores this pointer. The destructor of the numeric table calls the freeDataMemory() method.

Examples

C++:

Java*: