-
Notifications
You must be signed in to change notification settings - Fork 31
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
shift_kernel & shift_cuda_kernel compiled but can not import #6
Comments
Thanks @Grant-Tao for trying out our repo. In order to help me reproduce the error, can you please provide the command that you ran to get each of the 2 errors? Thanks |
Big thanks for quick answer. my gcc is of version 7.4, all others are your requirements. the errors appeared when i use "import shift_kernel" and "import shift_cuda_kernel" btw, you did not mention anything about batchnorm operation in your paper, how do you deal with batchnorm in your shift network. maybe i am wrong |
Hello @Grant-Tao Regarding batchnorm, we have left it intact and simply used PyTorch's batchnorm op as is. We may look into the future on implementing batchnorm with bitwise shifts.
|
Sorry for the delay. We have made a big refactoring of the code. Can you checkout the master branch and try again? |
I forgot to say, you will need to run |
Hi, I have a related question about the cuda\cpp version of shift kernel. Since you mentioned that the cuda kernel is only for testing. I wonder what's the difference between cuda implementation and common conv implementation with suitable round as in your code. I don't know if I made this clear. It seems the conv implementation of Shift in your code <modules.py> and <modules_q.py> is exactly the same as Shift function. I wonder what is the effort to implement it using CUDA kernel? BTW, why is the CUDA kernel implementation not available for training stage? |
Hi @msxiaojin
Please don't hesitate if any of the points I made were not clear. |
Thanks for the reply. You've made this very clear to me. And thanks for the brilliant work! |
Successfully setup everything, and compiled shift_kernel, but when import shift_kernel, error message appeared:
ImportError: /home/grant/venv/lib/python3.6/site-packages/shift_kernel-0.0.0-py3.6-linux-x86_64.egg/shift_kernel.cpython-36m-x86_64-linux-gnu.so: undefined symbol: _ZN6caffe26detail36_typeMetaDataInstance_preallocated_4E
For shift_cuda_kernel, the error message is:
Segmentation fault (core dumped)
I am working on Ubuntu 18.04, others are as required.
The text was updated successfully, but these errors were encountered: