Are you tired to label your images by hand to work with object detection? Have hundreds or thousands of images to label? Then this project will make your life easier, just create some annotations and let the machine do the rest for you!
- You will need to clone the TensorFlow repository
- Install the dependencies for object detection
- Copy and paste the files generate_xml.py and visualization_utils.py into the research/object_detection/utils in the tensorflow repo.
- Change the xml path in generate_xml.py to put your own local path.
- Add the images you want to label into the images folder
- Add your pre-treined model (as a fronzen inference graph) and label map into the 'graphs' folder.
- Inside the auto_annotate folder run: python3 scripts/detection_images.py
- If you have TF 2.x, just run the following command:
python3 scripts/detection_img_tf2.py --saved_model /path-saved-model --labelmap /path-label-map.pbtxt --imgs /path-of-the-imgs
- If it runs correctly, you will see the inference results and the xml in your respective folders!
If you have trouble or doubt check my tutorial on medium. You can also open an issue and I'll hep you!