Thank you @ptrblck, the resize transform was not the issue here but I figured out it was actually due to the fact that my images are mainly blue and that the Grayscale transform multiply blue values by 0.114. I solved the problem by manually setting the max value to 1. I still don’t know why the ToTensor() function didn’t normalize the values between 0 and 1 after the Grayscal transform though.
Here is my solution:
img = Image.open("myimg.png")
img = img_transforms(img)
img*= (1.0/img.max())