Files
openvino/docs/ops/movement/Transpose_1.md
Nikolay Tyukaev ef45b5da8d Doc Migration (master) (#1377)
* Doc Migration from Gitlab (#1289)

* doc migration

* fix

* Update FakeQuantize_1.md

* Update performance_benchmarks.md

* Updates graphs for FPGA

* Update performance_benchmarks.md

* Change DL Workbench structure (#1)

* Changed DL Workbench structure

* Fixed tags

* fixes

* Update ie_docs.xml

* Update performance_benchmarks_faq.md

* Fixes in DL Workbench layout

* Fixes for CVS-31290

* [DL Workbench] Minor correction

* Fix for CVS-30955

* Added nGraph deprecation notice as requested by Zoe

* fix broken links in api doxy layouts

* CVS-31131 fixes

* Additional fixes

* Fixed POT TOC

* Update PAC_Configure.md

PAC DCP 1.2.1 install guide.

* Update inference_engine_intro.md

* fix broken link

* Update opset.md

* fix

* added opset4 to layout

* added new opsets to layout, set labels for them

* Update VisionAcceleratorFPGA_Configure.md

Updated from 2020.3 to 2020.4

Co-authored-by: domi2000 <domi2000@users.noreply.github.com>
2020-07-20 17:36:08 +03:00

2.5 KiB

Transpose

Versioned name: Transpose-1

Category: Data movement

Short description: Transpose operation reorders the input tensor dimensions.

Attributes:

No attributes available.

Inputs:

  • 1: "arg" - the tensor to be transposed. A tensor of type T1. Required.
  • 2: "input_order" - the permutation to apply to the axes of the input shape. Must be a vector of element T2 type, with shape [n], where n is the rank of "arg". The tensor's value must contain every integer in the range [0,n-1]. If an empty list is specified [] then the axes will be inverted. A tensor of type T2. Required.

Outputs:

  • 1: A tensor with shape and type matching 1st tensor.

Types

  • T1: arbitrary supported type.
  • T2: any integer type.

Detailed description:

Transpose operation reorders the input tensor dimensions. Source indexes and destination indexes are bound by the formula: \f[ output[i(order[0]), i(order[1]), ..., i(order[N-1])] = input[i(0), i(1), ..., i(N-1)], where i(j) in range 0..(input.shape[j]-1). \f]

Examples

Example 1

<layer ... type="Transpose">
    <input>
        <port id="0">
            <dim>2</dim>
            <dim>3</dim>
            <dim>4</dim>
        </port>
        <port id="1">
            <dim>3</dim>  <!-- [2, 0, 1] -->
        </port>
    </input>
    <output>
        <port id="2">
            <dim>4</dim>
            <dim>2</dim>
            <dim>3</dim>
        </port>
    </output>
</layer>

Example 2: input_order in not specified

<layer ... type="Transpose">
    <input>
        <port id="0">
            <dim>2</dim>
            <dim>3</dim>
            <dim>4</dim>
        </port>
    </input>
    <output>         <!-- input_order = [2, 1, 0] if input_order is not set -->
        <port id="1">
            <dim>4</dim>
            <dim>3</dim>
            <dim>2</dim>
        </port>
    </output>
</layer>

Example 3: input_order = empty_list []

<layer ... type="Transpose">
    <input>
        <port id="0">
            <dim>2</dim>
            <dim>3</dim>
            <dim>4</dim>
        </port>
        <port id="1">
            <dim>0</dim> <!-- input_order = [2, 1, 0] if input_order is empty list -->
        </port>
    </input>
    <output>         
        <port id="2">
            <dim>4</dim>
            <dim>3</dim>
            <dim>2</dim>
        </port>
    </output>
</layer>