facebookresearch / Detectron

FAIR's research platform for object detection research, implementing popular algorithms like Mask R-CNN and RetinaNet.
Apache License 2.0
26.25k stars 5.46k forks source link

No module named caffe2 when trying to using pretrained detectron model #900

Open romass12 opened 5 years ago

romass12 commented 5 years ago

Python = 3.7

python tools/infer_simple.py --cfg ~/projects/tablebank/model_final.pkl --output-dir /tmp/detectron-tablebank --image-ext jpg Traceback (most recent call last): File "tools/infer_simple.py", line 36, in from caffe2.python import workspace ModuleNotFoundError: No module named 'caffe2'

archanray commented 5 years ago

please go through: https://github.com/facebookresearch/Detectron/blob/master/INSTALL.md

specifically: https://caffe2.ai/docs/getting-started.html?platform=mac&configuration=prebuilt change the platform and installation type accordingly. I generally do pre-built binaries.

Note: Caffe2 supports only 2.7 and 3.6 as of now (officially).