Change the Image

Hi everyone,
I had a basic question,
I have a (3x288x169) image and I want to change it to (288x169x3).
Some on remember how to do it in PyTorch?

Thanks,
Morag

If your tensor is called x, do:
x = x.transpose(0, 1).transpose(1, 2)

This left shifts all the axes by one position.

ValueError: axes don’t match array

I just tried this solution with your exact image size. This works:
43%20PM

Can you upload a more complete version of the error along with your code? This will enable others to help you better :sweat_smile: