imgTensor = torchvision.transforms.ToTensor(img)
TypeError: object() takes no parameters
getting this issue, but when I checked the documentation the function is suppose to use image as a parameter
imgTensor = torchvision.transforms.ToTensor(img)
TypeError: object() takes no parameters
getting this issue, but when I checked the documentation the function is suppose to use image as a parameter
Try imgTensor = torchvision.transforms.ToTensor()(img)
thanks … imgTensor = torchvision.transforms.ToTensor()(img) worked fine