Browse Source

Update test.py with yaml.SafeLoader (#1969)

5.0
Abhiram V GitHub 3 years ago
parent
commit
91c30e4eff
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      test.py

+ 1
- 1
test.py View File

@@ -68,7 +68,7 @@ def test(data,
model.eval()
is_coco = data.endswith('coco.yaml') # is COCO dataset
with open(data) as f:
data = yaml.load(f, Loader=yaml.FullLoader) # model dict
data = yaml.load(f, Loader=yaml.SafeLoader) # model dict
check_dataset(data) # check
nc = 1 if single_cls else int(data['nc']) # number of classes
iouv = torch.linspace(0.5, 0.95, 10).to(device) # iou vector for mAP@0.5:0.95

Loading…
Cancel
Save