reverse plotting low to high confidence (#1448)
This commit is contained in:
parent
f14c143926
commit
3d09ca366c
@ -121,7 +121,7 @@ def detect(save_img=False):
|
||||
s += '%g %ss, ' % (n, names[int(c)]) # add to string
|
||||
|
||||
# Write results
|
||||
for *xyxy, conf, cls in det:
|
||||
for *xyxy, conf, cls in reversed(det):
|
||||
if save_txt: # Write to file
|
||||
xywh = (xyxy2xywh(torch.tensor(xyxy).view(1, 4)) / gn).view(-1).tolist() # normalized xywh
|
||||
with open(save_path[:save_path.rfind('.')] + '.txt', 'a') as file:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user