parent
3ef3a95cfa
commit
f2de1ad2aa
4
test.py
4
test.py
|
@ -188,8 +188,8 @@ def test(data,
|
||||||
|
|
||||||
# Per target class
|
# Per target class
|
||||||
for cls in torch.unique(tcls_tensor):
|
for cls in torch.unique(tcls_tensor):
|
||||||
ti = (cls == tcls_tensor).nonzero(as_tuple=False).view(-1) # prediction indices
|
ti = (cls == tcls_tensor).nonzero(as_tuple=False).view(-1) # target indices
|
||||||
pi = (cls == pred[:, 5]).nonzero(as_tuple=False).view(-1) # target indices
|
pi = (cls == pred[:, 5]).nonzero(as_tuple=False).view(-1) # prediction indices
|
||||||
|
|
||||||
# Search for detections
|
# Search for detections
|
||||||
if pi.shape[0]:
|
if pi.shape[0]:
|
||||||
|
|
Loading…
Reference in New Issue