Thanks Ivan for your answer  !



 ivan-jgr:

remember that in an image you can only have [0, 255] value (i.e. 8 bits)


My images are 16 bits png, so the values go from [0, 65536]. Before ToTensor() transformation does PyTorch change these to 8 bits?



 ivan-jgr:

Torch will normalize [0, 65536] → [0, 1] or [0, 255] → [0, 1]


So the transformation just divides each element from de image matrix representation by 65536 (16 bits in my case) and I get a representation of the same interval [0, 65536] but in float data type [0, 1]. Am I right?