glenn-jocher commited on
Commit
72d0614
1 Parent(s): bafbc65

Multi-GPU disabled in test.py

Browse files
Files changed (1) hide show
  1. test.py +3 -3
test.py CHANGED
@@ -1,7 +1,6 @@
1
  import argparse
2
  import json
3
 
4
- import yaml
5
  from torch.utils.data import DataLoader
6
 
7
  from utils.datasets import *
@@ -40,8 +39,9 @@ def test(data,
40
  if half:
41
  model.half() # to FP16
42
 
43
- if device.type != 'cpu' and torch.cuda.device_count() > 1:
44
- model = nn.DataParallel(model)
 
45
 
46
  else: # called by train.py
47
  training = True
 
1
  import argparse
2
  import json
3
 
 
4
  from torch.utils.data import DataLoader
5
 
6
  from utils.datasets import *
 
39
  if half:
40
  model.half() # to FP16
41
 
42
+ # Multi-GPU disabled, incompatible with .half()
43
+ # if device.type != 'cpu' and torch.cuda.device_count() > 1:
44
+ # model = nn.DataParallel(model)
45
 
46
  else: # called by train.py
47
  training = True