New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ImportError:_pointnet2.so: undefined symbol: PyInt_FromLong #18
Comments
What version of python are you using (I have been using 3.6)? Also, what does |
$ ldd _pointnet2.so |
And what version of python? |
It's python 3.5, I will try 3.6 |
I want to use the code with python2.7, where should I edit? |
I'm not sure. I have never seen that error personally as I've ever only used this repo with python 3.6. |
Did a little googling, it seems that If you want to keep using python3, you will need to edit the cmake file here: https://github.com/erikwijmans/Pointnet2_PyTorch/blob/master/CMakeLists.txt#L12 to point to the specific version of python instead of just If you want to use python2.7, there shouldn't be undefined symbol errors, but you will need to add the necessary |
hi erikwijmans:
environment of my computer is ubuntu16.04, cuda9.0 pytorch0.4.1 and gtx 1060
I just follow your steps:
1.mkdir build && cd build
2.cmake .. && make
and successful
But when I run the train_sem_seg.py , I got the error.
/usr/bin/python3.5 /home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/train/train_sem_seg.py
Traceback (most recent call last):
File "/home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/train/train_sem_seg.py", line 11, in
from pointnet2.models import Pointnet2SemMSG as Pointnet
File "/home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/init.py", line 1, in
from . import utils
File "/home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/utils/init.py", line 1, in
from . import pointnet2_utils
File "/home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/utils/pointnet2_utils.py", line 10, in
from pointnet2.utils._ext import pointnet2
File "/home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/utils/_ext/pointnet2/init.py", line 3, in
from ._pointnet2 import lib as _lib, ffi as _ffi
ImportError: /home/mengzhen/PointNet/Pointnet2_PyTorch/pointnet2/utils/_ext/pointnet2/_pointnet2.so: undefined symbol: PyInt_FromLong
Process finished with exit code 1
could you help me?
Thank you very much!
Smm
The text was updated successfully, but these errors were encountered: