Image Labeler

user guide

author: Gapchich Vladislav

2011


1. Introduction

Image labeler is a tool that allows you to mark objects on the image and label them accordingly.

For example, lets take this picture:


Pic. 1.1

There are five objects on it: two markers, two pens, a toy and a hat. Let's suppose that pen, toy and a hat are certain classes of objects and their numbers are: hat – 1, pen – 2, toy – 3. So now we can select all objects in the image and label them accordingly.

We'll have something like this:


Pic. 1.2

After the labeling procedure is finished all the information about selected regions can be saved into xml file or an application can generate a segmented image only with selected regions.


Pic. 1.3

Now you've seen the main features of this application. Let's take a look at the program in more detail.


2. Getting started

After the first launch of ImageLabeler application you'll see this window:


Pic. 2.1


Everything is empty because no image has been loaded yet. There are a lot of ways to open images.

3. Loading images and data

Click on menu File and you'll see these options: “load image”, “load images”, “load labeled image”, “load legend” and “Pascal” menu.



Pic. 3.1

An application with loaded image looks this:


Pic 3.2

As you can see all the tools are enabled now and you can use them.


4. Labeling


First you should add some labels. To do it you have to click on “Add label” button in the top right corner of the window.

Pic. 4.1

As the result a new label with the name “New label” will appear. The number of labels can not be more than 100. To change the name of a label just make a double click on it and edit the text of an item. To remove the label you can use “Remove label” button or open a popup menu by right click on an item and select “Delete” action. To change label's color or make it the “main” label use popup menu as well.


5. Selecting objects

Now when the labels are created and their colors are set we can begin with the selecting objects on the image.


Pic. 5.1

There are two tools you can use to select an object on the image:

First – bounding box. To add a bounding box just select it from the toolbox in the upper left corner and start selecting the bounds of an objects with left mouse button pressed. Move mouse from one corner of the rectangle to another to capture the whole object in it. If you're not satisfied with the result you can start a new rectangle by clicking left mouse button again and the old one will be automatically erased.

Second – polygon tool. To start selecting object with this tool you need to follow the object contour with the “pointing and clicking”. Just click with the left mouse button in the key points of the contour and program will draw a polygon which follow the points you've created. You can press and hold left mouse button to see the last line of the polygon and select more accurately.


If you've decided no to make any selection just click “Esc” button on your keyboard.


Before you decide to confirm the object you selected you should choose one of the labels you created before. To confirm the selection click “Confirm selection” button in the lower left corner of the window or just press “enter” button on the keyboard.


To zoom in or zoom out an image use ctrl + mouse wheel.



6. Editing selected areas


To edit already selected area find it in the “Selected areas” list and double click on it.



Pic. 6.1

One of the contours will become dashed and all it's points will become visible and selectable. To edit a contour grab any point you want with the mouse pointer and move it until you get the satisfying result. Also you can edit Label ID of the selected area and it's point by changing text of an item manually. To do it call a popup menu of the “Selected areas” list and choose “Change area” action. You can delete area using the same popup menu but selecting “Delete area”

7. Saving information about objects


Pic. 7.1.

To save the whole information(labels, objects, image description, tags, segmented image as 2d array of label id's) use “Save all info” action in the “File” menu. This file will have xml format and “*.dat” extension. By default it's name would be “imagename_labeled.dat” where “imagename” part is the name of an original file. If you'll store this “*.dat” file in the same directory as the original image then you'll be able to load it using “load image” menu action. Storing data with this the default name in the directory of an original image is highly recommended.

To get segmented image like Pic. 1.3 simply choose “Save segmented picture” action from the “File” menu. It is also recommended to use default name and path for the segmented image. To look at the results of segmentation go to the “View” menu and select “Segmented” action

To save the legend(labels, ids and colors) choose “Save legend” action from the “File” menu.