det

paddle.linalg. det ( x, name=None ) [source]

Calculates determinant value of a square matrix or batches of square matrices. :param x: input (Tensor): the input matrix of size (n, n) or the batch of matrices of size

System Message: ERROR/3 (/usr/local/lib/python3.8/site-packages/paddle/tensor/linalg.py:docstring of paddle.tensor.linalg.det, line 3)

Unexpected indentation.

(*, n, n) where * is one or more batch dimensions.

System Message: WARNING/2 (/usr/local/lib/python3.8/site-packages/paddle/tensor/linalg.py:docstring of paddle.tensor.linalg.det, line 4)

Block quote ends without a blank line; unexpected unindent.

Returns

the determinant value of a square matrix or batches of square matrices.

Return type

y (Tensor)

Examples


import paddle

x = paddle.randn([3,3,3])

A = paddle.linalg.det(x)

print(A)

# [ 0.02547996, 2.52317095, -6.15900707])