9/18/2015

Develop a GUI tool to label and annotate image

labelImg Introduction

  In the past few month, I started to do a project about objection detection. There is a great website, called Image-Net, that I can download images from it to do objection recognition. However, Image-Net provide the users with a few images with bounding box(annotation file). Therefore, I tried to spend a few days to develop a GUI tools that can annotate the image in PascalVOC and Image-Net annotation format. The bellow screenshot is my GUI tool developed by pyQT and forking from labelMe.


A tutorial demonstrates how to use it. There are some hotkeys that can annotate and save the image faster.
Hotkeys:
' Ctrl+ N ' :  Create a bounding box
' n ' : Change to the next image
'Ctrl + S' : Save the annotated file

Other ImageNet Utils
  I also created some tools that can easily download the image, crop the image with bounding box, and convert the image's path and label to text file, etc. Please feel tree to knock yourself out. 

For example, one of the tools 

It will create train.txt containing 3,000 paths and label 1 for training and test.txt contain 1,000 paths and label 1 for testing, and label 1 is chair.
./labelcreator.py --size_of_train 3000 --size_of_test 1000 --label 1 --dir ./chair

The result format is as bellow:

Conclusion


  Hope these tools can help the people who are doing vision algorithms or research.

If the tool helps you, please give me a star in Github.

Source code: