def slogdet(x, name=None):
    "\n    Calculates the sign and natural logarithm of the absolute value of a square matrix's or batches square matrices' determinant.\n    The determinant can be computed with ``sign * exp(logabsdet)\n\n    Supports input of float, double\n\n    Note that for matrices that have zero determinant, this returns ``(0, -inf)``\n    Args:\n        x (Tensor): the batch of matrices of size :math:`(*, n, n)`\n            where math:`*` is one or more batch dimensions.\n\n    Returns:\n        y (Tensor): A tensor containing the sign of the determinant and the natural logarithm\n        of the absolute value of determinant, respectively.\n\n    Examples:\n    .. code-block:: python\n\n        import paddle\n\n        x =  paddle.randn([3,3,3])\n\n        A = paddle.linalg.slogdet(x)\n\n        print(A)\n\n        # [[ 1.        ,  1.        , -1.        ],\n        # [-0.98610914, -0.43010661, -0.10872950]])\n\n    "
    if paddle.in_dynamic_mode():
        return _C_ops.slogdeterminant(x)
    check_dtype(x.dtype, 'Input', ['float32', 'float64'], 'slogdet')
    input_shape = list(x.shape)
    assert (len(input_shape) >= 2), ("The x must be at least 2-dimensional, but received Input x's dimensional: %s.\n" % len(input_shape))
    assert (input_shape[(- 1)] == input_shape[(- 2)]), ('Expect squared input,but received %s by %s matrix.\n' % (input_shape[(- 2)], input_shape[(- 1)]))
    helper = LayerHelper('slogdeterminant', **locals())
    out = helper.create_variable_for_type_inference(dtype=x.dtype)
    helper.append_op(type='slogdeterminant', inputs={'Input': [x]}, outputs={'Out': [out]})
    return out
Calculates the sign and natural logarithm of the absolute value of a square matrix's or batches square matrices' determinant.
The determinant can be computed with ``sign * exp(logabsdet)

Supports input of float, double

Note that for matrices that have zero determinant, this returns ``(0, -inf)``
Args:
    x (Tensor): the batch of matrices of size :math:`(*, n, n)`
        where math:`*` is one or more batch dimensions.

Returns:
    y (Tensor): A tensor containing the sign of the determinant and the natural logarithm
    of the absolute value of determinant, respectively.

Examples:
.. code-block:: python

    import paddle

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

    A = paddle.linalg.slogdet(x)

    print(A)

    # [[ 1.        ,  1.        , -1.        ],
    # [-0.98610914, -0.43010661, -0.10872950]])
def slogdet(x, name=None):
    "\n    Calculates the sign and natural logarithm of the absolute value of a square matrix's or batches square matrices' determinant.\n    The determinant can be computed with ``sign * exp(logabsdet)\n\n    Supports input of float, double\n\n    Note that for matrices that have zero determinant, this returns ``(0, -inf)``\n    Args:\n        x (Tensor): the batch of matrices of size :math:`(*, n, n)`\n            where math:`*` is one or more batch dimensions.\n\n    Returns:\n        y (Tensor): A tensor containing the sign of the determinant and the natural logarithm\n        of the absolute value of determinant, respectively.\n\n    Examples:\n    .. code-block:: python\n\n        import paddle\n\n        x =  paddle.randn([3,3,3])\n\n        A = paddle.linalg.slogdet(x)\n\n        print(A)\n\n        # [[ 1.        ,  1.        , -1.        ],\n        # [-0.98610914, -0.43010661, -0.10872950]])\n\n    "
    if paddle.in_dynamic_mode():
        return _C_ops.slogdeterminant(x)
    check_dtype(x.dtype, 'Input', ['float32', 'float64'], 'slogdet')
    input_shape = list(x.shape)
    assert (len(input_shape) >= 2), ("The x must be at least 2-dimensional, but received Input x's dimensional: %s.\n" % len(input_shape))
    assert (input_shape[(- 1)] == input_shape[(- 2)]), ('Expect squared input,but received %s by %s matrix.\n' % (input_shape[(- 2)], input_shape[(- 1)]))
    helper = LayerHelper('slogdeterminant', **locals())
    out = helper.create_variable_for_type_inference(dtype=x.dtype)
    helper.append_op(type='slogdeterminant', inputs={'Input': [x]}, outputs={'Out': [out]})
    return out