问题
I was trying to run tensorflow model and I was using Python 3.6 with PyCharm (pip). I got this error:
Use the retry module or similar alternatives.
Traceback (most recent call last):
File "/Users/erdogan/Desktop/tens/model/research/object_detection/builders/model_builder_test.py", line 21, in <module>
from object_detection.builders import model_builder
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/object_detection-0.1-py3.6.egg/object_detection/builders/model_builder.py", line 30, in <module>
from object_detection.models import faster_rcnn_inception_resnet_v2_feature_extractor as frcnn_inc_res
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/object_detection-0.1-py3.6.egg/object_detection/models/faster_rcnn_inception_resnet_v2_feature_extractor.py", line 28, in <module>
from nets import inception_resnet_v2
ModuleNotFoundError: No module named 'nets'
I have used this:
Vural-MacBook-Pro:research erdogan$ export PYTHONPATH=/Users/erdogan/Desktop/tens/model/research/slim:$PYTHONPAT
But it did not work. I have also checked my path:
Vural-MacBook-Pro:research erdogan$ echo $PYTHONPATH
I got this:
/Users/erdogan/Desktop/tens/model/research/slim:
回答1:
Try to copy the nets folder from slim to the installation directory. Ref
来源:https://stackoverflow.com/questions/49724650/i-got-this-error-modulenotfounderror-no-module-named-nets-tensorflow