facebookresearch / facebookresearch/detectron2
Getting started commands to test not working!
- Dominant language
- Python
- Stars
- 34.7k
- Forks
- 7.9k
- PR merge metrics
- No merged PRs in 30d
Description
As given in the documentation i used the following command-
```
cd demo/
python demo.py --config-file ../configs/COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x.yaml \
--input input1.jpg input2.jpg \
[--other-options]
--opts MODEL.WEIGHTS detectron2://COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x/137849600/model_final_f10217.pkl
```
`
the command i used-`
`python3 demo/demo.py --config-file ../configs/COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x.yaml --webcam --opts MODEL.WEIGHTS detectron2://COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x/137849600/model_final_f10217.pkl`
**error i got-**
```
File "/usr/local/lib/python3.7/site-packages/detectron2/config/config.py", line 45, in merge_from_file
assert PathManager.isfile(cfg_filename), f"Config file '{cfg_filename}' does not exist!"
AssertionError: Config file '../configs/COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x.yaml' does not exist!
```
not understanding why this error also, **why i did python3 instead of python is because-**
`python demo/demo.py --config-file ../configs/COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x.yaml --webcam --opts MODEL.WEIGHTS detectron2://COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x/137849600/model_final_f10217.pkl`
**error-**
`ImportError: dlopen(/opt/homebrew/Caskroom/miniforge/base/envs/detectron/lib/python3.9/site-packages/pycocotools/_mask.cpython-39-darwin.so, 0x0002): tried: '/opt/homebrew/Caskroom/miniforge/base/envs/detectron/lib/python3.9/site-packages/pycocotools/_mask.cpython-39-darwin.so' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), '/usr/local/lib/_mask.cpython-39-darwin.so' (no such file), '/usr/lib/_mask.cpython-39-darwin.so' (no such file)`
Contributor guide
Research direction
Start with demo/demo.py and the documented command, checking the working directory and whether ../configs/COCO-InstanceSegmentation/mask_rcnn_R_50_FPN_3x.yaml is present. Then inspect the reported pycocotools architecture error in the Python environment. Done is not defined by the issue because it does not identify a specific code or documentation change.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- computer-vision, machine-learning
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100