enum dnnl_sparse_encoding_t

enum dnnl_sparse_encoding_t#

Overview#

Sparse encodings. More…

#include <dnnl_types.h>

enum dnnl_sparse_encoding_t
{
    dnnl_sparse_encoding_undef = 0,
    dnnl_csr,
    dnnl_packed,
    dnnl_coo,
    dnnl_grouped,
};

Detailed Documentation#

Sparse encodings.

See also:

Sparse memory formats

Enum Values#

dnnl_sparse_encoding_undef

Undefined sparse encoding kind, used for empty memory descriptors.

dnnl_csr

Compressed Sparse Row (CSR) encoding.

dnnl_packed

An encoding that is used for an opaque storage schema for tensors with unstructured sparsity. A memory descriptor with the packed encoding cannot be used to create a memory object. It can only be used to create a primitive descriptor to query the actual memory descriptor (similar to the format tag any).

dnnl_coo

Coordinate Sparse Encoding (COO).

dnnl_grouped

Grouped Encoding represents a tensor where one dimension has variable size per group. Stored as concatenated blocks with an offsets specifying the size of each group along the variable dimension. Some of the blocks could be empty.