Files
openvino/docs/ops/shape/ShapeOf_1.md
Tatiana Savina aa5b6ecac2 DOCS shift to rst - Opset S (#17158)
* ops to rst

* fix errors

* formula fix

* change code

* console directive

* vsplit try hoghlight

* fix code snippets

* comment fixes

* fix list
2023-04-24 11:02:30 +02:00

974 B

ShapeOf

@sphinxdirective

Versioned name: ShapeOf-1

Category: Shape manipulation

Short description: ShapeOf produces 1D tensor with the input tensor shape.

Attributes: has no attributes.

Inputs:

  • 1: Arbitrary input tensor. Required.

Outputs:

  • 1: 1D tensor that is equal to input tensor shape. Number of elements is equal to input tensor rank. Can be empty 1D tensor if input tensor is a scalar, that mean 0-dimensional tensor.

Example

.. code-block:: cpp

<layer ... type="ShapeOf">
    <input>
        <port id="0">
            <dim>2</dim>
            <dim>3</dim>
            <dim>224</dim>
            <dim>224</dim>
        </port>
    </input>
    <output>
        <port id="1">  < !-- output value is: [2,3,224,224]-->
            <dim>4</dim>
        </port>
    </output>
</layer>

@endsphinxdirective