# ViDi ELClassify Tool

With the Classify tool, you can quickly train a deep learning model which accurately predicts the classification of an image.

The Classify tool allows you to specify a region of interest (ROI), either from the entire image or a fixture area of the image, and train the tool by labeling an initial training set of images. Once you have trained the Classify tool, it is able to output a class for this region on other images by comparing with the training set. The Classify tool utilizes deep learning technology to distinguish the characteristics and differences of the selected image part, giving you real time feedback on your training progress and the accuracy of class predictions.

To use the Classify tool:

1. Select the Classify tool under the ViDi EL Tools group in the Inspect application step.

2. Position the Classify Region box on the segment of the image you want to classify. To position the Classify Region box, click and drag the box to the area of the image you want to classify. To resize the Classify Region box, click and drag the corners of the box. To rotate the Classify Region box, click and drag the rotate button on the box.

3. Click OK in the right corner under the Directions box.

   Note: Once you click OK, you can no longer resize the region of interest (ROI).

4. After you click OK, the Classify tool appears in the list of configured tools, and the Classify tool property edit panel opens.

5. To train the first image, click on the class label you want to classify it as. The default class labels are NG and OK. This adds the Classify Region segment of the image to the labeled image database, and the tool starts predicting the class for any new images presented to the tool (either by triggering the camera or cycling through the record/ playback filmstrip). Notice that the number of labeled images to the right of the class label field increases by 1 when the image is added to the tool database.

6. To edit a class label, click Edit on the right side of the class label field and fill in the label you want in the field. Press enter to rename the class label. To add a new class, click on Add New Class.

7. As you label more images, the tool starts to predict results from the unlabeled images that are currently processed and presented in the image window. The predicted class is represented by a yellow circle next to each class, and a confidence score for each image, as represented by the green semi circle.

8. Once you have some images labeled, click Edit Classes to check if each image label is correct. You can also add more unlabeled images to the tool database in the Edit Classes panel.

Note: Model Health is a measure of the accuracy of the model when validated against the set of labeled images in the tool. Model health tends to increase as you add more representative images to each class. If individual classes contain a large degree of variability from one image to another, the model health can remain low, even while the tool predicts accurate results. Therefore, you cannot use Model Health as a hard reference for tool validation.
Note: Confidence Score is a score between 0-100 (100 being the most confident). The score denotes the confidence that the prediction of the Classify tool is correct and the Classify tool labels a particular image accurately.

You can also enable advanced tool settings if your job requires more complex configuration. For more information on the advanced tool settings that are available, see Advanced Tool Settings.