Transpose // Operation that transposes axes of a tensor
Description¶
Warning
This op is not yet implemented in any backend.
Warning
This op is experimental and subject to change without notice.
Operation that transposes axes of an input tensor. This operation covers matrix transposition, and also more general cases on higherrank tensors.
Inputs¶
Name 
Element Type 
Shape 


Any 
Any 



Outputs¶
Name 
Element Type 
Shape 


Same as 

The input input_order
must be a vector of shape [n], where n is the
rank of arg
, and must contain every integer in the range [0,n1]
. This
vector represents a permutation of arg
’s dimensions. For example,



Comment 




Transposes the 



Transposes the 



Transposes the 



Moves the “last” dimension to the “first” position. 
Mathematical Definition¶
Backprop¶
Not yet implemented.
C++ Interface¶

class
Transpose
: public ngraph::op::Op¶ 
Tensor transpose operation.
Public Functions

const NodeTypeInfo &
get_type_info
() const¶ 
Returns the NodeTypeInfo for the node’s class. During transition to type_info, returns a dummy type_info for Node if the class has not been updated yet.

Transpose
(const Output<Node> &arg, const Output<Node> &input_order)¶ 
Constructs a transpose operation.
 Parameters

arg
: Node producing the tensor to be transposed.input_order
: Node producing the permutation to apply to the axes of the input shape. Must be a vector of element type element::i64, with shape [n], where n is the rank of arg. The tensor’s value must contain every integer in the range [0,n1].

void
validate_and_infer_types
()¶ 
Throws if the node is invalid.

const NodeTypeInfo &