Table Of Contents

Detect Shapes (Detect Rectangles) (G Dataflow)

Last Modified: October 26, 2017

Searches for rectangles in an image.

connector_pane_image
datatype_icon

ROI descriptor

Rectangle or rotated rectangle within which to detect shapes.

datatype_icon

Global Rectangle

Coordinates of the bounding rectangle.

datatype_icon

Contours

Individual shapes that define an ROI.

datatype_icon

ID

Object specifying if contour is the external or internal edge of an ROI.

datatype_icon

Type

Shape type of the contour.

datatype_icon

Coordinates

Relative position of the contour.

datatype_icon

image in

Reference to the searched image.

datatype_icon

rectangle size ranges

Sizes of rectangles to detect.

Width is defined as the length of the shorter side of a rectangle and height is defined as the longer side of the rectangle you want to search for.

datatype_icon

Min Width

Minimum width describing the rectangles to detect.

datatype_icon

Max Width

Maximum width describing the rectangles to detect.

datatype_icon

Min Height

Minimum height describing the rectangles to detect.

datatype_icon

Max Height

Maximum height describing the rectangles to detect.

datatype_icon

curve extraction options

Information about how curves are extracted from the inspection image during the match phase.

datatype_icon

Extraction Mode

Input that specifies how the node identifies curves in the image.

Name Value Description
Normal 0

(Default) Select if you want the node to make no assumptions about the uniformity of objects in the image or the image background.

Uniform Regions 1

Select if you want the node to assume that either the objects in the image or the image background consist of uniform pixel values. This allows the node to more accurately calculate the external curves of the objects.

datatype_icon

Edge Threshold

Minimum contrast a seed point must have for it to begin a curve.

Valid values range from 1 to 255.

Default: 75

datatype_icon

Edge Filter Size

Width of the edge filter that the node uses to identify curves in the image.

Name Value Description
Fine 0

Sets to fine edge filter size.

Normal 1

(Default) Sets to normal edge filter size.

Contour Tracing 2

Sets to contour tracing edge filter size, which provides the best results for contour extraction but increases the time required to process the image.

datatype_icon

Min Length

Length, in pixels, of the smallest curve that you want the node to identify.

The node ignores any curves that have a length less than this value.

Default: 25

datatype_icon

Row Search Step Size

Distance, in the y direction, between the image rows that the algorithm inspects for curve seed points.

Valid values range from 1 to 255.

Default: 15

datatype_icon

Col Search Step Size

Distance, in the x direction, between the image columns that the algorithm inspects for curve seed points.

Valid values range from 1 to 255.

Default: 15

datatype_icon

Max Endpoint Gap

Maximum gap, in pixels, between the endpoints of a curve that the node identifies as a closed curve.

If the gap is larger than this value, the node identifies the curve as an open curve.

Default: 10

datatype_icon

Closed

Boolean value that specifies only closed curves are identified in the image.

TRUE Identifies only closed curves.
FALSE Identifies both open and closed curves.

Default: FALSE

datatype_icon

Subpixel

Boolean value that specifies if curve points are detected with subpixel accuracy.

TRUE Curve points are detected with subpixel accuracy.
FALSE Curve points are not detected with subpixel accuracy.

Default: FALSE

datatype_icon

match options

Match options used when detecting shapes.

datatype_icon

Rotation

Boolean input specifyomg whether or not to search for rotated versions of the shape.

datatype_icon

Scale

Boolean that specifies whether or not to search for scaled versions of the shape.

datatype_icon

occlusion

Boolean that specifies whether or not to search for occluded versions of the shape.

datatype_icon

Range Settings

Array that specifies the allowable ranges for rotation and scale.

datatype_icon

Match Constraints

Match option whose values you want to constrain by the given range.

Name Value Description
Rotation Angle (degrees) 0

Set a range for this option to specify the angles at which you expect the node to find template matches in the inspection image. The node ignores this range if the Rotation is not enabled.

Scale Factor (%) 1

Set a range for this option to specify the sizes at which you expect the node to find template matches in the inspection image. The size is expressed as the following percentage: the size of the match divided by size of the template image, multiplied by 100. The node ignores this range if the Scale is not enabled.

Occlusion (%) 2

Set a range for this option to specify the amount of occlusion you expect for a match in the inspection image. Matches that have up to 50% occlusion are accurately detected. The node ignores this range if the Occlusion is not enabled.

datatype_icon

Min

Minimum value of the range for a given match constraint.

datatype_icon

Max

Maximum value of the range for a given match constraint.

datatype_icon

error in

Error conditions that occur before this node runs.

The node responds to this input according to standard error behavior.

Standard Error Behavior

Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

error in does not contain an error error in contains an error
If no error occurred before the node runs, the node begins execution normally.

If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.

Default: No error

datatype_icon

minimum match score

Minimum score a returned shape can have.

datatype_icon

image out

Reference to the image input.

datatype_icon

rectangles

Array of rectangle clusters that describe each found rectangle.

Width is defined as the length of the shorter side of a rectangle and height is defined as the longer side of the rectangle you want to search for.

datatype_icon

Corners

Array of coordinates that specify the corners of the rectangle.

datatype_icon

Angle

Orientation of the rectangle.

datatype_icon

Width

Width of the rectangle.

datatype_icon

Height

Height of the rectangle.

datatype_icon

Score

Score of the rectangle.

datatype_icon

number of rectangles

Number of matches found.

datatype_icon

error out

Error information.

The node produces this output according to standard error behavior.

Standard Error Behavior

Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

error in does not contain an error error in contains an error
If no error occurred before the node runs, the node begins execution normally.

If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.

Where This Node Can Run:

Desktop OS: Windows

FPGA: Not supported

Web Server: Not supported in VIs that run in a web application


Recently Viewed Topics