updates
This commit is contained in:
parent
3834b77961
commit
e701979862
|
@ -688,7 +688,7 @@ def kmeans_targets(path='../coco/trainvalno5k.txt', n=9, img_size=416): # from
|
||||||
wh = np.concatenate(dataset.labels, 0)[:, 3:5] # wh from cxywh
|
wh = np.concatenate(dataset.labels, 0)[:, 3:5] # wh from cxywh
|
||||||
|
|
||||||
# Kmeans calculation
|
# Kmeans calculation
|
||||||
k = cluster.vq.kmeans(wh, n)[0]
|
k, dist = cluster.vq.kmeans(wh, n) # points, mean distance
|
||||||
k = k[np.argsort(k.prod(1))] # sort small to large
|
k = k[np.argsort(k.prod(1))] # sort small to large
|
||||||
|
|
||||||
# Measure IoUs
|
# Measure IoUs
|
||||||
|
|
Loading…
Reference in New Issue