Calculates determinant of a 2D square tensor.

tch_det(x)

Arguments

x

tensor object

Examples

x <- tensor(matrix(runif(36), ncol = 6)) tch_det(x)
#> tensor #> 0.00503185 #> [ Variable[CPUFloatType]{} ]