T
- data type for q()
output@Operator(group="linalg") public final class Qr<T> extends PrimitiveOp
Computes the QR decomposition of each inner matrix in `tensor` such that `tensor[..., :, :] = q[..., :, :] * r[..., :,:])`
# 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)
Modifier and Type | Class and Description |
---|---|
static class |
Qr.Options
Optional attributes for
Qr |
operation
Modifier and Type | Method and Description |
---|---|
static <T> Qr<T> |
create(Scope scope,
Operand<T> input,
Qr.Options... options)
Factory method to create a class wrapping a new Qr operation.
|
static Qr.Options |
fullMatrices(Boolean fullMatrices) |
Output<T> |
q()
Orthonormal basis for range of `a`.
|
Output<T> |
r()
Triangular factor.
|
equals, hashCode, op, toString
public static <T> Qr<T> create(Scope scope, Operand<T> input, Qr.Options... options)
scope
- current scopeinput
- A tensor of shape `[..., M, N]` whose inner-most 2 dimensions
form matrices of size `[M, N]`. Let `P` be the minimum of `M` and `N`.options
- carries optional attributes valuespublic static Qr.Options fullMatrices(Boolean fullMatrices)
fullMatrices
- If true, compute full-sized `q` and `r`. If false
(the default), compute only the leading `P` columns of `q`.public Output<T> q()
Copyright © 2022. All rights reserved.