mindspore/docs/api/api_python/ops/mindspore.ops.MatrixTriangu...

29 lines
1.4 KiB
ReStructuredText
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

mindspore.ops.MatrixTriangularSolve
===================================
.. py:class:: mindspore.ops.MatrixTriangularSolve(lower=True, adjoint=False)
返回一个新Tensor其为含上三角矩阵或下三角矩阵的线性方程组的解。
.. note::
仅在GPU上支持广播机制。
参数:
- **lower** (bool可选) - 如果为True `matrix` 的最内矩阵为下三角矩阵。默认值: ``True``
- **adjoint** (bool可选) - 指明是否使用矩阵的伴随矩阵进行求解。默认值: ``False`` ,使用转置矩阵进行求解。
输入:
- **matrix** (Tensor) - Tensor其shape为 :math:`(*, M, M)` 类型支持float32、float64、complex64和complex128。
- **rhs** (Tensor) - Tensor其shape为 :math:`(*, M, N)` 类型支持float32、float64、complex64和complex128。
输出:
Tensor其shape为 :math:`(*, M, N)` ,数据类型与 `matrix` 相同。
异常:
- **TypeError** - 如果 `matrix``rhs` 不是Tensor。
- **TypeError** - 如果 `lower``adjoint` 不是bool型。
- **ValueError** - 如果在GPU平台上 `matrix``rhs` 的batch大小不满足广播条件或者在\
其他平台上 `matrix``rhs` 的batch大小不相等。
- **ValueError** - 如果 `matrix` 的最内两维不相等。
- **ValueError** - 如果 `matrix``rhs` 的倒数第二维不相等。