I have torch.tensor which has dimension of 0 x 240 x 3 x 540 x 960
I just want to remove 0 dimension, so I want to have pytorch tensor
size of 240 x 3 x 540 x 960.
I used tensor= torch.squeeze(tensor) to try that, but zero dimension was not removed...
In my case, the size of tensor is variable so I can't hard code it to torch.squeeze..
Is there any simple way to remove undesired dimension in pytorch.tensor?