|TensorFlow 1 version||View source on GitHub|
Base class defining a [batch of] linear operator[s].
Compat aliases for migration
See Migration guide for more details.
tf.linalg.LinearOperator( dtype, graph_parents=None, is_non_singular=None, is_self_adjoint=None, is_positive_definite=None, is_square=None, name=None )
LinearOperator provide access to common methods on a
(batch) matrix, without the need to materialize the matrix. This allows:
- Matrix free computations
- Operators that take advantage of special structure, while providing a consistent API to users.
To enable a public method, subclasses should implement the leading-underscore
version of the method. The argument signature should be identical except for
the omission of
name="...". For example, to enable
matmul(x, adjoint=False, name="matmul") a subclass should implement
Subclasses should only implement the assert methods
assert_non_singular) if they can be done in less than
Class docstrings should contain an explanation of computational complexity. Since this is a high-performance library, attention should be paid to detail, and explanations can include constants as well as Big-O notation.
LinearOperator subclasses should operate on a [batch] matrix with
compatible shape. Class docstrings should define what is meant by compatible
shape. Some subclasses may not support batching.
x is a batch matrix with compatible shape for
operator.shape = [B1,...,Bb] + [M, N], b >= 0, x.shape = [B1,...,Bb] + [N, R]
rhs is a batch matrix with compatible shape for