Faster-RCNN_TF icon indicating copy to clipboard operation
Faster-RCNN_TF copied to clipboard

setup.py issue

Open Griovwe opened this issue 7 years ago • 3 comments

I just start learning python, I have a problem for the setup.py . When I type the command "make", there is an error as below:

python setup.py build_ext --inplace File "setup.py", line 84 print extra_postargs ^ SyntaxError: Missing parentheses in call to 'print' Makefile:2: recipe for target 'all' failed

It seems that parentheses needed, I add them as print ("extra_postargs"), and then implement the command "make", there is another error as below:

python setup.py build_ext --inplace Traceback (most recent call last): File "setup.py", line 55, in CUDA = locate_cuda() File "setup.py", line 49, in locate_cuda for k, v in cudaconfig.iteritems(): AttributeError: 'dict' object has no attribute 'iteritems' Makefile:2: recipe for target 'all' failed make: *** [all] Error 1

It says "cudaconfig" dictionary does not have "iteritems". I check in the code, there is no definition of "iteritems" in the "cudaconfig". I install Anaconda with python 3.6, I don't know if this is a problem caused by version, or if I should change some code.

Griovwe avatar Mar 27 '17 22:03 Griovwe

It's because you are using python 3, in python 3 you have to print() whereas in python 2 you could just print. You should try it again with python 2 or perhaps try a tool like 2to3.

LHagendoorn avatar Mar 29 '17 09:03 LHagendoorn

I had the same problem, installing python 2.7 instead of 3 all works fine

AlbertoBenini avatar Mar 29 '17 09:03 AlbertoBenini

I had the same problem with python3. Changing the 'iteritems' into 'items' would work

hanaluana avatar Oct 12 '18 17:10 hanaluana