Theem commited on
Commit
db89d15
1 Parent(s): 41cb296

fix map_locations

Browse files
Files changed (1) hide show
  1. README.md +1 -1
README.md CHANGED
@@ -12,7 +12,7 @@ The file is given as a state_dict. Thus to initialize the model run:
12
 
13
  ```
14
  # Load pretrained weights
15
- state_dict = torch.load(model_path, map_location=torch.device('cpu'))['model']
16
  # Load torchvision model
17
  model = torchvision.models.detection.fasterrcnn_resnet50_fpn(weights=None)
18
  # Adapt input convolution
 
12
 
13
  ```
14
  # Load pretrained weights
15
+ state_dict = torch.load(model_path)['model']
16
  # Load torchvision model
17
  model = torchvision.models.detection.fasterrcnn_resnet50_fpn(weights=None)
18
  # Adapt input convolution