CompareGoldenTemplate_Intensity


Compares an image with a template image considered to have no defects.

Applications:Finding general object defects by analyzing brightness deviations from a template image.

Syntax

C++
C#
Python
 
def CompareGoldenTemplate_Intensity(
	inImage: Image,
	inGoldenTemplate: GrayGoldenTemplate,
	outDefects: Region,
	outDifferenceRegion: Region,
	outEdgeRegion: Region,
	/,
	*,
	inGoldenTemplateAlignment: CoordinateSystem2D | None = None,
	inMaxDifference: float = 20.0,
	inMinDefectRadius: int = 1,
	outObjectPosition: Rectangle2D | None = None
)
-> outDefectsPresent: bool

Parameters

Name Type Range Default Description
Input value inImage Image Input image
Input value inGoldenTemplate GrayGoldenTemplate Golden gray template containing image of an object with no defects
Input value inGoldenTemplateAlignment CoordinateSystem2D | None None Adjusts the golden template to the position of the inspected object
Input value inMaxDifference float 0.0 - 20.0 Maximal allowed difference between corresponding pixels of the input and golden images
Input value inMinDefectRadius int 0 - 1 Minimal radius of a defect
Output value outDefects Region Region of detected defects
Output value outDifferenceRegion Region Region of pixels differing too much between the golden image and the input image
Output value outDefectsPresent bool Flag indicating whether any defects were detected
Output value outEdgeRegion Region Region of pixels that will not be compared
Output value outObjectPosition Rectangle2D | None None Position of the object being compared