from mmdet.apis import init_detector, inference_detector
config_file = 'rtmdet_tiny_8xb32-300e_coco.py'
checkpoint_file = 'rtmdet_tiny_8xb32-300e_coco_20220902_112414-78e30dcc.pth'
model = init_detector(config_file, checkpoint_file, device='cpu') # or device='cuda:0'
inference_detector(model, 'demo/demo.jpg')
Above is the code for the Verification installation section in the official documentation.
In previous versions of the mmdet,i can use show_result_pyplot( ) to visualize the result in image.
from mmdet.apis import show_result_pyplot
But in latest mmdet i can't import show_result_pyplot( ) from mmdet.apis.
How can i visualize Class DetDataSample results in image in latest mmdet?
Above is the code for the Verification installation section in the official documentation. In previous versions of the mmdet,i can use show_result_pyplot( ) to visualize the result in image.
But in latest mmdet i can't import show_result_pyplot( ) from mmdet.apis. How can i visualize Class DetDataSample results in image in latest mmdet?