
Last chance! 50% off unlimited learning
Sale ends in
Maximum
torch_maximum(self, other)
(Tensor) the input tensor.
(Tensor) the second input tensor
Computes the element-wise maximum of input
and other
.
# NOT RUN {
if (torch_is_installed()) {
a <- torch_tensor(c(1, 2, -1))
b <- torch_tensor(c(3, 0, 4))
torch_maximum(a, b)
}
# }
Run the code above in your browser using DataLab