one row of training instance
More...
#include <data.h>
template<typename IndexType, typename DType = real_t>
class dmlc::Row< IndexType, DType >
one row of training instance
- Template Parameters
-
IndexType | type of index |
DType | type of data (both label and value will be of DType |
template<typename IndexType, typename DType = real_t>
IndexType dmlc::Row< IndexType, DType >::get_field |
( |
size_t |
i | ) |
const |
|
inline |
- Parameters
-
- Returns
- field for i-th feature
template<typename IndexType, typename DType = real_t>
IndexType dmlc::Row< IndexType, DType >::get_index |
( |
size_t |
i | ) |
const |
|
inline |
- Parameters
-
- Returns
- i-th feature
template<typename IndexType, typename DType = real_t>
DType dmlc::Row< IndexType, DType >::get_label |
( |
| ) |
const |
|
inline |
- Returns
- the label of the instance
template<typename IndexType, typename DType = real_t>
uint64_t dmlc::Row< IndexType, DType >::get_qid |
( |
| ) |
const |
|
inline |
- Returns
- the qid of the instance, this function is always safe even when qid == NULL
template<typename IndexType, typename DType = real_t>
DType dmlc::Row< IndexType, DType >::get_value |
( |
size_t |
i | ) |
const |
|
inline |
- Parameters
-
- Returns
- i-th feature value, this function is always safe even when value == NULL
template<typename IndexType, typename DType = real_t>
- Returns
- the weight of the instance, this function is always safe even when weight == NULL
template<typename IndexType, typename DType = real_t>
template<typename V >
V dmlc::Row< IndexType, DType >::SDot |
( |
const V * |
weight, |
|
|
size_t |
size |
|
) |
| const |
|
inline |
helper function to compute dot product of current
- Parameters
-
weight | the dense array of weight we want to product |
size | the size of the weight vector |
- Template Parameters
-
V | type of the weight vector |
- Returns
- the result of dot product
template<typename IndexType, typename DType = real_t>
const IndexType* dmlc::Row< IndexType, DType >::field |
template<typename IndexType, typename DType = real_t>
const IndexType* dmlc::Row< IndexType, DType >::index |
template<typename IndexType, typename DType = real_t>
const DType* dmlc::Row< IndexType, DType >::label |
template<typename IndexType, typename DType = real_t>
length of the sparse vector
template<typename IndexType, typename DType = real_t>
const uint64_t* dmlc::Row< IndexType, DType >::qid |
session-id of the instance
template<typename IndexType, typename DType = real_t>
const DType* dmlc::Row< IndexType, DType >::value |
array value of each instance, this can be NULL indicating every value is set to be 1
template<typename IndexType, typename DType = real_t>
The documentation for this class was generated from the following file:
- /work/mxnet/3rdparty/dmlc-core/include/dmlc/data.h