Skip to content

Commit

Permalink
Add check for empty prediction labels (#1725)
Browse files Browse the repository at this point in the history
  • Loading branch information
holtvogt authored Aug 17, 2022
1 parent 903a9d2 commit d21fa99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mmdet3d/core/visualizer/show_result.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ def show_result(points,

vis = Visualizer(points)
if pred_bboxes is not None:
if pred_labels is None:
if pred_labels is None or pred_labels.numel() == 0:
vis.add_bboxes(bbox3d=pred_bboxes)
else:
palette = np.random.randint(
Expand Down

0 comments on commit d21fa99

Please sign in to comment.