Load FTRL embedding parameters with debug support.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingFTRLParametersGradAccumDebug
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load MDL Adagrad Light embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingMDLAdagradLightParameters
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load Momentum embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingMomentumParameters
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load Momentum embedding parameters with debug support.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingMomentumParametersGradAccumDebug
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load proximal Adagrad embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingProximalAdagradParameters
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load proximal Adagrad embedding parameters with debug support.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingProximalAdagradParametersGradAccumDebug
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingProximalYogiParameters


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingProximalYogiParametersGradAccumDebug


Load RMSProp embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingRMSPropParameters
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load RMSProp embedding parameters with debug support.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingRMSPropParametersGradAccumDebug
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load SGD embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingStochasticGradientDescentParameters
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Load SGD embedding parameters.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoadTPUEmbeddingStochasticGradientDescentParametersGradAccumDebug
An op that loads optimization parameters into HBM for embedding. Must be preceded by a ConfigureTPUEmbeddingHost op that sets up the correct embedding table configuration. For example, this op is used to install parameters that are loaded from a checkpoint before a training loop is executed.


Computes natural logarithm of x element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Log
I.e., \(y = \log_e x\).
x = tf.constant([0, 0.5, 1, 5]) tf.math.log(x)
See: https://en.wikipedia.org/wiki/Logarithm


Computes natural logarithm of (1 + x) element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Log1p
I.e., \(y = \log_e (1 + x)\).


Returns the truth value of x AND y element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogicalAnd


Returns the truth value of NOT x element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogicalNot


Returns the truth value of x OR y element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogicalOr


Computes the sign and the log of the absolute value of the determinant of
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogMatrixDeterminant
one or more square matrices.
The input is a tensor of shape [N, M, M] whose inner-most 2 dimensions form square matrices. The outputs are two tensors containing the signs and absolute values of the log determinants for all N input submatrices [..., :, :] such that determinant = sign*exp(log_abs_determinant). The log_abs_determinant is computed as det(P)*sum(log(diag(LU))) where LU is the LU decomposition of the input and P is the corresponding permutation matrix.


Computes log softmax activations.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogSoftmax
For each batch i and class j we have


Generates labels for candidate sampling with a log-uniform distribution.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LogUniformCandidateSampler
See explanations of candidate sampling and the data formats at go/candidate-sampling.
For each batch, this op picks a single set of sampled candidate labels.
The advantages of sampling candidates per-batch are simplicity and the possibility of efficient dense matrix multiplication. The disadvantage is that the sampled candidates must be chosen independently of the context and of the true labels.


Outputs all keys and values in the table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableExport


Outputs all keys and values in the table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableExportV2


Looks up keys in a table, outputs the corresponding values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableFind
The tensor keys must of the same type as the keys of the table. The output values is of the type of the table values.
The scalar default_value is the value output for keys not present in the table. It must also be of the same type as the table values.


Looks up keys in a table, outputs the corresponding values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableFindV2
The tensor keys must of the same type as the keys of the table. The output values is of the type of the table values.
The scalar default_value is the value output for keys not present in the table. It must also be of the same type as the table values.


Replaces the contents of the table with the specified keys and values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableImport
The tensor keys must be of the same type as the keys of the table. The tensor values must be of the type of the table values.


Replaces the contents of the table with the specified keys and values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableImportV2
The tensor keys must be of the same type as the keys of the table. The tensor values must be of the type of the table values.


Updates the table to associates keys with values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableInsert
The tensor keys must be of the same type as the keys of the table. The tensor values must be of the type of the table values.


Updates the table to associates keys with values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableInsertV2
The tensor keys must be of the same type as the keys of the table. The tensor values must be of the type of the table values.


Removes keys and its associated values from a table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableRemoveV2
The tensor keys must of the same type as the keys of the table. Keys not already in the table are silently ignored.


Computes the number of elements in the given table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableSize


Computes the number of elements in the given table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LookupTableSizeV2


Forwards the input to the output.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LoopCond
This operator represents the loop termination condition used by the "pivot" switches of a loop.


Applies lower_bound(sorted_search_values, values) along each row.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LowerBound
Each set of rows with the same index in (sorted_inputs, values) is treated independently. The resulting row is the equivalent of calling np.searchsorted(sorted_inputs, values, side='left').
The result is not a global index to the entire Tensor, but rather just the index in the last dimension.
A 2-D example: sorted_sequence = [[0, 3, 9, 9, 10], [1, 2, 3, 4, 5]] values = [[2, 4, 9], [0, 2, 6]]
result = LowerBound(sorted_sequence, values)
result == [[1, 2, 2], [0, 1, 5]]


Local Response Normalization.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LRN
The 4-D input tensor is treated as a 3-D array of 1-D vectors (along the last dimension), and each vector is normalized independently. Within a given vector, each component is divided by the weighted, squared sum of inputs within depth_radius. In detail,
For details, see Krizhevsky et al., ImageNet classification with deep convolutional neural networks (NIPS 2012).


Gradients for Local Response Normalization.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LRNGrad


Computes the LSTM cell forward propagation for 1 time step.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LSTMBlockCell
This implementation uses 1 weight matrix and 1 bias vector, and there's an optional peephole connection.
This kernel op implements the following mathematical equations:


Computes the LSTM cell backward propagation for 1 timestep.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.LSTMBlockCellGrad
This implementation is to be used in conjunction of LSTMBlockCell.


Computes the LU decomposition of one or more square matrices.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Lu
The input is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices.
The input has to be invertible.
The output consists of two tensors LU and P containing the LU decomposition of all input submatrices [..., :, :]. LU encodes the lower triangular and upper triangular factors.
For each input submatrix of shape [M, M], L is a lower triangular matrix of shape [M, M] with unit diagonal whose entries correspond to the strictly lower triangular part of LU. U is a upper triangular matrix of shape [M, M] whose entries correspond to the upper triangular part, including the diagonal, of LU.
P represents a permutation matrix encoded as a list of indices each between 0 and M-1, inclusive. If P_mat denotes the permutation matrix corresponding to P, then the L, U and P satisfies P_mat * input = L * U.


Makes a new iterator from the given dataset and stores it in iterator.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MakeIterator
This operation may be executed multiple times. Each execution will reset the iterator in iterator to the first element of dataset.


Creates a dataset that fuses mapping with batching.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapAndBatchDataset
Creates a dataset that applies f to the outputs of input_dataset and then batches batch_size of them.
Unlike a "MapDataset", which applies f sequentially, this dataset invokes up to batch_size * num_parallel_batches copies of f in parallel.


Op removes all elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapClear


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapDataset


Maps a function on the list of tensors unpacked from arguments on dimension 0.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapDefun
The function given by f is assumed to be stateless, and is executed concurrently on all the slices; up to batch_size (i.e. the size of the 0th dimension of each argument) functions will be scheduled at once.
The max_intra_op_parallelism attr, which defaults to 1, can be used to limit the intra op parallelism. To limit inter-op parallelism, a user can set a private threadpool on the dataset using tf.data.Options's ThreadingOptions.
Note that this op is not exposed to users directly, but is invoked in tf.data rewrites.


Op returns the number of incomplete elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapIncompleteSize


Op peeks at the values at the specified key. If the
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapPeek
underlying container does not contain this key this op will block until it does.


Op returns the number of elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapSize


Stage (key, values) in the underlying container which behaves like a hashtable.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapStage


Op removes and returns the values associated with the key
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapUnstage
from the underlying container. If the underlying container does not contain this key, the op will block until it does.


Op removes and returns a random (key, value)
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MapUnstageNoKey
from the underlying container. If the underlying container does not contain elements, the op will block until it does.


Returns the set of files matching one or more glob patterns.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatchingFiles
Note that this routine only supports wildcard characters in the basename portion of the pattern, not in the directory portion. Note also that the order of filenames returned is deterministic.


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatchingFilesDataset


Multiply the matrix "a" by the matrix "b".
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatMul
The inputs must be two-dimensional matrices and the inner dimension of "a" (after being transposed if transpose_a is true) must match the outer dimension of "b" (after being transposed if transposed_b is true).


Copy a tensor setting everything outside a central band in each innermost matrix to zero.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixBandPart
The band part is computed as follows: Assume input has k dimensions [I, J, K, ..., M, N], then the output is a tensor with the same shape where
band[i, j, k, ..., m, n] = in_band(m, n) * input[i, j, k, ..., m, n].
The indicator function
in_band(m, n) = (num_lower < 0 || (m-n) <= num_lower)) && (num_upper < 0 || (n-m) <= num_upper).


Computes the determinant of one or more square matrices.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDeterminant
The input is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. The output is a tensor containing the determinants for all input submatrices [..., :, :].


Returns a batched diagonal tensor with a given batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiag
Given a diagonal, this operation returns a tensor with the diagonal and everything else padded with zeros. The diagonal is computed as follows:
Assume diagonal has k dimensions [I, J, K, ..., N], then the output is a tensor of rank k+1 with dimensions [I, J, K, ..., N, N]` where:
output[i, j, k, ..., m, n] = 1{m=n} * diagonal[i, j, k, ..., n].


Returns the batched diagonal part of a batched tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiagPart
This operation returns a tensor with the diagonal part of the batched input. The diagonal part is computed as follows:
Assume input has k dimensions [I, J, K, ..., M, N], then the output is a tensor of rank k - 1 with dimensions [I, J, K, ..., min(M, N)] where:
diagonal[i, j, k, ..., n] = input[i, j, k, ..., n, n].
The input must be at least a matrix.


Returns the batched diagonal part of a batched tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiagPartV2
Returns a tensor with the k[0]-th to k[1]-th diagonals of the batched input.
Assume input has r dimensions [I, J, ..., L, M, N]. Let max_diag_len be the maximum length among all diagonals to be extracted, max_diag_len = min(M + min(k[1], 0), N + min(-k[0], 0)) Let num_diags be the number of diagonals to extract, num_diags = k[1] - k[0] + 1.
If num_diags == 1, the output tensor is of rank r - 1 with shape [I, J, ..., L, max_diag_len] and values:
where y = max(-k[1], 0), x = max(k[1], 0).
Otherwise, the output tensor has rank r with dimensions [I, J, ..., L, num_diags, max_diag_len] with values:
where d = k[1] - m, y = max(-d, 0), and x = max(d, 0).
The input must be at least a matrix.


Returns the batched diagonal part of a batched tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiagPartV3
Returns a tensor with the k[0]-th to k[1]-th diagonals of the batched input.
Assume input has r dimensions [I, J, ..., L, M, N]. Let max_diag_len be the maximum length among all diagonals to be extracted, max_diag_len = min(M + min(k[1], 0), N + min(-k[0], 0)) Let num_diags be the number of diagonals to extract, num_diags = k[1] - k[0] + 1.
If num_diags == 1, the output tensor is of rank r - 1 with shape [I, J, ..., L, max_diag_len] and values:
where y = max(-k[1], 0), x = max(k[1], 0).
Otherwise, the output tensor has rank r with dimensions [I, J, ..., L, num_diags, max_diag_len] with values:
where d = k[1] - m, y = max(-d, 0) - offset, and x = max(d, 0) - offset.
offset is zero except when the alignment of the diagonal is to the right.
where diag_len(d) = min(cols - max(d, 0), rows + min(d, 0)).
The input must be at least a matrix.


Returns a batched diagonal tensor with given batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiagV2
Returns a tensor with the contents in diagonal as k[0]-th to k[1]-th diagonals of a matrix, with everything else padded with padding. num_rows and num_cols specify the dimension of the innermost matrix of the output. If both are not specified, the op assumes the innermost matrix is square and infers its size from k and the innermost dimension of diagonal. If only one of them is specified, the op assumes the unspecified value is the smallest possible based on other criteria.
Let diagonal have r dimensions [I, J, ..., L, M, N]. The output tensor has rank r+1 with shape [I, J, ..., L, M, num_rows, num_cols] when only one diagonal is given (k is an integer or k[0] == k[1]). Otherwise, it has rank r with shape [I, J, ..., L, num_rows, num_cols].
The second innermost dimension of diagonal has double meaning. When k is scalar or k[0] == k[1], M is part of the batch size [I, J, ..., M], and the output tensor is:
Otherwise, M is treated as the number of diagonals for the matrix in the same batch (M = k[1]-k[0]+1), and the output tensor is:
where d = n - m, diag_index = k[1] - d, and index_in_diag = n - max(d, 0).


Returns a batched diagonal tensor with given batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixDiagV3
Returns a tensor with the contents in diagonal as k[0]-th to k[1]-th diagonals of a matrix, with everything else padded with padding. num_rows and num_cols specify the dimension of the innermost matrix of the output. If both are not specified, the op assumes the innermost matrix is square and infers its size from k and the innermost dimension of diagonal. If only one of them is specified, the op assumes the unspecified value is the smallest possible based on other criteria.
Let diagonal have r dimensions [I, J, ..., L, M, N]. The output tensor has rank r+1 with shape [I, J, ..., L, M, num_rows, num_cols] when only one diagonal is given (k is an integer or k[0] == k[1]). Otherwise, it has rank r with shape [I, J, ..., L, num_rows, num_cols].
The second innermost dimension of diagonal has double meaning. When k is scalar or k[0] == k[1], M is part of the batch size [I, J, ..., M], and the output tensor is:
Otherwise, M is treated as the number of diagonals for the matrix in the same batch (M = k[1]-k[0]+1), and the output tensor is:
where d = n - m, diag_index = [k] - d, and index_in_diag = n - max(d, 0) + offset.
offset is zero except when the alignment of the diagonal is to the right.
where diag_len(d) = min(cols - max(d, 0), rows + min(d, 0)).


Deprecated, use python implementation tf.linalg.matrix_exponential.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixExponential


Computes the inverse of one or more square invertible matrices or their adjoints (conjugate transposes).
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixInverse
The input is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. The output is a tensor of the same shape as the input containing the inverse for all input submatrices [..., :, :].
The op uses LU decomposition with partial pivoting to compute the inverses.
If a matrix is not invertible there is no guarantee what the op does. It may detect the condition and raise an exception or it may simply return a garbage result.


Computes the matrix logarithm of one or more square matrices:
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixLogarithm
\(log(exp(A)) = A\)
This op is only defined for complex matrices. If A is positive-definite and real, then casting to a complex matrix, taking the logarithm and casting back to a real matrix will give the correct result.
This function computes the matrix logarithm using the Schur-Parlett algorithm. Details of the algorithm can be found in Section 11.6.2 of: Nicholas J. Higham, Functions of Matrices: Theory and Computation, SIAM 2008. ISBN 978-0-898716-46-7.
The input is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. The output is a tensor of the same shape as the input containing the exponential for all input submatrices [..., :, :].


Returns a batched matrix tensor with new batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSetDiag
Given input and diagonal, this operation returns a tensor with the same shape and values as input, except for the main diagonal of the innermost matrices. These will be overwritten by the values in diagonal.
The output is computed as follows:
Assume input has k+1 dimensions [I, J, K, ..., M, N] and diagonal has k dimensions [I, J, K, ..., min(M, N)]. Then the output is a tensor of rank k+1 with dimensions [I, J, K, ..., M, N] where:


Returns a batched matrix tensor with new batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSetDiagV2
Given input and diagonal, this operation returns a tensor with the same shape and values as input, except for the specified diagonals of the innermost matrices. These will be overwritten by the values in diagonal.
input has r+1 dimensions [I, J, ..., L, M, N]. When k is scalar or k[0] == k[1], diagonal has r dimensions [I, J, ..., L, max_diag_len]. Otherwise, it has r+1 dimensions [I, J, ..., L, num_diags, max_diag_len]. num_diags is the number of diagonals, num_diags = k[1] - k[0] + 1. max_diag_len is the longest diagonal in the range [k[0], k[1]], max_diag_len = min(M + min(k[1], 0), N + min(-k[0], 0))
The output is a tensor of rank k+1 with dimensions [I, J, ..., L, M, N]. If k is scalar or k[0] == k[1]:
Otherwise,
where d = n - m, diag_index = k[1] - d, and index_in_diag = n - max(d, 0).


Returns a batched matrix tensor with new batched diagonal values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSetDiagV3
Given input and diagonal, this operation returns a tensor with the same shape and values as input, except for the specified diagonals of the innermost matrices. These will be overwritten by the values in diagonal.
input has r+1 dimensions [I, J, ..., L, M, N]. When k is scalar or k[0] == k[1], diagonal has r dimensions [I, J, ..., L, max_diag_len]. Otherwise, it has r+1 dimensions [I, J, ..., L, num_diags, max_diag_len]. num_diags is the number of diagonals, num_diags = k[1] - k[0] + 1. max_diag_len is the longest diagonal in the range [k[0], k[1]], max_diag_len = min(M + min(k[1], 0), N + min(-k[0], 0))
The output is a tensor of rank k+1 with dimensions [I, J, ..., L, M, N]. If k is scalar or k[0] == k[1]:
Otherwise,
where d = n - m, diag_index = k[1] - d, and index_in_diag = n - max(d, 0) + offset.
offset is zero except when the alignment of the diagonal is to the right.
where diag_len(d) = min(cols - max(d, 0), rows + min(d, 0)).


Solves systems of linear equations.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSolve
Matrix is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. Rhs is a tensor of shape [..., M, K]. The output is a tensor shape [..., M, K]. If adjoint is False then each output matrix satisfies matrix[..., :, :] * output[..., :, :] = rhs[..., :, :]. If adjoint is True then each output matrix satisfies adjoint(matrix[..., :, :]) * output[..., :, :] = rhs[..., :, :].


Solves one or more linear least-squares problems.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSolveLs
matrix is a tensor of shape [..., M, N] whose inner-most 2 dimensions form real or complex matrices of size [M, N]. Rhs is a tensor of the same type as matrix and shape [..., M, K]. The output is a tensor shape [..., N, K] where each output matrix solves each of the equations matrix[..., :, :] * output[..., :, :] = rhs[..., :, :] in the least squares sense.
We use the following notation for (complex) matrix and right-hand sides in the batch:
matrix=\(A \in \mathbb{C}^{m \times n}\), rhs=\(B \in \mathbb{C}^{m \times k}\), output=\(X \in \mathbb{C}^{n \times k}\), l2_regularizer=\(\lambda \in \mathbb{R}\).
If fast is True, then the solution is computed by solving the normal equations using Cholesky decomposition. Specifically, if \(m \ge n\) then \(X = (A^H A + \lambda I)^{-1} A^H B\), which solves the least-squares problem \(X = \mathrm{argmin}_{Z \in \Re^{n \times k} } ||A Z - B||_F^2 + \lambda ||Z||_F^2\). If \(m \lt n\) then output is computed as \(X = A^H (A A^H + \lambda I)^{-1} B\), which (for \(\lambda = 0\)) is the minimum-norm solution to the under-determined linear system, i.e. \(X = \mathrm{argmin}_{Z \in \mathbb{C}^{n \times k} } ||Z||_F^2 \), subject to \(A Z = B\). Notice that the fast path is only numerically stable when \(A\) is numerically full rank and has a condition number \(\mathrm{cond}(A) \lt \frac{1}{\sqrt{\epsilon_{mach} } }\) or \(\lambda\) is sufficiently large.
If fast is False an algorithm based on the numerically robust complete orthogonal decomposition is used. This computes the minimum-norm least-squares solution, even when \(A\) is rank deficient. This path is typically 6-7 times slower than the fast path. If fast is False then l2_regularizer is ignored.
Equivalent to np.linalg.lstsq


Computes the matrix square root of one or more square matrices:
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixSquareRoot
matmul(sqrtm(A), sqrtm(A)) = A
The input matrix should be invertible. If the input matrix is real, it should have no eigenvalues which are real and negative (pairs of complex conjugate eigenvalues are allowed).
The matrix square root is computed by first reducing the matrix to quasi-triangular form with the real Schur decomposition. The square root of the quasi-triangular matrix is then computed directly. Details of the algorithm can be found in: Nicholas J. Higham, "Computing real square roots of a real matrix", Linear Algebra Appl., 1987.
The input is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. The output is a tensor of the same shape as the input containing the matrix square root for all input submatrices [..., :, :].


Solves systems of linear equations with upper or lower triangular matrices by backsubstitution.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MatrixTriangularSolve
matrix is a tensor of shape [..., M, M] whose inner-most 2 dimensions form square matrices. If lower is True then the strictly upper triangular part of each inner-most matrix is assumed to be zero and not accessed. If lower is False then the strictly lower triangular part of each inner-most matrix is assumed to be zero and not accessed. rhs is a tensor of shape [..., M, N].
The output is a tensor of shape [..., M, N]. If adjoint is True then the innermost matrices in output satisfy matrix equations matrix[..., :, :] * output[..., :, :] = rhs[..., :, :]. If adjoint is False then the strictly then the innermost matrices in output satisfy matrix equations adjoint(matrix[..., i, k]) * output[..., k, j] = rhs[..., i, j].
Note, the batch shapes for the inputs only need to broadcast.
Equivalent to scipy.linalg.solve_triangular


Computes the maximum of elements across dimensions of a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Max
Reduces input along the dimensions given in axis. Unless keep_dims is true, the rank of the tensor is reduced by 1 for each entry in axis. If keep_dims is true, the reduced dimensions are retained with length 1.


Returns the max of x and y (i.e. x > y ? x : y) element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Maximum


Creates a dataset that overrides the maximum intra-op parallelism.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxIntraOpParallelismDataset


Performs max pooling on the input.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPool


Performs 3D max pooling on the input.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPool3D


Computes gradients of 3D max pooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPool3DGrad


Computes second-order gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPool3DGradGrad


Computes gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGrad


Computes second-order gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGradGrad


Computes second-order gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGradGradV2


Computes second-order gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGradGradWithArgmax


Computes gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGradV2


Computes gradients of the maxpooling function.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolGradWithArgmax


Performs max pooling on the input.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolV2


Performs max pooling on the input and outputs both max values and indices.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MaxPoolWithArgmax
The indices in argmax are flattened, so that a maximum value at position [b, y, x, c] becomes flattened index: (y * width + x) * channels + c if include_batch_in_index is False; ((b * height + y) * width + x) * channels + c if include_batch_in_index is True.
The indices returned are always in [0, height) x [0, width) before flattening, even if padding is involved and the mathematically correct answer is outside (either negative or too large). This is a bug, but fixing it is difficult to do in a safe backwards compatible way, especially due to flattening.


Computes the mean of elements across dimensions of a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Mean
Reduces input along the dimensions given in axis. Unless keep_dims is true, the rank of the tensor is reduced by 1 for each entry in axis. If keep_dims is true, the reduced dimensions are retained with length 1.


Forwards the value of an available tensor from inputs to output.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Merge
Merge waits for at least one of the tensors in inputs to become available. It is usually combined with Switch to implement branching.
Merge forwards the first tensor to become available to output, and sets value_index to its index in inputs.


Merges summaries.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MergeSummary
This op creates a Summary protocol buffer that contains the union of all the values in the input summaries.
When the Op is run, it reports an InvalidArgument error if multiple values in the summaries to merge use the same tag.


V2 format specific: merges the metadata files of sharded checkpoints. The
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MergeV2Checkpoints
result is one logical checkpoint, with one physical metadata file and renamed data files.
Intended for "grouping" multiple checkpoints in a sharded checkpoint setup.
If delete_old_dirs is true, attempts to delete recursively the dirname of each path in the input checkpoint_prefixes. This is useful when those paths are non user-facing temporary locations.


Transforms a spectrogram into a form that's useful for speech recognition.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Mfcc
Mel Frequency Cepstral Coefficients are a way of representing audio data that's been effective as an input feature for machine learning. They are created by taking the spectrum of a spectrogram (a 'cepstrum'), and discarding some of the higher frequencies that are less significant to the human ear. They have a long history in the speech recognition world, and https://en.wikipedia.org/wiki/Mel-frequency_cepstrum is a good resource to learn more.


Computes the minimum of elements across dimensions of a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Min
Reduces input along the dimensions given in axis. Unless keep_dims is true, the rank of the tensor is reduced by 1 for each entry in axis. If keep_dims is true, the reduced dimensions are retained with length 1.


Returns the min of x and y (i.e. x < y ? x : y) element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Minimum
Both inputs are number-type tensors (except complex). minimum expects that both tensors have the same dtype.
Note that minimum supports broadcast semantics.
If inputs are not tensors, they will be converted to tensors. See tf.convert_to_tensor.


Pads a tensor with mirrored values.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MirrorPad
This operation pads a input with mirrored values according to the paddings you specify. paddings is an integer tensor with shape [n, 2], where n is the rank of input. For each dimension D of input, paddings[D, 0] indicates how many values to add before the contents of input in that dimension, and paddings[D, 1] indicates how many values to add after the contents of input in that dimension. Both paddings[D, 0] and paddings[D, 1] must be no greater than input.dim_size(D) (or input.dim_size(D) - 1) if copy_border is true (if false, respectively).
The padded size of each dimension D of the output is:
paddings(D, 0) + input.dim_size(D) + paddings(D, 1)


Gradient op for MirrorPad op. This op folds a mirror-padded tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MirrorPadGrad
This operation folds the padded areas of input by MirrorPad according to the paddings you specify. paddings must be the same as paddings argument given to the corresponding MirrorPad op.
The folded size of each dimension D of the output is:
input.dim_size(D) - paddings(D, 0) - paddings(D, 1)


Returns element-wise remainder of division. This emulates C semantics in that
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Mod
the result here is consistent with a truncating divide. E.g. tf.truncatediv(x, y) * y + truncate_mod(x, y) = x.


Identity transformation that models performance.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ModelDataset
Identity transformation that models performance.


Returns x * y element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Mul


Returns x * y element-wise. Returns zero if y is zero, even if x if infinite or NaN.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MulNoNan


Creates a MultiDeviceIterator resource.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MultiDeviceIterator


Generates a MultiDeviceIterator resource from its provided string handle.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MultiDeviceIteratorFromStringHandle


Gets next element for the provided shard number.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MultiDeviceIteratorGetNextFromShard


Initializes the multi device iterator with the given dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MultiDeviceIteratorInit


Produces a string handle for the given MultiDeviceIterator.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MultiDeviceIteratorToStringHandle


Draws samples from a multinomial distribution.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Multinomial


Creates an empty hash table that uses tensors as the backing store.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableDenseHashTable
It uses "open addressing" with quadratic reprobing to resolve collisions.
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a scalar. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Creates an empty hash table that uses tensors as the backing store.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableDenseHashTableV2
It uses "open addressing" with quadratic reprobing to resolve collisions.
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a scalar. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Creates an empty hash table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableHashTable
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a scalar. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Creates an empty hash table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableHashTableOfTensors
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a vector. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Creates an empty hash table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableHashTableOfTensorsV2
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a vector. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Creates an empty hash table.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutableHashTableV2
This op creates a mutable hash table, specifying the type of its keys and values. Each value must be a scalar. Data can be inserted into the table using the insert operations. It does not support the initialization operation.


Locks a mutex resource. The output is the lock. So long as the lock tensor
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutexLock
is alive, any other request to use MutexLock with this mutex will wait.
This is particularly useful for creating a critical section when used in conjunction with MutexLockIdentity:
While fn is running in the critical section, no other functions which wish to use this critical section may run.
Often the use case is that two executions of the same graph, in parallel, wish to run fn; and we wish to ensure that only one of them executes at a time. This is especially important if fn modifies one or more variables at a time.
It is also useful if two separate functions must share a resource, but we wish to ensure the usage is exclusive.


Creates a Mutex resource that can be locked by MutexLock.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.MutexV2


Outputs a tensor containing the reduction across all input tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NcclAllReduce
Outputs a tensor containing the reduction across all input tensors passed to ops within the same `shared_name.
The graph should be constructed so if one op runs with shared_name value c, then num_devices ops will run with shared_name value c. Failure to do so will cause the graph execution to fail to complete.
input: the input to the reduction data: the value of the reduction across all num_devices devices. reduction: the reduction operation to perform. num_devices: The number of devices participating in this reduction. shared_name: Identifier that shared between ops of the same reduction.


Sends input to all devices that are connected to the output.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NcclBroadcast
Sends input to all devices that are connected to the output.
The graph should be constructed so that all ops connected to the output have a valid device assignment, and the op itself is assigned one of these devices.
input: The input to the broadcast. output: The same as input. shape: The shape of the input tensor.


Reduces input from num_devices using reduction to a single device.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NcclReduce
Reduces input from num_devices using reduction to a single device.
The graph should be constructed so that all inputs have a valid device assignment, and the op itself is assigned one of these devices.
input: The input to the reduction. data: the value of the reduction across all num_devices devices. reduction: the reduction operation to perform.


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Ndtri


Computes numerical negative value element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Neg
I.e., \(y = -x\).


Returns the next representable value of x1 in the direction of x2, element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NextAfter
This operation returns the same result as the C++ std::nextafter function.
It can also return a subnormal number.
Equivalent to C++ std::nextafter function.


Makes its input available to the next iteration.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NextIteration


Non-deterministically generates some integers.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonDeterministicInts
This op may use some OS-provided source of non-determinism (e.g. an RNG), so each execution will give different results.


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppression
pruning away boxes that have high intersection-over-union (IOU) overlap with previously selected boxes. Bounding boxes are supplied as [y1, x1, y2, x2], where (y1, x1) and (y2, x2) are the coordinates of any diagonal pair of box corners and the coordinates can be provided as normalized (i.e., lying in the interval [0, 1]) or absolute. Note that this algorithm is agnostic to where the origin is in the coordinate system. Note that this algorithm is invariant to orthogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system result in the same boxes being selected by the algorithm. The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example: selected_indices = tf.image.non_max_suppression( boxes, scores, max_output_size, iou_threshold) selected_boxes = tf.gather(boxes, selected_indices)


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppressionV2
pruning away boxes that have high intersection-over-union (IOU) overlap with previously selected boxes. Bounding boxes are supplied as [y1, x1, y2, x2], where (y1, x1) and (y2, x2) are the coordinates of any diagonal pair of box corners and the coordinates can be provided as normalized (i.e., lying in the interval [0, 1]) or absolute. Note that this algorithm is agnostic to where the origin is in the coordinate system. Note that this algorithm is invariant to orthogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system result in the same boxes being selected by the algorithm.
The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example:
selected_indices = tf.image.non_max_suppression_v2( boxes, scores, max_output_size, iou_threshold) selected_boxes = tf.gather(boxes, selected_indices)


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppressionV3
pruning away boxes that have high intersection-over-union (IOU) overlap with previously selected boxes. Bounding boxes with score less than score_threshold are removed. Bounding boxes are supplied as [y1, x1, y2, x2], where (y1, x1) and (y2, x2) are the coordinates of any diagonal pair of box corners and the coordinates can be provided as normalized (i.e., lying in the interval [0, 1]) or absolute. Note that this algorithm is agnostic to where the origin is in the coordinate system and more generally is invariant to orthogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system result in the same boxes being selected by the algorithm. The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example: selected_indices = tf.image.non_max_suppression_v2( boxes, scores, max_output_size, iou_threshold, score_threshold) selected_boxes = tf.gather(boxes, selected_indices)


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppressionV4
pruning away boxes that have high intersection-over-union (IOU) overlap with previously selected boxes. Bounding boxes with score less than score_threshold are removed. Bounding boxes are supplied as [y1, x1, y2, x2], where (y1, x1) and (y2, x2) are the coordinates of any diagonal pair of box corners and the coordinates can be provided as normalized (i.e., lying in the interval [0, 1]) or absolute. Note that this algorithm is agnostic to where the origin is in the coordinate system and more generally is invariant to orthogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system result in the same boxes being selected by the algorithm. The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example: selected_indices = tf.image.non_max_suppression_v2( boxes, scores, max_output_size, iou_threshold, score_threshold) selected_boxes = tf.gather(boxes, selected_indices)


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppressionV5
pruning away boxes that have high intersection-over-union (IOU) overlap with previously selected boxes. Bounding boxes with score less than score_threshold are removed. Bounding boxes are supplied as [y1, x1, y2, x2], where (y1, x1) and (y2, x2) are the coordinates of any diagonal pair of box corners and the coordinates can be provided as normalized (i.e., lying in the interval [0, 1]) or absolute. Note that this algorithm is agnostic to where the origin is in the coordinate system and more generally is invariant to orthogonal transformations and translations of the coordinate system; thus translating or reflections of the coordinate system result in the same boxes being selected by the algorithm. The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example: selected_indices = tf.image.non_max_suppression_v2( boxes, scores, max_output_size, iou_threshold, score_threshold) selected_boxes = tf.gather(boxes, selected_indices) This op also supports a Soft-NMS (with Gaussian weighting) mode (c.f. Bodla et al, https://arxiv.org/abs/1704.04503) where boxes reduce the score of other overlapping boxes instead of directly causing them to be pruned. To enable this Soft-NMS mode, set the soft_nms_sigma parameter to be larger than 0.


Greedily selects a subset of bounding boxes in descending order of score,
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonMaxSuppressionWithOverlaps
pruning away boxes that have high overlaps with previously selected boxes. Bounding boxes with score less than score_threshold are removed. N-by-n overlap values are supplied as square matrix, which allows for defining a custom overlap criterium (eg. intersection over union, intersection over area, etc.).
The output of this operation is a set of integers indexing into the input collection of bounding boxes representing the selected boxes. The bounding box coordinates corresponding to the selected indices can then be obtained using the tf.gather operation. For example:
selected_indices = tf.image.non_max_suppression_with_overlaps( overlaps, scores, max_output_size, overlap_threshold, score_threshold) selected_boxes = tf.gather(boxes, selected_indices)


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NonSerializableDataset


Does nothing. Only useful as a placeholder for control edges.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NoOp


Returns the truth value of (x != y) element-wise.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NotEqual


Finds values of the n-th order statistic for the last dimension.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.NthElement
If the input is a vector (rank-1), finds the entries which is the nth-smallest value in the vector and outputs their values as scalar tensor.
For matrices (resp. higher rank input), computes the entries which is the nth-smallest value in each row (resp. vector along the last dimension). Thus,


Returns a one-hot tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OneHot
The locations represented by indices in indices take value on_value, while all other locations take value off_value.
If the input indices is rank N, the output will have rank N+1, The new axis is created at dimension axis (default: the new axis is appended at the end).
If indices is a scalar the output shape will be a vector of length depth.
If indices is a vector of length features, the output shape will be:
If indices is a matrix (batch) with shape [batch, features], the output shape will be:
Suppose that
Then output is [4 x 3]:
Suppose that
Then output is [3 x 4]:
Suppose that
Then output is [2 x 2 x 3]:


Makes a "one-shot" iterator that can be iterated only once.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OneShotIterator
A one-shot iterator bundles the logic for defining the dataset and the state of the iterator in a single op, which allows simple input pipelines to be defined without an additional initialization ("MakeIterator") step.
One-shot iterators have the following limitations:
For greater flexibility, use "Iterator" and "MakeIterator" to define an iterator using an arbitrary subgraph, which may capture tensors (including fed values) as parameters, and which may be reset multiple times by rerunning "MakeIterator".


Returns a tensor of ones with the same shape and type as x.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OnesLike


Creates a dataset by applying optimizations to input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptimizeDataset
Creates a dataset by applying optimizations to input_dataset.


Creates a dataset by applying related optimizations to input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptimizeDatasetV2
Creates a dataset by applying related optimizations to input_dataset.


Constructs an Optional variant from a tuple of tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptionalFromValue


Returns the value stored in an Optional variant or raises an error if none exists.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptionalGetValue


Returns true if and only if the given Optional variant has a value.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptionalHasValue


Creates an Optional variant with no value.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OptionalNone


Op removes all elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapClear


Op returns the number of incomplete elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapIncompleteSize


Op peeks at the values at the specified key. If the
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapPeek
underlying container does not contain this key this op will block until it does. This Op is optimized for performance.


Op returns the number of elements in the underlying container.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapSize


Stage (key, values) in the underlying container which behaves like a ordered
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapStage
associative container. Elements are ordered by key.


Op removes and returns the values associated with the key
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapUnstage
from the underlying container. If the underlying container does not contain this key, the op will block until it does.


Op removes and returns the (key, value) element with the smallest
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OrderedMapUnstageNoKey
key from the underlying container. If the underlying container does not contain elements, the op will block until it does.


Retrieves a single tensor from the computation outfeed.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedDequeue
This operation will block indefinitely until data is available.


Retrieve multiple values from the computation outfeed.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedDequeueTuple
This operation will block indefinitely until data is available. Output i corresponds to XLA tuple element i.


Retrieve multiple values from the computation outfeed. Device ordinal is a
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedDequeueTupleV2
tensor allowing dynamic outfeed.
This operation will block indefinitely until data is available. Output i corresponds to XLA tuple element i.
Args: device_ordinal: A Tensor of type int32. An int scalar tensor, representing the TPU device to use. This should be -1 when the Op is running on a TPU device, and >= 0 when the Op is running on the CPU device. dtypes: A list of tf.DTypes that has length >= 1. The element types of each element in outputs. shapes: A list of shapes (each a tf.TensorShape or list of ints). The shapes of each tensor in outputs. name: A name for the operation (optional).
Returns: A list of Tensor objects of type dtypes.


Retrieves a single tensor from the computation outfeed. Device ordinal is a
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedDequeueV2
tensor allowing dynamic outfeed.
This operation will block indefinitely until data is available.
Args: device_ordinal: A Tensor of type int32. An int scalar tensor, representing the TPU device to use. This should be -1 when the Op is running on a TPU device, and >= 0 when the Op is running on the CPU device. dtype: A tf.DType. The type of elements in the tensor. shape: A tf.TensorShape or list of ints. The shape of the tensor. name: A name for the operation (optional).
Returns: A Tensor of type dtype.


Enqueue a Tensor on the computation outfeed.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedEnqueue


Enqueue multiple Tensor values on the computation outfeed.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.OutfeedEnqueueTuple


Packs a list of N rank-R tensors into one rank-(R+1) tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Pack
Packs the N tensors in values into a tensor with rank one higher than each tensor in values, by packing them along the axis dimension. Given a list of tensors of shape (A, B, C);
if axis == 0 then the output tensor will have the shape (N, A, B, C). if axis == 1 then the output tensor will have the shape (A, N, B, C). Etc.
This is the opposite of unpack.


Pads a tensor with zeros.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Pad
This operation pads a input with zeros according to the paddings you specify. paddings is an integer tensor with shape [Dn, 2], where n is the rank of input. For each dimension D of input, paddings[D, 0] indicates how many zeros to add before the contents of input in that dimension, and paddings[D, 1] indicates how many zeros to add after the contents of input in that dimension.
The padded size of each dimension D of the output is:
paddings(D, 0) + input.dim_size(D) + paddings(D, 1)


Creates a dataset that batches and pads batch_size elements from the input.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PaddedBatchDataset


Creates a dataset that batches and pads batch_size elements from the input.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PaddedBatchDatasetV2


A queue that produces elements in first-in first-out order.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PaddingFIFOQueue
Variable-size shapes are allowed by setting the corresponding shape dimensions to 0 in the shape attr. In this case DequeueMany will pad up to the maximum size of any given element in the minibatch. See below for details.


A queue that produces elements in first-in first-out order.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PaddingFIFOQueueV2
Variable-size shapes are allowed by setting the corresponding shape dimensions to 0 in the shape attr. In this case DequeueMany will pad up to the maximum size of any given element in the minibatch. See below for details.


Pads a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PadV2
This operation pads input according to the paddings and constant_values you specify. paddings is an integer tensor with shape [Dn, 2], where n is the rank of input. For each dimension D of input, paddings[D, 0] indicates how many padding values to add before the contents of input in that dimension, and paddings[D, 1] indicates how many padding values to add after the contents of input in that dimension. constant_values is a scalar tensor of the same type as input that indicates the value to use for padding input.
The padded size of each dimension D of the output is:
paddings(D, 0) + input.dim_size(D) + paddings(D, 1)


Concatenates a list of N tensors along the first dimension.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelConcat
The input tensors are all required to have size 1 in the first dimension.
The difference between concat and parallel_concat is that concat requires all of the inputs be computed before the operation will begin but doesn't require that the input shapes be known during graph construction. Parallel concat will copy pieces of the input into the output as they become available, in some situations this can provide a performance benefit.


Interleave the values from the data tensors into a single tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelDynamicStitch
Builds a merged tensor such that
For example, if each indices[m] is scalar or vector, we have
Each data[i].shape must start with the corresponding indices[i].shape, and the rest of data[i].shape must be constant w.r.t. i. That is, we must have data[i].shape = indices[i].shape + constant. In terms of this constant, the output shape is
Values may be merged in parallel, so if an index appears in both indices[m][i] and indices[n][j], the result may be invalid. This differs from the normal DynamicStitch operator that defines the behavior in that case.
This method can be used to merge partitions created by dynamic_partition as illustrated on the following example:


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelInterleaveDataset
The resulting dataset is similar to the InterleaveDataset, with the exception that if retrieving the next value from a dataset would cause the requester to block, it will skip that input dataset. This dataset is especially useful when loading data from a variable-latency datastores (e.g. HDFS, GCS), as it allows the training step to proceed so long as some data is available.
!! WARNING !! If the sloppy parameter is set to True, the operation of this dataset will not be deterministic!
This dataset has been superseded by ParallelInterleaveDatasetV2. New code should use ParallelInterleaveDatasetV2.
The Python API tf.data.experimental.parallel_interleave creates instances of this op. tf.data.experimental.parallel_interleave is a deprecated API.


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelInterleaveDatasetV2
The resulting dataset is similar to the InterleaveDataset, except that the dataset will fetch records from the interleaved datasets in parallel.
The tf.data Python API creates instances of this op from Dataset.interleave() when the num_parallel_calls parameter of that method is set to any value other than None.
By default, the output of this dataset will be deterministic, which may result in the dataset blocking if the next data item to be returned isn't available. In order to avoid head-of-line blocking, one can set the experimental_deterministic parameter of tf.data.Options to False, which can improve performance at the expense of non-determinism.


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelInterleaveDatasetV3
The resulting dataset is similar to the InterleaveDataset, except that the dataset will fetch records from the interleaved datasets in parallel.
The tf.data Python API creates instances of this op from Dataset.interleave() when the num_parallel_calls parameter of that method is set to any value other than None.
By default, the output of this dataset will be deterministic, which may result in the dataset blocking if the next data item to be returned isn't available. In order to avoid head-of-line blocking, one can either set the deterministic attribute to "false", or leave it as "default" and set the experimental_deterministic parameter of tf.data.Options to False. This can improve performance at the expense of non-determinism.


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelInterleaveDatasetV4
The resulting dataset is similar to the InterleaveDataset, except that the dataset will fetch records from the interleaved datasets in parallel.
The tf.data Python API creates instances of this op from Dataset.interleave() when the num_parallel_calls parameter of that method is set to any value other than None.
By default, the output of this dataset will be deterministic, which may result in the dataset blocking if the next data item to be returned isn't available. In order to avoid head-of-line blocking, one can either set the deterministic attribute to "false", or leave it as "default" and set the experimental_deterministic parameter of tf.data.Options to False. This can improve performance at the expense of non-determinism.


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelMapDataset
Unlike a "MapDataset", which applies f sequentially, this dataset invokes up to num_parallel_calls copies of f in parallel.


Creates a dataset that applies f to the outputs of input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParallelMapDatasetV2
Unlike a "MapDataset", which applies f sequentially, this dataset invokes up to num_parallel_calls copies of f in parallel.


Outputs random values from a normal distribution. The parameters may each be a
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParameterizedTruncatedNormal
scalar which applies to the entire output, or a vector of length shape[0] which stores the parameters for each batch.


Transforms a vector of brain.Example protos (as strings) into typed tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseExample


Transforms input_dataset containing Example protos as vectors of DT_STRING into a dataset of Tensor or SparseTensor objects representing the parsed features.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseExampleDataset


Transforms input_dataset containing Example protos as vectors of DT_STRING into a dataset of Tensor or SparseTensor objects representing the parsed features.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseExampleDatasetV2


Transforms a vector of tf.Example protos (as strings) into typed tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseExampleV2


Transforms a vector of brain.SequenceExample protos (as strings) into typed tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseSequenceExample


Transforms a vector of tf.io.SequenceExample protos (as strings) into
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseSequenceExampleV2
typed tensors.
Args: serialized: A Tensor of type string. A scalar or vector containing binary serialized SequenceExample protos. debug_name: A Tensor of type string. A scalar or vector containing the names of the serialized protos. May contain, for example, table key (descriptive) name for the corresponding serialized proto. This is purely useful for debugging purposes, and the presence of values here has no effect on the output. May also be an empty vector if no name is available. context_sparse_keys: A Tensor of type string. The keys expected in the Examples' features associated with context_sparse values. context_dense_keys: A Tensor of type string. The keys expected in the SequenceExamples' context features associated with dense values. context_ragged_keys: A Tensor of type string. The keys expected in the Examples' features associated with context_ragged values. feature_list_sparse_keys: A Tensor of type string. The keys expected in the FeatureLists associated with sparse values. feature_list_dense_keys: A Tensor of type string. The keys expected in the SequenceExamples' feature_lists associated with lists of dense values. feature_list_ragged_keys: A Tensor of type string. The keys expected in the FeatureLists associated with ragged values. feature_list_dense_missing_assumed_empty: A Tensor of type bool. A vector corresponding 1:1 with feature_list_dense_keys, indicating which features may be missing from the SequenceExamples. If the associated FeatureList is missing, it is treated as empty. context_dense_defaults: A list of Tensor objects with types from: float32, int64, string. A list of Ncontext_dense Tensors (some may be empty). context_dense_defaults[j] provides default values when the SequenceExample's context map lacks context_dense_key[j]. If an empty Tensor is provided for context_dense_defaults[j], then the Feature context_dense_keys[j] is required. The input type is inferred from context_dense_defaults[j], even when it's empty. If context_dense_defaults[j] is not empty, its shape must match context_dense_shapes[j]. Ncontext_sparse: An optional int that is >= 0. Defaults to 0. context_sparse_types: An optional list of tf.DTypes from: tf.float32, tf.int64, tf.string. Defaults to []. A list of Ncontext_sparse types; the data types of data in each context Feature given in context_sparse_keys. Currently the ParseSingleSequenceExample supports DT_FLOAT (FloatList), DT_INT64 (Int64List), and DT_STRING (BytesList). context_ragged_value_types: An optional list of tf.DTypes from: tf.float32, tf.int64, tf.string. Defaults to []. RaggedTensor.value dtypes for the ragged context features. context_ragged_split_types: An optional list of tf.DTypes from: tf.int32, tf.int64. Defaults to []. RaggedTensor.row_split dtypes for the ragged context features. context_dense_shapes: An optional list of shapes (each a tf.TensorShape or list of ints). Defaults to []. A list of Ncontext_dense shapes; the shapes of data in each context Feature given in context_dense_keys. The number of elements in the Feature corresponding to context_dense_key[j] must always equal context_dense_shapes[j].NumEntries(). The shape of context_dense_values[j] will match context_dense_shapes[j]. Nfeature_list_sparse: An optional int that is >= 0. Defaults to 0. Nfeature_list_dense: An optional int that is >= 0. Defaults to 0. feature_list_dense_types: An optional list of tf.DTypes from: tf.float32, tf.int64, tf.string. Defaults to []. feature_list_sparse_types: An optional list of tf.DTypes from: tf.float32, tf.int64, tf.string. Defaults to []. A list of Nfeature_list_sparse types; the data types of data in each FeatureList given in feature_list_sparse_keys. Currently the ParseSingleSequenceExample supports DT_FLOAT (FloatList), DT_INT64 (Int64List), and DT_STRING (BytesList). feature_list_ragged_value_types: An optional list of tf.DTypes from: tf.float32, tf.int64, tf.string. Defaults to []. RaggedTensor.value dtypes for the ragged FeatureList features. feature_list_ragged_split_types: An optional list of tf.DTypes from: tf.int32, tf.int64. Defaults to []. RaggedTensor.row_split dtypes for the ragged FeatureList features. feature_list_dense_shapes: An optional list of shapes (each a tf.TensorShape or list of ints). Defaults to []. A list of Nfeature_list_dense shapes; the shapes of data in each FeatureList given in feature_list_dense_keys. The shape of each Feature in the FeatureList corresponding to feature_list_dense_key[j] must always equal feature_list_dense_shapes[j].NumEntries(). name: A name for the operation (optional).
Returns: A tuple of Tensor objects (context_sparse_indices, context_sparse_values, context_sparse_shapes, context_dense_values, context_ragged_values, context_ragged_row_splits, feature_list_sparse_indices, feature_list_sparse_values, feature_list_sparse_shapes, feature_list_dense_values, feature_list_dense_lengths, feature_list_ragged_values, feature_list_ragged_outer_splits, feature_list_ragged_inner_splits).


Transforms a tf.Example proto (as a string) into typed tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseSingleExample


Transforms a scalar brain.SequenceExample proto (as strings) into typed tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseSingleSequenceExample


Transforms a serialized tensorflow.TensorProto proto into a Tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.ParseTensor


returns f(inputs), where f's body is placed and partitioned.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PartitionedCall


A placeholder op for a value that will be fed into the computation.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Placeholder
N.B. This operation will fail with an error if it is executed. It is intended as a way to represent a value that will always be fed, and to provide attrs that enable the fed value to be checked at runtime.


A placeholder op for a value that will be fed into the computation.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PlaceholderV2
N.B. This operation will fail with an error if it is executed. It is intended as a way to represent a value that will always be fed, and to provide attrs that enable the fed value to be checked at runtime.


A placeholder op that passes through input when its output is not fed.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PlaceholderWithDefault


Compute the polygamma function \(\psi^{(n)}(x)\).
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Polygamma
The polygamma function is defined as:
\(\psi^{(a)}(x) = \frac{d^a}{dx^a} \psi(x)\)
where \(\psi(x)\) is the digamma function. The polygamma function is defined only for non-negative integer orders \a\.


Computes element-wise population count (a.k.a. popcount, bitsum, bitcount).
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PopulationCount
For each entry in x, calculates the number of 1 (on) bits in the binary representation of that entry.


Computes the power of one value to another.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Pow
Given a tensor x and a tensor y, this operation computes \(x^y\) for corresponding elements in x and y. For example:


Creates a dataset that asynchronously prefetches elements from input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PrefetchDataset


An op which linearizes one Tensor value to an opaque variant tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Prelinearize


An op which linearizes multiple Tensor values to an opaque variant tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PrelinearizeTuple


An identity op that triggers an error if a gradient is requested.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PreventGradient
When executed in a graph, this op outputs its input tensor as-is.
When building ops to compute gradients, the TensorFlow gradient system will return an error when trying to lookup the gradient of this op, because no gradient must ever be registered for this function. This op exists to prevent subtle bugs from silently returning unimplemented gradients in some corner cases.


Prints a list of tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Print
Passes input through to output and prints data when evaluating.


Prints a string scalar.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PrintV2
Prints a string scalar to the desired output_stream.


A queue that produces elements sorted by the first component value.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PriorityQueue
Note that the PriorityQueue requires the first component of any element to be a scalar int64, in addition to the other elements declared by component_types. Therefore calls to Enqueue and EnqueueMany (resp. Dequeue and DequeueMany) on a PriorityQueue will all require (resp. output) one extra entry in their input (resp. output) lists.


A queue that produces elements sorted by the first component value.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PriorityQueueV2
Note that the PriorityQueue requires the first component of any element to be a scalar int64, in addition to the other elements declared by component_types. Therefore calls to Enqueue and EnqueueMany (resp. Dequeue and DequeueMany) on a PriorityQueue will all require (resp. output) one extra entry in their input (resp. output) lists.


Creates a dataset that uses a custom thread pool to compute input_dataset.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PrivateThreadPoolDataset


Computes the product of elements across dimensions of a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Prod
Reduces input along the dimensions given in axis. Unless keep_dims is true, the rank of the tensor is reduced by 1 for each entry in axis. If keep_dims is true, the reduced dimensions are retained with length 1.


Invokes a python function to compute func(input)->output.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PyFunc
This operation is considered stateful. For a stateless version, see PyFuncStateless.


A stateless version of PyFunc.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.PyFuncStateless


Computes the QR decompositions of one or more matrices.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.Qr
Computes the QR decomposition of each inner matrix in tensor such that tensor[..., :, :] = q[..., :, :] * r[..., :,:])
Currently, the gradient for the QR decomposition is well-defined only when the first P columns of the inner matrix are linearly independent, where P is the minimum of M and N, the 2 inner-most dimmensions of tensor.


Use QuantizeAndDequantizeV2 instead.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeAndDequantize


Quantizes then dequantizes a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeAndDequantizeV2
This op simulates the precision loss from the quantized forward pass by:
There are different ways to quantize. This version uses only scaling, so 0.0 maps to 0.
From the specified 'num_bits' in the quantized output type, it determines minimum and maximum representable quantized values.
e.g.
If range_given == False, the initial input_min, input_max will be determined automatically as the minimum and maximum values in the input tensor, otherwise the specified values of input_min, input_max are used.
This op determines the maximum scale_factor that would map the initial [input_min, input_max] range to a range that lies within the representable quantized range.
It determines the scale from one of input_min and input_max, then updates the other one to maximize the representable range.
e.g.
After determining the scale_factor and updating the input range, it applies the following to each value in the 'input' tensor.
output = round(clamp(value, input_min, input_max) * scale_factor) / scale_factor.
The above round function rounds the value based on the given round_mode.


Quantizes then dequantizes a tensor.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeAndDequantizeV3
This is almost identical to QuantizeAndDequantizeV2, except that num_bits is a tensor, so its value can change during training.


Returns the gradient of QuantizeAndDequantizeV4.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeAndDequantizeV4
This is almost identical to QuantizeAndDequantizeV2, except that it returns a gradient of 1 for inputs that are within the quantization range, or 0 otherwise.


Returns the gradient of QuantizeAndDequantizeV4.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeAndDequantizeV4Grad
Returns a gradient of 1 for inputs that are within the quantization range, or 0 otherwise.


Returns x + y element-wise, working on quantized buffers.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedAdd


Produces the average pool of the input tensor for quantized types.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedAvgPool


Quantized Batch normalization.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedBatchNormWithGlobalNormalization
This op is deprecated and will be removed in the future. Prefer tf.nn.batch_normalization.


Adds Tensor 'bias' to Tensor 'input' for Quantized types.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedBiasAdd
Broadcasts the values of bias on dimensions 0..N-2 of 'input'.


Concatenates quantized tensors along one dimension.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConcat


Computes a 2D convolution given quantized 4D input and filter tensors.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2D
The inputs are quantized tensors where the lowest value represents the real number of the associated minimum, and the highest represents the maximum. This means that you can only interpret the quantized output in the same way, by taking the returned minimum and maximum values into account.


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DAndRelu


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DAndReluAndRequantize


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DAndRequantize


Computes QuantizedConv2D per channel.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DPerChannel


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBias


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasAndRelu


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasAndReluAndRequantize


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasAndRequantize


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasSignedSumAndReluAndRequantize


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasSumAndRelu


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedConv2DWithBiasSumAndReluAndRequantize


Computes quantized depthwise Conv2D.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedDepthwiseConv2D


Computes quantized depthwise Conv2D with Bias.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedDepthwiseConv2DWithBias


Computes quantized depthwise Conv2D with Bias and Relu.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedDepthwiseConv2DWithBiasAndRelu


Computes quantized depthwise Conv2D with Bias, Relu and Requantize.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedDepthwiseConv2DWithBiasAndReluAndRequantize


Quantized Instance normalization.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedInstanceNorm


Perform a quantized matrix multiplication of a by the matrix b.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMul
The inputs must be two-dimensional matrices and the inner dimension of a (after being transposed if transpose_a is non-zero) must match the outer dimension of b (after being transposed if transposed_b is non-zero).


Performs a quantized matrix multiplication of a by the matrix b with bias
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMulWithBias
add.
The inputs must be two-dimensional matrices and 1D bias vector. And the inner dimension of a (after being transposed if transpose_a is non-zero) must match the outer dimension of b (after being transposed if transposed_b is non-zero). Then do broadcast add operation with bias values on the matrix multiplication result. The bias size must match inner dimension of b.
Args: a: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied. Must be a two-dimensional tensor of type quint8. b: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied and must be a two-dimensional tensor of type qint8. bias: A Tensor. Must be one of the following types: float32, qint32. A 1D bias tensor with size matching inner dimension of b (after being transposed if transposed_b is non-zero). min_a: A Tensor of type float32. The float value that the lowest quantized a value represents. max_a: A Tensor of type float32. The float value that the highest quantized a value represents. min_b: A Tensor of type float32. The float value that the lowest quantized b value represents. max_b: A Tensor of type float32. The float value that the highest quantized b value represents. Toutput: An optional tf.DType from: tf.qint8, tf.quint8, tf.qint32, tf.qint16, tf.quint16. Defaults to tf.qint32. transpose_a: An optional bool. Defaults to False. If true, a is transposed before multiplication. transpose_b: An optional bool. Defaults to False. If true, b is transposed before multiplication. input_quant_mode: An optional string from: "MIN_FIRST", "SCALED". Defaults to "MIN_FIRST". Input data quantization mode. Either MIN_FIRST(default) or SCALED. name: A name for the operation (optional).
Returns: A tuple of Tensor objects (out, min_out, max_out).


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMulWithBiasAndDequantize


Perform a quantized matrix multiplication of a by the matrix b with bias
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMulWithBiasAndRelu
add and relu fusion.
The inputs must be two-dimensional matrices and 1D bias vector. And the inner dimension of a (after being transposed if transpose_a is non-zero) must match the outer dimension of b (after being transposed if transposed_b is non-zero). Then do broadcast add operation with bias values on the matrix multiplication result. The bias size must match inner dimension of b. Then do relu activation to get non-negative result.
Args: a: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied. Must be a two-dimensional tensor of type quint8. b: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied and must be a two-dimensional tensor of type qint8. bias: A Tensor of type float32. A 1D bias tensor with size matching with inner dimension of b (after being transposed if transposed_b is non-zero). min_a: A Tensor of type float32. The float value that the lowest quantized a value represents. max_a: A Tensor of type float32. The float value that the highest quantized a value represents. min_b: A Tensor of type float32. The float value that the lowest quantized b value represents. max_b: A Tensor of type float32. The float value that the highest quantized b value represents. Toutput: An optional tf.DType from: tf.qint8, tf.quint8, tf.qint32, tf.qint16, tf.quint16. Defaults to tf.qint32. transpose_a: An optional bool. Defaults to False. If true, a is transposed before multiplication. transpose_b: An optional bool. Defaults to False. If true, b is transposed before multiplication. input_quant_mode: An optional string from: "MIN_FIRST", "SCALED". Defaults to "MIN_FIRST". Input data quantization mode. Either MIN_FIRST(default) or SCALED. name: A name for the operation (optional).
Returns: A tuple of Tensor objects (out, min_out, max_out).


Perform a quantized matrix multiplication of a by the matrix b with bias
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMulWithBiasAndReluAndRequantize
add and relu and requantize fusion.
The inputs must be two-dimensional matrices and 1D bias vector. And the inner dimension of a (after being transposed if transpose_a is non-zero) must match the outer dimension of b (after being transposed if transposed_b is non-zero). Then do broadcast add operation with bias values on the matrix multiplication result. The bias size must match inner dimension of b. Then do relu activation to get non-negative result. Then do requantize operation to get final uint8 result.
Args: a: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied. Must be a two-dimensional tensor of type quint8. b: A Tensor. Must be one of the following types: qint8, quint8, qint32, qint16, quint16. A matrix to be multiplied and must be a two-dimensional tensor of type qint8. bias: A Tensor. Must be one of the following types: float32, qint32. A 1D bias tensor with size matching with inner dimension of b (after being transposed if transposed_b is non-zero). min_a: A Tensor of type float32. The float value that the lowest quantized a value represents. max_a: A Tensor of type float32. The float value that the highest quantized a value represents. min_b: A Tensor of type float32. The float value that the lowest quantized b value represents. max_b: A Tensor of type float32. The float value that the highest quantized b value represents. min_freezed_output: A Tensor of type float32. The float value that the highest quantized output value after requantize. max_freezed_output: A Tensor of type float32. Toutput: An optional tf.DType from: tf.qint8, tf.quint8, tf.qint32, tf.qint16, tf.quint16. Defaults to tf.quint8. transpose_a: An optional bool. Defaults to False. If true, a is transposed before multiplication. transpose_b: An optional bool. Defaults to False. If true, b is transposed before multiplication. input_quant_mode: An optional string from: "MIN_FIRST", "SCALED". Defaults to "MIN_FIRST". Input data quantization mode. Either MIN_FIRST(default) or SCALED. name: A name for the operation (optional).
Returns: A tuple of Tensor objects (out, min_out, max_out).


Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMatMulWithBiasAndRequantize


Produces the max pool of the input tensor for quantized types.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMaxPool


Returns x * y element-wise, working on quantized buffers.
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizedMul


Convert the quantized 'input' tensor into a lower-precision 'output', using the
Compat aliases for migration
See Migration guide for more details.
tf.compat.v1.raw_ops.QuantizeDownAndShrinkRange
actual distribution of the values to maximize the usage of the lower bit depth and adjusting the output min and max ranges accordingly.
[input_min, input_max] are scalar floats that specify the range for the float interpretation of the 'input' data. For example, if input_min is -1.0f and input_max is 1.0f, and we are dealing with quint16 quantized data, then a 0 value in the 16-bit data should be interpreted as -1.0f, and a 65535 means 1.0f.
This operator tries to squeeze as much precision as possible into an output with a lower bit depth by calculating the actual min and max values found in the data. For example, maybe that quint16 input has no values lower than 16,384 and none higher than 49,152. That means only half the range is actually needed, all the float interpretations are between -0.5f and 0.5f, so if we want to compress the data into a quint8 output, we can use that range rather than the theoretical -1.0f to 1.0f that is suggested by the input min and max.
In practice, this is most useful for taking output from operations like QuantizedMatMul that can produce higher bit-depth outputs than their inputs and may have large potential output ranges, but in practice have a distribution of input values that only uses a small fraction of the possible range. By feeding that output into this operator, we can reduce it from 32 bits down to 8 with minimal loss of accuracy.