# Use Image Sample Sets as Training and Testing Sets

Once image sample sets are configured, they can be used to both train and test ViDi tools, allowing you to validate the tools performance prior to deployment.

Tip:

The process of creating an image sample set for training and validation is best done iteratively. At the beginning of the application development process, you will probably want to select approximately half of the images in your image database for your training image sample set (in the Training Set dialog, the Count parameter will be set to 50%). As your database grows and increases in completeness, you will have more subsets of images (e.g. morning shift, afternoon shift, evening shift; line 1, line 2; plant 1, plant 2, etc.), and either additions to existing image sample sets, or additional image sample sets.

When you are ready to assess the generalization status of your tools, you can switch the Training Set Count parameter to 100% and train your desired training image sample set. Then you can run your testing sample image sets against the trained tools, to see how they perform against these other sets.

1. From your database of collected images, create a training image sample set.
2. Create a separate set as a testing image sample set.
3. Label all of the images/views in the training and testing image sample sets.
4. In the Training Set dialog, select the training image sample set and train the tool.
5. In the Database Overview, double-click the testing image sample set to load it into the View Browser.
6. From the Actions for N Views menu, select Clear Markings.
7. Process the images.

8. The statistics for the testing image set will then be displayed in the Database Overview.

   Note: Alternatively, you can also use the Filter in the Database Overview to load and process image sample sets.