# Neural Network Training

Neural network training Training is the process that your tool, which is a neural network, is learning about the features (pixels) based on the labels you made. For example, a tool will learn the defect/normal pixels in each image based on the defect/normal labels you drew. The goal of the tool Training is learning enough to give the correct inspection results of whether an unseen image is defective or not. The key to training is to ensure that you include all possible variations within your training set, and that your images are accurately labeled. Training times vary by the application, tool setup and the GPU in the PC being used to train the network. is a step in the training phase. In this step, the tool, which is a deep neural network, learns from the labels you provide. For example, the Red Analyze tool learns to identify defective and normal pixels based on the labels you draw on the images.

Symbol | Definition
1 | The sampling region.
2 | The user-drawn, labeled defect region.
3 | The neural network.
4 | The response of the neural network
5 | The iterative process of adjusting the weights to reduce the differences between the labeled defect (in yellow) and the response (in blue).

Neural network training has the following general steps:

1. The VisionPro Deep Learning application samples each image in the training image set A collection of images of your specific application. A training image set represents images of a specific part or process acquired in a consistent way using the lighting, optical, and mechanical characteristics of your runtime system. The training image set includes images that represent the range of image appearances that you expect to see in normal operation..

   - The Blue Locate, Blue Read, and Legacy type tools use the specified Feature Size for sampling.

   - The Standard type Red Analyze tool uses the specified Patch Size for sampling.

   - The Standard type Green Classify tool samples the whole image.

2. The application passes the resulting samples into the neural network.

3. For each sample, the neural network produces a specific response, depending on the tool type.

4. The application compares the response from the tool with the image labeling Labeling is the process of annotating an image with "ground truth". Depending on the tool that you are using, labeling can take different forms. You label an image set for two reasons: to provide the information needed to train the tool and to allow you to measure and validate the performance of the trained tool against the ground truth. associated with the sample’s location in the training image.

5. The application repeatedly adjusts the internal weights within the tool as the samples are processed and reprocessed. The purpose of this step is to reduce the differences between the responses of the tool and the labeling.

6. The application repeats the entire process many times.

Note: The specific characteristics of the neural network training vary depending on the type of the tool.