yikang-li / FactorizableNet

Factorizable Net (Multi-GPU version): An Efficient Subgraph-based Framework for Scene Graph Generation
216 stars 38 forks source link

undefined symbol: _ZN6caffe26detail36_typeMetaDataInstance_preallocated_4 #15

Closed berthyf96 closed 5 years ago

berthyf96 commented 5 years ago

After setting up the environment, I tried evaluating the model but keep running into this error:

Traceback (most recent call last):
  File "train_FN.py", line 20, in <module>
    import lib.datasets as datasets
  File "/n/fs/cap/bfeng/FactorizableNet/lib/datasets/__init__.py", line 10, in <module>
    from .VRD_loader import VRD
  File "/n/fs/cap/bfeng/FactorizableNet/lib/datasets/VRD_loader.py", line 19, in <module>
    from lib.rpn_msr.anchor_target_layer import anchor_target_layer
  File "/n/fs/cap/bfeng/FactorizableNet/lib/rpn_msr/anchor_target_layer.py", line 20, in <module>
    from lib.fast_rcnn.bbox_transform import bbox_transform
  File "/n/fs/cap/bfeng/FactorizableNet/lib/fast_rcnn/__init__.py", line 9, in <module>
    from . import nms_wrapper
  File "/n/fs/cap/bfeng/FactorizableNet/lib/fast_rcnn/nms_wrapper.py", line 8, in <module>
    from lib.layer_utils.roi_layers import nms as nms_gpu
  File "/n/fs/cap/bfeng/FactorizableNet/lib/layer_utils/roi_layers/__init__.py", line 3, in <module>
    from .nms import nms
  File "/n/fs/cap/bfeng/FactorizableNet/lib/layer_utils/roi_layers/nms.py", line 3, in <module>
    from layer_utils import _C
ImportError: /n/fs/cap/bfeng/FactorizableNet/lib/layer_utils/_C.cpython-36m-x86_64-linux-gnu.so: undefined symbol: _ZN6caffe26detail36_typeMetaDataInstance_preallocated_4E

I ran make in the lib folder with gcc version 5.3.1, CUDA 9.0, PyTorch 0.4.1. Can someone please help with this error?

yikang-li commented 5 years ago

Can you have a try of pytorch 1.0?

I cannot reproduce the problem. It seems that there is something wrong running the make.

berthyf96 commented 5 years ago

I created a new compiling environment with Python 2.7 and it works now! It works with Python 2.7, PyTorch 0.4.1, and CUDA 9.0.

yikang-li commented 5 years ago

Cool! Thanks for your information.