Unverified Commit 7b95816b authored by myproblemchild's avatar myproblemchild Committed by GitHub
Browse files

Use round() instead of int() when displaying score in OD API (#8419)

parent d59897d4
......@@ -1045,9 +1045,9 @@ def visualize_boxes_and_labels_on_image_array(
display_str = str(class_name)
if not skip_scores:
if not display_str:
display_str = '{}%'.format(int(100*scores[i]))
display_str = '{}%'.format(round(100*scores[i]))
else:
display_str = '{}: {}%'.format(display_str, int(100*scores[i]))
display_str = '{}: {}%'.format(display_str, round(100*scores[i]))
if not skip_track_ids and track_ids is not None:
if not display_str:
display_str = 'ID {}'.format(track_ids[i])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment