# Perturbation Tool Parameters

The Perturbation parameters allow the ViDi tools to artificially generate images to be trained on, improving results for applications with high amounts of variance. These parameters are common across all of the tools.

The Perturbation parameters can also be combined. This allows for the generation of more complex images by using the parameters separately, as well as in conjunction.

Tip: If your Training Set does not include all the variations your part may exhibit during runtime, you can use the Perturbation parameters. For example, if your part will rotate by +/-45 degrees, you can set the Rotation parameter, and the software will rotate the images during training by that amount. However, to get the best results, Cognex recommends using actual sample images of the part variations. When a part spins, there may be different shadows, and those will not be captured by the tool when the rotation is based on artificially spinning the image.

Parameter | Description
--- | ---
Rotation | Specifies the possible orientations, defining a piece-wise uniform distribution from which a perturbing rotation angle is drawn (if set to [0°, 0°], no rotational perturbation will be used). For example, with the following settings, [-10°, 10°] or [170°, 190°], the part can be detected between -10 and 10 degrees, or between 170 and 190 degrees. These types of settings are particularly useful if your part can be orientated with a regular orientation, or upside down with a small variation in its angle, but never in between.
Scale | Specifies the normal distribution around 1 from which a perturbing scaling factor is drawn (if set to 0%, it will not be applied). For example, a Scale setting of 100%, providing images of half the original size to double the original.
Original = | Possible Perturbations = |  |  |
Aspect-Ratio | Specifies the normal distribution around 1 from which a perturbing aspect-ratio factor is drawn (if set to 0%, it will not be applied).
Shear | Specifies the normal distribution around 1 from which a perturbing shearing factor is drawn (if set to 0%, it will not be applied).
Flip | Specifies whether to randomly flip the image during sampling in the horizontal, vertical or both directions. This is useful if the object or surface exhibits the corresponding symmetries. This setting can help to highly increase the quantity of training data.
Horizontal |
Vertical |
Both |
Luminance | Specifies the normal distribution around 1 from which a perturbing luminance factor is drawn (if set to 0%, it will not be applied).
Contrast | Specifies the normal distribution around 1 from which a perturbing contrast factor is drawn (if set to 0%, it will not be applied).
Invert Contrast | Specifies whether or not to randomly invert the contrast in order to simulate contrast reversal in the training samples.