Error importing string_int_label_map_pb2
When I run the object_detection_tutorial.ipynb i get the following error ImportError Traceback (most recent call last) in () ----> 1 from utils import label_map_util 2 3 from utils import visualization_utils as vis_util D:\Personal\learn\ML\DL\Tensorflow\Official-Tutorial\models-master\object_detection\utils\label_map_util.py in () 20 import tensorflow as tf 21 from google.protobuf import text_format ---> 22 from object_detection.protos import string_int_label_map_pb2 23 24 ImportError: cannot import name 'string_int_label_map_pb2'
I did run the following command : "C:\Program Files\protoc\bin\protoc" object_detection/protos/*.proto --python_out=.
but still error in importing string_int_label_map_pb2
I apologize but I am having a hard time understanding what the problem is, where the problem is, and what version it affects. Please resubmit and pay attention to the issue template (https://github.com/tensorflow/models/issues/new) . Please provide all the information it asks. Thank you.
you can check your 'object/detection/protos' directory, checking if there is 'string_int_label_map_pb2.py'.The file was generated by command
protoc object_detection/protos/*.proto --python_out=.
you can check your 'object/detection/protos' directory, checking if there is 'string_int_label_map_pb2.py'.The file was generated by command
protoc object_detection/protos/*.proto --python_out=.
Exactly what I was looking for. Thanks!
I get the same issue: ImportError: cannot import name 'string_int_label_map_pb2'
However when checking the directory the file 'string_int_label_map_pb2' and others are present. (I ran the command as above)
Was following this tutorial, using Anaconda, Spyder https://pythonprogramming.net/introduction-use-tensorflow-object-detection-api-tutorial/
@Coenbal did you solve the problem? I have the same issue. The scripts are present in the protos folder but the problem persists.
I face the same issues and I'm using a macbook.
I am facing this issue "cannot import name 'string_int_label_map_pb2' " . I am struck here not knowing what to do. Please anyone help me in solving this issue.
I have gone through above discussion , but couldn't understand what it explains as I am new . This didn't statement "protoc object_detection/protos/*.proto --python_out=." , is what I am unable to understand. How to Run it in Win-10 to solve the issue.And what does it do...? Please help me in learning..! I use Win-10
@harish-git08 Follow the Step 2f. Compile Protobufs and run setup.py of this github: https://github.com/EdjeElectronics/TensorFlow-Object-Detection-API-Tutorial-Train-Multiple-Objects-Windows-10
and finally run python setup.py build and python setup.py install from object_detection/research
When I applied @shartoo 's solution it worked but I had to do that command from "/research" path.
Tq so much
On Fri, Jan 25, 2019, 3:21 AM Heedoo Moon <[email protected] wrote:
When I applied @shartoo https://github.com/shartoo 's solution and worked but I had to do that command from "/research" path.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tensorflow/models/issues/2322#issuecomment-457370949, or mute the thread https://github.com/notifications/unsubscribe-auth/Aqoah0v0I9jFXThqe6ULbjHMwnR1NN5Xks5vGir7gaJpZM4PJ4Bp .
i am facing this issue in pycharm please help!
from object_detection.protos import string_int_label_map_pb2
ImportError: cannot import name 'string_int_label_map_pb2'
THIS IS THE ERROR
@PreethmKumar As shown above, 2322#issuecomment-446956766, and You should install protoc first. Then run this command in your bash or cmd :
protoc object_detection/protos/string_int_label_map.proto --python_out=.
Closing this issue since it's resolved. Feel free to reopen if the issue still persists. Thanks!
Simply, go to protos dirctory in object detection folder in your pc and put this python file into the it: https://github.com/datitran/object_detector_app/blob/master/object_detection/protos/string_int_label_map_pb2.py