CreateGoldenTemplate2
Create a model to be used with CompareGoldenTemplate2 filter.
Syntax
C++
C#
Python
def CreateGoldenTemplate2( inImages: list[Image], outModel: GoldenTemplate2Model, /, *, inObjectMask: Region | None = None, inDownscale: int = 2, inMaxDisplacement: int = 2, inLargeDefectSize: int = 50, inBrightnessAugmentation: int = 0, inNoiseAugmentation: int = 0, inSmoothingAugmentationStdDev: float = 0.0 ) -> None
Parameters
| Name | Type | Range | Default | Description | |
|---|---|---|---|---|---|
![]() |
inImages | list[Image] | List of input images that has to be uniform in terms of size and format. | ||
![]() |
inObjectMask | Region | None | None | ||
![]() |
inDownscale | int | 1 - ![]() |
2 | Shrink the input for processing by dividing by specified value. Reduces sensitivity to minuscule (pixel-size) defects. Greatly improves processing speed. |
![]() |
inMaxDisplacement | int | 0 - ![]() |
2 | Error in object positioning. If in doubt, it is better to set this value too high. If set too low, subtle defects won't be detected, or no defects may not be detected at all. High values may impair detection of small defects, especially near edges. |
![]() |
inLargeDefectSize | int | 0 - ![]() |
50 | Expected size (diameter) of largest, extensive defects. |
![]() |
inBrightnessAugmentation | int | 0 | Allows for greater (additional to the value inferred from inImages training set) brightness deviation in inspected images. | |
![]() |
inNoiseAugmentation | int | 0 | Allows for greater (additional to the value inferred from inImages training set) noise presence in inspected images. Uses a uniform noise with specified distribution width. | |
![]() |
inSmoothingAugmentationStdDev | float | 0.0 - ![]() |
0.0 | Allows for greater (additional to the value inferred from inImages training set) image smoothing in inspected images. Uses gaussian smoothing with specified standard deviation. |
![]() |
outModel | GoldenTemplate2Model |



