Skip to content

Commit

Permalink
[Fix] Fix browse dataset (#9401)
Browse files Browse the repository at this point in the history
* [Fix] Fix browse dataset.

* clean code
  • Loading branch information
RangiLyu authored Nov 29, 2022
1 parent 59f35db commit b30c875
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions mmdet/visualization/local_visualizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,7 @@ def add_datasample(
and masks. Defaults to 0.3.
step (int): Global step value to record. Defaults to 0.
"""
image = image.clip(0, 255).astype(np.uint8)
classes = self.dataset_meta.get('CLASSES', None)
palette = self.dataset_meta.get('PALETTE', None)

Expand Down
1 change: 1 addition & 0 deletions tools/analysis_tools/browse_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ def main():
osp.basename(img_path),
img,
data_sample,
draw_pred=False,
show=not args.not_show,
wait_time=args.show_interval,
out_file=out_file)
Expand Down

0 comments on commit b30c875

Please sign in to comment.