mxnet
Functions
Inner product
Collaboration diagram for Inner product:

Functions

mkldnn_status_t MKLDNN_API mkldnn_inner_product_forward_desc_init (mkldnn_inner_product_desc_t *ip_desc, mkldnn_prop_kind_t prop_kind, const mkldnn_memory_desc_t *src_desc, const mkldnn_memory_desc_t *weights_desc, const mkldnn_memory_desc_t *bias_desc, const mkldnn_memory_desc_t *dst_desc)
 
mkldnn_status_t MKLDNN_API mkldnn_inner_product_backward_data_desc_init (mkldnn_inner_product_desc_t *ip_desc, const mkldnn_memory_desc_t *diff_src_desc, const mkldnn_memory_desc_t *weights_desc, const mkldnn_memory_desc_t *diff_dst_desc)
 
mkldnn_status_t MKLDNN_API mkldnn_inner_product_backward_weights_desc_init (mkldnn_inner_product_desc_t *ip_desc, const mkldnn_memory_desc_t *src_desc, const mkldnn_memory_desc_t *diff_weights_desc, const mkldnn_memory_desc_t *diff_bias_desc, const mkldnn_memory_desc_t *diff_dst_desc)
 

Detailed Description

A primitive to compute an inner product.

Inner product layer is also known as fully connected layer. With spatial dimension:

\[dst[n][oc] = \sum\limits_{ic, kh, kw} src[n][ic][kh][kw] \cdot weights[oc][ic][kh][kw] + bias[oc]\]

Function Documentation

mkldnn_status_t MKLDNN_API mkldnn_inner_product_backward_data_desc_init ( mkldnn_inner_product_desc_t ip_desc,
const mkldnn_memory_desc_t diff_src_desc,
const mkldnn_memory_desc_t weights_desc,
const mkldnn_memory_desc_t diff_dst_desc 
)

Initializes an inner product descriptor ip_desc for backward propagation with respect to data using memory descriptors.

Note
Memory descriptors are allowed to be initialized with mkldnn_any value of format_kind.

Order of inputs:

Order of outputs:

mkldnn_status_t MKLDNN_API mkldnn_inner_product_backward_weights_desc_init ( mkldnn_inner_product_desc_t ip_desc,
const mkldnn_memory_desc_t src_desc,
const mkldnn_memory_desc_t diff_weights_desc,
const mkldnn_memory_desc_t diff_bias_desc,
const mkldnn_memory_desc_t diff_dst_desc 
)

Initializes an inner product descriptor ip_desc for backward propagation with respect to weights using memory descriptors.

Note
Memory descriptors are allowed to be initialized with mkldnn_any value of format_kind.

Order of inputs:

Order of outputs:

mkldnn_status_t MKLDNN_API mkldnn_inner_product_forward_desc_init ( mkldnn_inner_product_desc_t ip_desc,
mkldnn_prop_kind_t  prop_kind,
const mkldnn_memory_desc_t src_desc,
const mkldnn_memory_desc_t weights_desc,
const mkldnn_memory_desc_t bias_desc,
const mkldnn_memory_desc_t dst_desc 
)

Initializes an inner product descriptor ip_desc for forward propagation using prop_kind (possible values are mkldnn_forward_training and mkldnn_forward_inference) and memory descriptors. In order to create an inner product without bias, bias_desc should be either NULL or a pointer to a descriptor with memory format equal to mkldnn_format_undef.

Note
Memory descriptors are allowed to be initialized with mkldnn_any value of format_kind.

Order of inputs:

Order of outputs: