powered by
Isinf
torch_isinf(self)
(Tensor) A tensor to check
Returns a new tensor with boolean elements representing if each element is +/-INF or not.
+/-INF
if (torch_is_installed()) { torch_isinf(torch_tensor(c(1, Inf, 2, -Inf, NaN))) }
Run the code above in your browser using DataLab