What did you expect to see?
test success
What did you observe instead?
import utils.c2
ImportError: No module named c2
E.g.:
python2 $DETECTRON/tests/test_spatial_narrow_as_op.py
PYTHONPATH
environment variable: /usr/local:/opt/ros/indigo/lib/python2.7/dist-packages:/usr/local::/home/znjs/caffe2/build:/home/znjs/caffe2/buildpython --version
output: Python 2.7.6Hi~ You should include /detectron/lib in your pythonpath.
Hi @earlysleepearlyup, please make sure that you have set up Python modules following the installation instructions.
Relevant extract:
Set up Python modules:
cd $DETECTRON/lib && make
@YoungMagic @ir413 Thank you very much !
I have solved this problem. Because I had installed apollo-kernel.So my PC enter the apollo-kernel automatically when boot the PC.
In this kernel,I can't driver my nvidia GPU cards. And then this problem comes out.
I tried to change my common kernel to solve this problem successfully.
Thank you !
@earlysleepearlyup could you tell me how to change the apollo kernel? I am facing the same problem as you..
@DanielNehemiah When you enter the ubuntu os,you can select the Linux x.x.x-xx-generic
Thanks! @earlysleepearlyup The issue was I had installed detectron with sudo and so detectron only works when i use sudo in the terminal
@YoungMagic But there is no lib folder under DETECTRON project
You just can simply add the cloned detectron path (the one that contains another subdirectory named 'detectron') to your PYTHONPATH
Ok. There is no detectron/lib anymore in this repo? Am I looking to the wrong place?
Ok. There is no detectron/lib anymore in this repo? Am I looking to the wrong place?
You just add this command export PYTHONPATH=/your/path/to/detection:$PYTHONPATH
to your bashrc file.
It works on my machine.
Hope helps.
Most helpful comment
@YoungMagic But there is no lib folder under DETECTRON project