label-studio-ml-backend icon indicating copy to clipboard operation
label-studio-ml-backend copied to clipboard

AttributeError: 'ConfigDict' object has no attribute 'test_cfg'

Open ealpha opened this issue 2 years ago • 3 comments

Load new model from: /label-studio-ml-backend/mmdetection/configs/faster_rcnn/faster_rcnn_r50_fpn_1x_coco.py /label-studio-ml-backend/mmdetection/checkpoints/faster_rcnn_r50_fpn_1x_coco_20200130-047c8118.pth [2022-05-22 04:13:15,529] [ERROR] [label_studio_ml.exceptions::exception_f::53] Traceback (most recent call last):

Traceback (most recent call last): File "label_studio_ml/exceptions.py", line 39, in exception_f return f(*args, **kwargs) File "label_studio_ml/api.py", line 50, in _setup model = _manager.fetch(project, schema, force_reload, hostname=hostname, access_token=access_token) File "label_studio_ml/model.py", line 502, in fetch model = cls.model_class(label_config=label_config, **kwargs) File "coco-detector/mmdetection.py", line 68, in init self.model = init_detector(config_file, checkpoint_file, device=device) File "/miniconda3/envs/open-mmlab/lib/python3.8/site-packages/mmdet/apis/inference.py", line 34, in init_detector model = build_detector(config.model, test_cfg=config.test_cfg) File "/miniconda3/envs/open-mmlab/lib/python3.8/site-packages/mmcv/utils/config.py", line 363, in getattr return getattr(self._cfg_dict, name) File "/miniconda3/envs/open-mmlab/lib/python3.8/site-packages/mmcv/utils/config.py", line 43, in getattr raise ex AttributeError: 'ConfigDict' object has no attribute 'test_cfg'

ealpha avatar May 22 '22 04:05 ealpha

Hi @ealpha Do you use this model localy or in docker? Could you please write your packages versions (ml backend, mmdet, etc)?

KonstantinKorotaev avatar May 30 '22 11:05 KonstantinKorotaev

i tried with the same configuration for object detection and got a similar error. it is some issue with mmdet and mmcv.

vishal-ranjan avatar Jul 21 '22 03:07 vishal-ranjan

i tried with the same configuration for object detection and got a similar error. it is some issue with mmdet and mmcv.

Do you run it locally or in docker?

KonstantinKorotaev avatar Jul 21 '22 09:07 KonstantinKorotaev

Closed as unanswered issue.

makseq avatar Mar 09 '23 18:03 makseq