tf.raw_ops.Lu
Stay organized with collections
Save and categorize content based on your preferences.
Computes the LU decomposition of one or more square matrices.
tf.raw_ops.Lu(
input,
output_idx_type=tf.dtypes.int32
,
name=None
)
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.
Args |
input
|
A Tensor . Must be one of the following types: float64 , float32 , half , complex64 , complex128 .
A tensor of shape [..., M, M] whose inner-most 2 dimensions form matrices of
size [M, M] .
|
output_idx_type
|
An optional tf.DType from: tf.int32, tf.int64 . Defaults to tf.int32 .
|
name
|
A name for the operation (optional).
|
Returns |
A tuple of Tensor objects (lu, p).
|
lu
|
A Tensor . Has the same type as input .
|
p
|
A Tensor of type output_idx_type .
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates. Some content is licensed under the numpy license.
Last updated 2024-04-26 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-04-26 UTC."],[],[],null,["# tf.raw_ops.Lu\n\n\u003cbr /\u003e\n\nComputes the LU decomposition of one or more square matrices.\n\n#### View aliases\n\n\n**Compat aliases for migration**\n\nSee\n[Migration guide](https://www.tensorflow.org/guide/migrate) for\nmore details.\n\n[`tf.compat.v1.raw_ops.Lu`](https://www.tensorflow.org/api_docs/python/tf/raw_ops/Lu)\n\n\u003cbr /\u003e\n\n tf.raw_ops.Lu(\n input,\n output_idx_type=../../tf/dtypes#int32,\n name=None\n )\n\nThe input is a tensor of shape `[..., M, M]` whose inner-most 2 dimensions\nform square matrices.\n\nThe input has to be invertible.\n\nThe output consists of two tensors LU and P containing the LU decomposition\nof all input submatrices `[..., :, :]`. LU encodes the lower triangular and\nupper triangular factors.\n\nFor each input submatrix of shape `[M, M]`, L is a lower triangular matrix of\nshape `[M, M]` with unit diagonal whose entries correspond to the strictly lower\ntriangular part of LU. U is a upper triangular matrix of shape `[M, M]` whose\nentries correspond to the upper triangular part, including the diagonal, of LU.\n\nP represents a permutation matrix encoded as a list of indices each between `0`\nand `M-1`, inclusive. If P_mat denotes the permutation matrix corresponding to\nP, then the L, U and P satisfies P_mat \\* input = L \\* U.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|-------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `input` | A `Tensor`. Must be one of the following types: `float64`, `float32`, `half`, `complex64`, `complex128`. A tensor of shape `[..., M, M]` whose inner-most 2 dimensions form matrices of size `[M, M]`. |\n| `output_idx_type` | An optional [`tf.DType`](../../tf/dtypes/DType) from: `tf.int32, tf.int64`. Defaults to [`tf.int32`](../../tf#int32). |\n| `name` | A name for the operation (optional). |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Returns ------- ||\n|------|-------------------------------------------|\n| A tuple of `Tensor` objects (lu, p). ||\n| `lu` | A `Tensor`. Has the same type as `input`. |\n| `p` | A `Tensor` of type `output_idx_type`. |\n\n\u003cbr /\u003e"]]