Attend the Women in ML Symposium on December 7 Register now

Eig

public final class Eig

Computes the eigen decomposition of one or more square matrices.

Computes the eigenvalues and (optionally) right eigenvectors of each inner matrix in `input` such that `input[..., :, :] = v[..., :, :] * diag(e[..., :])`. The eigenvalues are sorted in non-decreasing order.

# a is a tensor.
 # e is a tensor of eigenvalues.
 # v is a tensor of eigenvectors.
 e, v = eig(a)
 e = eig(a, compute_v=False)
 

Nested Classes

class Eig.Options Optional attributes for Eig  

Public Methods

static Eig.Options
computeV(Boolean computeV)
static <U, T> Eig<U>
create(Scope scope, Operand<T> input, Class<U> Tout, Options... options)
Factory method to create a class wrapping a new Eig operation.
Output<U>
e()
Eigenvalues.
Output<U>
v()
Eigenvectors.

Inherited Methods

Public Methods

public static Eig.Options computeV (Boolean computeV)

Parameters
computeV If `True` then eigenvectors will be computed and returned in `v`. Otherwise, only the eigenvalues will be computed.

public static Eig<U> create (Scope scope, Operand<T> input, Class<U> Tout, Options... options)

Factory method to create a class wrapping a new Eig operation.

Parameters
scope current scope
input `Tensor` input of shape `[N, N]`.
options carries optional attributes values
Returns
  • a new instance of Eig

public Output<U> e ()

Eigenvalues. Shape is `[N]`.

public Output<U> v ()

Eigenvectors. Shape is `[N, N]`.