# step 1: convert it to [0 ,2]
tensor_image = tensor_image +1

 # step 2: convert it to [0 ,1]
tensor_image = tensor_image - tensor_image.min()
tensor_image_0_1 = tensor_image / (tensor_image.max() - tensor_image.min())