# Array Ops

# Array Ops

## Summary

| ### Classes ||
|---|---|
| [tensorflow:: ops:: BatchToSpace](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/batch-to-space) | [BatchToSpace](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/batch-to-space#classtensorflow_1_1ops_1_1_batch_to_space) for 4-D tensors of type T. |
| [tensorflow:: ops:: BatchToSpaceND](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/batch-to-space-n-d) | [BatchToSpace](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/batch-to-space#classtensorflow_1_1ops_1_1_batch_to_space) for N-D tensors of type T. |
| [tensorflow:: ops:: Bitcast](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/bitcast) | Bitcasts a tensor from one type to another without copying data. |
| [tensorflow:: ops:: BroadcastDynamicShape](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/broadcast-dynamic-shape) | Return the shape of s0 op s1 with broadcast. |
| [tensorflow:: ops:: BroadcastTo](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/broadcast-to) | Broadcast an array for a compatible shape. |
| [tensorflow:: ops:: CheckNumerics](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/check-numerics) | Checks a tensor for NaN and Inf values. |
| [tensorflow:: ops:: Concat](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/concat) | Concatenates tensors along one dimension. |
| [tensorflow:: ops:: ConjugateTranspose](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/conjugate-transpose) | Shuffle dimensions of x according to a permutation and conjugate the result. |
| [tensorflow:: ops:: DebugGradientIdentity](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/debug-gradient-identity) | [Identity](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/identity#classtensorflow_1_1ops_1_1_identity) op for gradient debugging. |
| [tensorflow:: ops:: DebugGradientRefIdentity](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/debug-gradient-ref-identity) | [Identity](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/identity#classtensorflow_1_1ops_1_1_identity) op for gradient debugging. |
| [tensorflow:: ops:: DeepCopy](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/deep-copy) | Makes a copy of ` x ` . |
| [tensorflow:: ops:: DepthToSpace](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/depth-to-space) | [DepthToSpace](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/depth-to-space#classtensorflow_1_1ops_1_1_depth_to_space) for tensors of type T. |
| [tensorflow:: ops:: Dequantize](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/dequantize) | [Dequantize](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/dequantize#classtensorflow_1_1ops_1_1_dequantize) the 'input' tensor into a float or bfloat16 [Tensor](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/tensor#classtensorflow_1_1_tensor) . |
| [tensorflow:: ops:: Diag](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/diag) | Returns a diagonal tensor with a given diagonal values. |
| [tensorflow:: ops:: DiagPart](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/diag-part) | Returns the diagonal part of the tensor. |
| [tensorflow:: ops:: EditDistance](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/edit-distance) | Computes the (possibly normalized) Levenshtein Edit Distance. |
| [tensorflow:: ops:: Empty](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/empty) | Creates a tensor with the given shape. |
| [tensorflow:: ops:: EnsureShape](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/ensure-shape) | Ensures that the tensor's shape matches the expected shape. |
| [tensorflow:: ops:: ExpandDims](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/expand-dims) | Inserts a dimension of 1 into a tensor's shape. |
| [tensorflow:: ops:: ExtractImagePatches](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/extract-image-patches) | Extract ` patches ` from ` images ` and put them in the "depth" output dimension. |
| [tensorflow:: ops:: ExtractVolumePatches](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/extract-volume-patches) | Extract ` patches ` from ` input ` and put them in the ` "depth" ` output dimension. |
| [tensorflow:: ops:: FakeQuantWithMinMaxArgs](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-args) | Fake-quantize the 'inputs' tensor, type float to 'outputs' tensor of same type. |
| [tensorflow:: ops:: FakeQuantWithMinMaxArgsGradient](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-args-gradient) | Compute gradients for a [FakeQuantWithMinMaxArgs](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-args#classtensorflow_1_1ops_1_1_fake_quant_with_min_max_args) operation. |
| [tensorflow:: ops:: FakeQuantWithMinMaxVars](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars) | Fake-quantize the 'inputs' tensor of type float via global float scalars. |
| [tensorflow:: ops:: FakeQuantWithMinMaxVarsGradient](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars-gradient) | Compute gradients for a [FakeQuantWithMinMaxVars](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars#classtensorflow_1_1ops_1_1_fake_quant_with_min_max_vars) operation. |
| [tensorflow:: ops:: FakeQuantWithMinMaxVarsPerChannel](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars-per-channel) | Fake-quantize the 'inputs' tensor of type float via per-channel floats. |
| [tensorflow:: ops:: FakeQuantWithMinMaxVarsPerChannelGradient](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars-per-channel-gradient) | Compute gradients for a [FakeQuantWithMinMaxVarsPerChannel](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fake-quant-with-min-max-vars-per-channel#classtensorflow_1_1ops_1_1_fake_quant_with_min_max_vars_per_channel) operation. |
| [tensorflow:: ops:: Fill](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fill) | Creates a tensor filled with a scalar value. |
| [tensorflow:: ops:: Fingerprint](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/fingerprint) | Generates fingerprint values. |
| [tensorflow:: ops:: Gather](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather) | [Gather](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather#classtensorflow_1_1ops_1_1_gather) slices from ` params ` according to ` indices ` . |
| [tensorflow:: ops:: GatherNd](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather-nd) | [Gather](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather#classtensorflow_1_1ops_1_1_gather) slices from ` params ` into a [Tensor](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/tensor#classtensorflow_1_1_tensor) with shape specified by ` indices ` . |
| [tensorflow:: ops:: GatherV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather-v2) | [Gather](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/gather#classtensorflow_1_1ops_1_1_gather) slices from ` params ` axis ` axis ` according to ` indices ` . |
| [tensorflow:: ops:: GuaranteeConst](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/guarantee-const) | Gives a guarantee to the TF runtime that the input tensor is a constant. |
| [tensorflow:: ops:: Identity](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/identity) | Return a tensor with the same shape and contents as the input tensor or value. |
| [tensorflow:: ops:: IdentityN](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/identity-n) | Returns a list of tensors with the same shapes and contents as the input. |
| [tensorflow:: ops:: ImmutableConst](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/immutable-const) | Returns immutable tensor from memory region. |
| [tensorflow:: ops:: InplaceAdd](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/inplace-add) | Adds v into specified rows of x. |
| [tensorflow:: ops:: InplaceSub](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/inplace-sub) | Subtracts ` v ` into specified rows of ` x ` . |
| [tensorflow:: ops:: InplaceUpdate](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/inplace-update) | Updates specified rows 'i' with values 'v'. |
| [tensorflow:: ops:: InvertPermutation](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/invert-permutation) | Computes the inverse permutation of a tensor. |
| [tensorflow:: ops:: MatrixBandPart](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-band-part) | Copy a tensor setting everything outside a central band in each innermost matrix to zero. |
| [tensorflow:: ops:: MatrixDiag](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag) | Returns a batched diagonal tensor with a given batched diagonal values. |
| [tensorflow:: ops:: MatrixDiagPart](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag-part) | Returns the batched diagonal part of a batched tensor. |
| [tensorflow:: ops:: MatrixDiagPartV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag-part-v2) | Returns the batched diagonal part of a batched tensor. |
| [tensorflow:: ops:: MatrixDiagPartV3](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag-part-v3) | Returns the batched diagonal part of a batched tensor. |
| [tensorflow:: ops:: MatrixDiagV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag-v2) | Returns a batched diagonal tensor with given batched diagonal values. |
| [tensorflow:: ops:: MatrixDiagV3](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-diag-v3) | Returns a batched diagonal tensor with given batched diagonal values. |
| [tensorflow:: ops:: MatrixSetDiag](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-set-diag) | Returns a batched matrix tensor with new batched diagonal values. |
| [tensorflow:: ops:: MatrixSetDiagV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-set-diag-v2) | Returns a batched matrix tensor with new batched diagonal values. |
| [tensorflow:: ops:: MatrixSetDiagV3](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/matrix-set-diag-v3) | Returns a batched matrix tensor with new batched diagonal values. |
| [tensorflow:: ops:: MirrorPad](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/mirror-pad) | Pads a tensor with mirrored values. |
| [tensorflow:: ops:: OneHot](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/one-hot) | Returns a one-hot tensor. |
| [tensorflow:: ops:: OnesLike](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/ones-like) | Returns a tensor of ones with the same shape and type as x. |
| [tensorflow:: ops:: Pad](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/pad) | Pads a tensor with zeros. |
| [tensorflow:: ops:: PadV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/pad-v2) | Pads a tensor. |
| [tensorflow:: ops:: ParallelConcat](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/parallel-concat) | Concatenates a list of ` N ` tensors along the first dimension. |
| [tensorflow:: ops:: Placeholder](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/placeholder) | A placeholder op for a value that will be fed into the computation. |
| [tensorflow:: ops:: PlaceholderWithDefault](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/placeholder-with-default) | A placeholder op that passes through ` input ` when its output is not fed. |
| [tensorflow:: ops:: PreventGradient](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/prevent-gradient) | An identity op that triggers an error if a gradient is requested. |
| [tensorflow:: ops:: QuantizeAndDequantizeV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v2) | Quantizes then dequantizes a tensor. |
| [tensorflow:: ops:: QuantizeAndDequantizeV3](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v3) | Quantizes then dequantizes a tensor. |
| [tensorflow:: ops:: QuantizeAndDequantizeV4](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v4) | Returns the gradient of ` https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v4#classtensorflow_1_1ops_1_1_quantize_and_dequantize_v4 ` . |
| [tensorflow:: ops:: QuantizeAndDequantizeV4Grad](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v4-grad) | Returns the gradient of ` https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-and-dequantize-v4#classtensorflow_1_1ops_1_1_quantize_and_dequantize_v4 ` . |
| [tensorflow:: ops:: QuantizeV2](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantize-v2) | Quantize the 'input' tensor of type float to 'output' tensor of type 'T'. |
| [tensorflow:: ops:: QuantizedConcat](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantized-concat) | Concatenates quantized tensors along one dimension. |
| [tensorflow:: ops:: QuantizedInstanceNorm](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/quantized-instance-norm) | Quantized Instance normalization. |
| [tensorflow:: ops:: SetDiff1D](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/set-diff1-d) | Computes the difference between two lists of numbers or strings. |
| [tensorflow:: ops:: Stack](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/stack) | Packs a list of ` N ` rank- ` R ` tensors into one rank- ` (R+1) ` tensor. |
| [tensorflow:: ops:: Where](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/where) | Reshapes a quantized tensor as per the Reshape op. |
| [tensorflow:: ops:: ZerosLike](https://www.tensorflow.org/versions/r2.5/api_docs/cc/class/tensorflow/ops/zeros-like) | Returns a tensor of zeros with the same shape and type as x. |