MyCaffe  1.12.2.41
Deep learning software for Windows C# programmers.
MyCaffe.db.stream.DataItem Class Reference

The DataItem manages one synchronized data item where the first element is the sync field. More...

Public Member Functions

 DataItem (int nFieldCount)
 The constructor. More...
 
int Add (int nFieldIdx, int nItemIdx, double[] rg, int nFieldCount)
 Adds a new set of raw data to the synchronized data. More...
 
bool Add (int nFieldIdx, double df)
 Add a new data item at a specified field index. More...
 
double[] GetData ()
 Returns the synchronized data fields. More...
 
void Reset ()
 Clears the data fields and the filled status. More...
 

Detailed Description

The DataItem manages one synchronized data item where the first element is the sync field.

Definition at line 12 of file DataItem.cs.

Constructor & Destructor Documentation

◆ DataItem()

MyCaffe.db.stream.DataItem.DataItem ( int  nFieldCount)

The constructor.

Parameters
nFieldCountSpecifies the total number of fields to be collected.

Definition at line 22 of file DataItem.cs.

Member Function Documentation

◆ Add() [1/2]

bool MyCaffe.db.stream.DataItem.Add ( int  nFieldIdx,
double  df 
)

Add a new data item at a specified field index.

Parameters
nFieldIdxSpecifies the field index.
dfSpecifies the raw data.
Returns
When the data item fields are full, true is returned, otherwise false is returned.

Definition at line 57 of file DataItem.cs.

◆ Add() [2/2]

int MyCaffe.db.stream.DataItem.Add ( int  nFieldIdx,
int  nItemIdx,
double[]  rg,
int  nFieldCount 
)

Adds a new set of raw data to the synchronized data.

Parameters
nFieldIdxSpecifies the field index where the data is to be added.
nItemIdxSpecifies the item index of the data.
rgSpecifies the raw data.
nFieldCountSpecifies the local number of fields contained in the 'rg' parameter.
Returns
The next field index is returned.

Definition at line 37 of file DataItem.cs.

◆ GetData()

double[] MyCaffe.db.stream.DataItem.GetData ( )

Returns the synchronized data fields.

Returns

Definition at line 72 of file DataItem.cs.

◆ Reset()

void MyCaffe.db.stream.DataItem.Reset ( )

Clears the data fields and the filled status.

Definition at line 80 of file DataItem.cs.


The documentation for this class was generated from the following file: