Browse Source

Update autoanchor.py with yaml.SafeLoader (#1971)

5.0
Abhiram V GitHub 3 years ago
parent
commit
17751b9891
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
      utils/autoanchor.py

+ 1
- 1
utils/autoanchor.py View File

@@ -98,7 +98,7 @@ def kmean_anchors(path='./data/coco128.yaml', n=9, img_size=640, thr=4.0, gen=10

if isinstance(path, str): # *.yaml file
with open(path) as f:
data_dict = yaml.load(f, Loader=yaml.FullLoader) # model dict
data_dict = yaml.load(f, Loader=yaml.SafeLoader) # model dict
from utils.datasets import LoadImagesAndLabels
dataset = LoadImagesAndLabels(data_dict['train'], augment=True, rect=True)
else:

Loading…
Cancel
Save