How to resize a tensor or image

Just a note: the backward of upsampling, and interpolate (upscale) is not deterministic. (see here) (Pytorch 1.0.0, 1.0.1).