Back to Adaptive Vision Library website

You are here: Start » Function Reference » Computer Vision » Template Matching » CreateEdgeModel2

CreateEdgeModel2


Header: AVL.h
Namespace: avl
Module: MatchingPro

Creates a model for edge-based template matching.

Applications: Dynamic creation of models in the runtime environment (normally they are created interactively in Studio).

Syntax

C++
C#
 
void avl::CreateEdgeModel2
(
	const avl::Image& inImage,
	atl::Optional<const avl::Region&> inTemplateRegion,
	atl::Optional<const avl::Rectangle2D&> inReferenceFrame,
	int inMinPyramidLevel,
	atl::Optional<int> inMaxPyramidLevel,
	float inSmoothingStdDev,
	float inEdgeThreshold,
	float inEdgeHysteresis,
	float inMinAngle,
	float inMaxAngle,
	float inAnglePrecision,
	float inMinScale,
	float inMaxScale,
	float inScalePrecision,
	float inEdgeCompleteness,
	atl::Conditional<avl::EdgeModel2>& outEdgeModel,
	atl::Optional<atl::Conditional<avl::Point2D>&> outEdgeModelPoint = atl::NIL,
	atl::Optional<atl::Conditional<atl::Array<avl::Path>>&> outEdges = atl::NIL,
	atl::Conditional<atl::Array<avl::Image> >& diagEdgePyramid
)

Parameters

Name Type Range Default Description
Input value
inImage const Image& Image from which model will be extracted
Input value
inTemplateRegion Optional<const Region&> NIL Region of the image from which model will be extracted
Input value
inReferenceFrame Optional<const Rectangle2D&> NIL Exact position of the model object in the image
Input value
inMinPyramidLevel int 0 - 12 1 Defines the number of reduced resolution levels dynamically created during model creation
Input value
inMaxPyramidLevel Optional<int> 0 - 12 NIL Defines the number of reduced resolution levels used to speed up computations
Input value
inSmoothingStdDev float 0.0 - 0.0f Standard deviation of the gaussian smoothing applied before edge extraction
Input value
inEdgeThreshold float 0.0 - 35.0f Higher threshold for edge magnitude
Input value
inEdgeHysteresis float 0.0 - 15.0f Threshold hysteresis value for edge magnitude
Input value
inMinAngle float -180.0f Start of range of possible rotations
Input value
inMaxAngle float 180.0f End of range of possible rotations
Input value
inAnglePrecision float 0.001 - 10.0 1.0f Defines angular resolution of the matching process
Input value
inMinScale float 0.0 - 1.0f Start of range of possible scales
Input value
inMaxScale float 0.0 - 1.0f End of range of possible scales
Input value
inScalePrecision float 0.001 - 10.0 1.0f Defines scale resolution of the matching process
Input value
inEdgeCompleteness float 0.01 - 1.0 1.0f Determines what fraction of the edges will be present in the created model
Output value
outEdgeModel Conditional<EdgeModel2>& Created model that can be used by LocateMultipleObjects_Edges
Output value
outEdgeModelPoint Optional<Conditional<Point2D>&> NIL The middle point of the created model
Output value
outEdges Optional<Conditional<Array<Path>>&> NIL Visualization of the model edges found at the original resolution
Diagnostic input
diagEdgePyramid Conditional<Array<Image> >& Visualization of the edges found at different resolution levels

Optional Outputs

The computation of following outputs can be switched off by passing value atl::NIL to these parameters: outEdgeModelPoint, outEdges.

Read more about Optional Outputs.

Hardware Acceleration

This operation supports automatic parallelization for multicore and multiprocessor systems.