From c403560b99afb1dac490d1e861f99401ca6ff50e Mon Sep 17 00:00:00 2001 From: Jim Martens Date: Thu, 29 Aug 2019 12:33:42 +0200 Subject: [PATCH] Added none check Signed-off-by: Jim Martens --- src/twomartens/masterthesis/ssd.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/twomartens/masterthesis/ssd.py b/src/twomartens/masterthesis/ssd.py index 15c3416..1bfed1b 100644 --- a/src/twomartens/masterthesis/ssd.py +++ b/src/twomartens/masterthesis/ssd.py @@ -471,7 +471,7 @@ def _get_observations(detections: Sequence[np.ndarray]) -> List[np.ndarray]: used_boxes = None for j in range(overlaps.shape[0]): # check if box is already in existing observation - if j in used_boxes: + if used_boxes is not None and j in used_boxes: continue box_overlaps = overlaps[j]