struct dnnl::softmax_v2_forward::desc

Overview

Descriptor for a softmax forward propagation primitive. More…

#include <dnnl.hpp>

struct desc
{
    // fields

    dnnl_softmax_v2_desc_t data;

    // methods

    desc();

    desc(
        prop_kind aprop_kind,
        algorithm aalgorithm,
        const memory::desc& src_desc,
        const memory::desc& dst_desc,
        int softmax_axis
        );
};

Detailed Documentation

Descriptor for a softmax forward propagation primitive.

Methods

desc()

Default constructor. Produces an empty object.

desc(
    prop_kind aprop_kind,
    algorithm aalgorithm,
    const memory::desc& src_desc,
    const memory::desc& dst_desc,
    int softmax_axis
    )

Constructs a descriptor for a softmax forward propagation primitive.

Parameters:

aprop_kind

Propagation kind. Possible values are dnnl::prop_kind::forward_training, and dnnl::prop_kind::forward_inference.

aalgorithm

Softmax algorithm kind: either dnnl::algorithm::softmax_accurate, or dnnl::algorithm::softmax_log.

src_desc

Source memory descriptor.

dst_desc

Destination memory descriptor.

softmax_axis

Axis over which softmax is computed.