.. index:: pair: struct; dnnl::binary .. _doxid-structdnnl_1_1binary: struct dnnl::binary =================== .. toctree:: :hidden: struct_dnnl_binary_primitive_desc.rst Overview ~~~~~~~~ Elementwise binary operator primitive. :ref:`More...` .. ref-code-block:: cpp :class: doxyrest-overview-code-block #include struct binary: public :ref:`dnnl::primitive` { // structs struct :ref:`primitive_desc`; // construction :ref:`binary`(); :ref:`binary`(const :ref:`primitive_desc`& pd); :ref:`binary`(const :ref:`primitive_desc`& pd, const std::vector& cache_blob); }; Inherited Members ----------------- .. ref-code-block:: cpp :class: doxyrest-overview-inherited-code-block public: // enums enum :ref:`kind`; // methods :ref:`handle`& :ref:`operator =` (const :ref:`handle`&); :ref:`handle`& :ref:`operator =` (:ref:`handle`&&); void :ref:`reset`(T t, bool weak = false); T :ref:`get`(bool allow_empty = false) const; :ref:`operator T` () const; :ref:`operator bool` () const; bool :ref:`operator ==` (const :ref:`handle`& other) const; bool :ref:`operator !=` (const :ref:`handle`& other) const; :ref:`const_dnnl_primitive_desc_t` :ref:`get_primitive_desc`() const; :ref:`kind` :ref:`get_kind`() const; std::vector :ref:`get_cache_blob`() const; void :ref:`execute`(const :ref:`stream`& astream, const std::unordered_map`>& args) const; :ref:`handle`(); :ref:`handle`(); :ref:`handle`(); :ref:`handle`(); .. _details-structdnnl_1_1binary: Detailed Documentation ~~~~~~~~~~~~~~~~~~~~~~ Elementwise binary operator primitive. Construction ------------ .. index:: pair: function; binary .. _doxid-structdnnl_1_1binary_1a3e30f5d399c655ec1e5d03a1fd1b855c: .. ref-code-block:: cpp :class: doxyrest-title-code-block binary() Default constructor. Produces an empty object. .. index:: pair: function; binary .. _doxid-structdnnl_1_1binary_1ad1c3928248051918ab44b523165e312e: .. ref-code-block:: cpp :class: doxyrest-title-code-block binary(const :ref:`primitive_desc`& pd) Constructs an elementwise binary operation primitive. .. rubric:: Parameters: .. list-table:: :widths: 20 80 * - pd - Primitive descriptor for an elementwise binary operation primitive. .. index:: pair: function; binary .. _doxid-structdnnl_1_1binary_1a8d470bf2ec91b74ed865f9ebc7e861e5: .. ref-code-block:: cpp :class: doxyrest-title-code-block binary(const :ref:`primitive_desc`& pd, const std::vector& cache_blob) Constructs an elementwise binary operation primitive from a cache blob. .. rubric:: Parameters: .. list-table:: :widths: 20 80 * - pd - Primitive descriptor for an elementwise binary operation primitive. * - cache_blob - Cache blob.