moveforever commented on issue #18346:
URL:
https://github.com/apache/incubator-mxnet/issues/18346#issuecomment-630711491
i add some code from 3rdparty/dmlc-core to mxnet/src/io.
- 1. support multi-format features
1) i add std::vector<UnitData<IndexType> > extra(a data struct to support
multi-format features in a row) as followed. UnitData can support fixed length
features(dense features or one-categorical features), and also can support
variable length features(multi-hot features)
```c++
template<typename IndexType, typename DType = real_t>
class UnitData {
public:
/*! \brief length of the sparse vector */
size_t length;
/*!
* \brief index of each instance
*/
const IndexType *index;
/*!
* \brief array value of each instance, this can be NULL
* indicating every value is set to be 1
*/
const DType *value;
};
```
- support multi-label
1) we only add label_width
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]