mirror of
https://github.com/ultralytics/yolov5.git
synced 2025-06-03 14:49:29 +08:00
parent
02719dde52
commit
3213d8713f
@ -1116,7 +1116,7 @@ def dataset_stats(path='coco128.yaml', autodownload=False, verbose=False):
|
|||||||
nc = data['nc'] # number of classes
|
nc = data['nc'] # number of classes
|
||||||
stats = {'nc': nc, 'names': data['names']} # statistics dictionary
|
stats = {'nc': nc, 'names': data['names']} # statistics dictionary
|
||||||
for split in 'train', 'val', 'test':
|
for split in 'train', 'val', 'test':
|
||||||
if split not in data:
|
if data.get(split) is None:
|
||||||
stats[split] = None # i.e. no test set
|
stats[split] = None # i.e. no test set
|
||||||
continue
|
continue
|
||||||
x = []
|
x = []
|
||||||
|
Loading…
x
Reference in New Issue
Block a user