I guess your self.transform contains some image transformations other than ToTensor(), e.g. RandomCrop().
These transformations currently work on PIL.Images, so if you load your image with img = Image.open(this_img) it should work.