Skip to content

Commit 2bb0423

Browse files
fix saliency map colour conversion
Signed-off-by: Ashwin Vaidya <[email protected]>
1 parent 046fcb2 commit 2bb0423

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/python/model_api/visualizer/scene/detection.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ def _get_overlays(self, result: DetectionResult) -> list[Overlay]:
3434
# Index 0 as it assumes only one batch
3535
if result.saliency_map is not None and result.saliency_map.size > 0:
3636
saliency_map = cv2.applyColorMap(result.saliency_map[0][label_index], cv2.COLORMAP_JET)
37+
saliency_map = cv2.cvtColor(saliency_map, cv2.COLOR_BGR2RGB)
3738
overlays.append(Overlay(saliency_map, label=label_name.title()))
3839
return overlays
3940

0 commit comments

Comments
 (0)