Commit
•
1e2cb6b
1
Parent(s):
ad71d2d
ONNX export explicit cpu map_location
Browse files- models/onnx_export.py +1 -1
models/onnx_export.py
CHANGED
@@ -25,7 +25,7 @@ if __name__ == '__main__':
|
|
25 |
|
26 |
# Load pytorch model
|
27 |
google_utils.attempt_download(opt.weights)
|
28 |
-
model = torch.load(opt.weights)['model']
|
29 |
model.eval()
|
30 |
model.fuse()
|
31 |
|
|
|
25 |
|
26 |
# Load pytorch model
|
27 |
google_utils.attempt_download(opt.weights)
|
28 |
+
model = torch.load(opt.weights, map_location=torch.device('cpu'))['model']
|
29 |
model.eval()
|
30 |
model.fuse()
|
31 |
|