excuse me. I also encounter this problem when I run the code below in a forward() function(code is in the image). If I comment the guess_img_dist_arr[n]=(torch.norm(guess_img[y][x]-guess_img[y_co][x_co]))
It will not raise the error, but get a wrong result.
could you tell me how to fix this?

屏幕快照 2017-12-21 上午12.36.27.png1480×754 88.2 KB