paascorb commited on
Commit
a652ef7
1 Parent(s): 9efeb3c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -11,7 +11,7 @@ model = models.ross.efficientdet.model(backbone=models.ross.efficientdet.backbon
11
  num_classes=2,
12
  img_size=384)
13
 
14
- state_dict = torch.load(checkpoint_path)
15
  model.load_state_dict(state_dict)
16
 
17
  infer_tfms = tfms.A.Adapter([*tfms.A.resize_and_pad(384),tfms.A.Normalize()])
 
11
  num_classes=2,
12
  img_size=384)
13
 
14
+ state_dict = torch.load(checkpoint_path, map_location=torch.device('cpu'))
15
  model.load_state_dict(state_dict)
16
 
17
  infer_tfms = tfms.A.Adapter([*tfms.A.resize_and_pad(384),tfms.A.Normalize()])