
Last chance! 50% off unlimited learning
Sale ends in
Fliplr
torch_fliplr(self)
(Tensor) Must be at least 2-dimensional.
Flip array in the left/right direction, returning a new tensor.
Flip the entries in each row in the left/right direction. Columns are preserved, but appear in a different order than before.
# NOT RUN {
if (torch_is_installed()) {
x <- torch_arange(start = 0, end = 4)$view(c(2, 2))
x
torch_fliplr(x)
}
# }
Run the code above in your browser using DataLab