torchvision.transforms uses either PIL as the backend for PIL.Images or the equivalent tensor manipulations (which should yield the same results as PIL).
Could you explain which delta is wrongly multiplied in which function?