Closed fengyang0317 closed 10 years ago
rename the selective_search_ijcv_with_python-master folder to selective_search_ijcv_with_python and add its path to sys.path.
@fengyang0317 hi, how did you install it ? just download the codes ? do i need to have matlab installed ? thanks
I fixed the problem and I told the details to someone who needed.
ImportError: No module named selective_search_ijcv_with_python
I rename the file selective_search_ijcv_with_python_master
to selective_search_ijcv_with_python
and put it under the caffe root. Then added the path to the PYTHONPATH and validate it by import selective_search_ijcv_with_python
in python mode.
I am having the same problem. There is no longer such file as "selective_search_ijcv_with_python_master".
I added C:\projects\caffe\examples\selective_search_ijcv_with_python to PYTHONPATH as instructed and did a test to show it works.
import selective_search_ijcv_with_python as selective_search
In addition, the following test also show the path is added properly:
import sys print(sys.path) ['', 'C:\projects\caffe\examples\selective_search_ijcv_with_python', .... <- OK
However, when I ran detect.py on the command line, it gives me the error "ImportError: No module named selective_search_ijcv_with_python". I traced the line in detector.py that did the import and added the following two lines right before the actual import command, still no luck:
import sys
sys.path.append('C:\projects\caffe\examples\selective_search_ijcv_with_python')
import selective_search_ijcv_with_python as selective_search # <- the troubled import line
Here is the detailed message:
c:\projects\caffe\examples>python ..\python\detect.py --crop_mode=selective_search --pretrained_model=..\models\bvlc_reference_rcnn_ilsvrc13\bvlc_reference_rcnn_ilsvrc13.caffemodel --model_def=..\models\bvlc_reference_rcnn_ilsvrc13\deploy.prototxt --gpu --raw_scale=255 _temp\det_input.txt _temp\det_output.h5
Traceback (most recent call last):
File "..\python\detect.py", line 28, in
I have add the path of selective_search_ijcv_with_python in to sys.path, but python still cannot find it. What should I do?