let input be of the shape of (BxCxHxW), and I want to flip along the Width.
in numpy I would have my input = input[:, :, :, ::-1]. How can I recreate the same results using torch.flip? I can’t seem to be able to get it right.
I am stupid…
it is just torch.flip(input, (3,))
doc said it should be a tuple of ints so I was confuse…
1 Like