Spaces:
Runtime error
Runtime error
i dummy
Browse files
model.py
CHANGED
@@ -25,8 +25,8 @@ class ImageLoader():
|
|
25 |
torchvision.transforms.ToTensor(),
|
26 |
torchvision.transforms.Resize(256),
|
27 |
torchvision.transforms.CenterCrop(224),
|
28 |
-
torchvision.transforms.Normalize((.485, .456, .406), (.229, .224, .225))
|
29 |
-
|
30 |
def load(self, im_path):
|
31 |
im = torch.FloatTensor(self.transformer(Image.open(im_path))).unsqueeze(0)
|
32 |
return {"image": im}
|
|
|
25 |
torchvision.transforms.ToTensor(),
|
26 |
torchvision.transforms.Resize(256),
|
27 |
torchvision.transforms.CenterCrop(224),
|
28 |
+
torchvision.transforms.Normalize((.485, .456, .406), (.229, .224, .225))])
|
29 |
+
|
30 |
def load(self, im_path):
|
31 |
im = torch.FloatTensor(self.transformer(Image.open(im_path))).unsqueeze(0)
|
32 |
return {"image": im}
|