Computes the QR decompositions of one or more matrices.
View aliases
Compat aliases for migration
See Migration guide for more details.
tf.raw_ops.Qr(
input, full_matrices=False, name=None
)
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
.
# a is a tensor.
# q is a tensor of orthonormal matrices.
# r is a tensor of upper triangular matrices.
q, r = qr(a)
q_full, r_full = qr(a, full_matrices=True)