mmfewshot icon indicating copy to clipboard operation
mmfewshot copied to clipboard

cannot import name 'show_result_pyplot' from 'mmdet.apis'

Open londumas opened this issue 1 year ago • 4 comments

Running the demo does not work with latest mmdetection.

Here is the proposed dem

python demo/demo_attention_rpn_detector_inference.py \
 demo/demo_detection_images/query_images/demo_query.jpg \
 configs/detection/attention_rpn/coco/attention-rpn_r50_c4_4xb2_coco_base-training.py     \
 https://download.openmmlab.com/mmfewshot/detection/attention_rpn/coco/attention-rpn_r50_c4_4xb2_coco_base-training_20211102_003348-da28cdfd.pth \
  --support-images-dir demo/demo_detection_images/support_images

The error is:

Traceback (most recent call last):
  File "<me>/mmfewshot/demo/demo_attention_rpn_detector_inference.py", line 14, in <module>
    from mmdet.apis import show_result_pyplot
ImportError: cannot import name 'show_result_pyplot' from 'mmdet.apis' (<me>/mmdetection/mmdet/apis/__init__.py)

londumas avatar Jun 12 '23 08:06 londumas

I encountered the same issue when attempting to run the demo.

rweaton-ai avatar Sep 25 '23 23:09 rweaton-ai

+1

cuicuiv avatar Dec 24 '23 15:12 cuicuiv

me too, when trying to migrate from mmdet 2.X to 3.X

matanPercepto avatar Dec 27 '23 19:12 matanPercepto

Check this out. https://github.com/open-mmlab/mmdetection/issues/10829#issuecomment-1763519179

sabrina19950113 avatar Mar 07 '24 14:03 sabrina19950113