#include <nn_ops.h>
Permute input tensor from src_format
to dst_format
.
Input tensor must be a vector of size 4, or a 4x2 tensor.
For example, with src_format
of NHWC
, dst_format
of NCHW
, and inputs:
[1, 2, 3, 4]and
[[1, 2, 3, 4], [5, 6, 7, 8]], the outputs will be (respectively):
[1, 4, 2, 3]and
[[1, 4, 2, 3], [5, 8, 6, 7]]
Arguments:
Optional attributes (see Attrs
):
Returns:
Constructors and Destructors | |
---|---|
DataFormatVecPermute(const ::tensorflow::Scope & scope, ::tensorflow::Input x) | |
DataFormatVecPermute(const ::tensorflow::Scope & scope, ::tensorflow::Input x, const DataFormatVecPermute::Attrs & attrs) |
Public attributes | |
---|---|
operation | |
y |
Public functions | |
---|---|
node() const | ::tensorflow::Node * |
operator::tensorflow::Input() const | |
operator::tensorflow::Output() const |
Public static functions | |
---|---|
DstFormat(StringPiece x) | |
SrcFormat(StringPiece x) |
Structs | |
---|---|
tensorflow::ops::DataFormatVecPermute::Attrs | Optional attribute setters for DataFormatVecPermute. |
Operation operation
::tensorflow::Output y
DataFormatVecPermute( const ::tensorflow::Scope & scope, ::tensorflow::Input x )
DataFormatVecPermute( const ::tensorflow::Scope & scope, ::tensorflow::Input x, const DataFormatVecPermute::Attrs & attrs )
::tensorflow::Node * node() const
operator::tensorflow::Input() const
operator::tensorflow::Output() const
Attrs DstFormat( StringPiece x )
Attrs SrcFormat( StringPiece x )
© 2020 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 4.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r2.4/api_docs/cc/class/tensorflow/ops/data-format-vec-permute