Table Of Contents

Setup Match Color Pattern (G Dataflow)

Last Modified: June 25, 2019

Sets parameters that are used during the color matching process.

Run this node before using the Match Color Pattern node.

connector_pane_image
datatype_icon

color score weight

Input, between 0 and 1000, that determines the percent contribution of the color score to the final color pattern matching score.

The application uses the color score weight for the final match ranking. For example, if the weight is 1000, the algorithm finds each match by using both color and shape information and then ranks the matches based on their color scores. If the weight is 0, the matches are ranked based on their shape scores. The default is 500, indicating that the match score uses an equal combination of the color and shape scores.

Default: 500

datatype_icon

minimum contrast

Minimum expected difference between the maximum luminance value and the minimum luminance value of the color pixels in the inspection image.

Default: 0

datatype_icon

match mode

Invariance mode to use when looking for the color template pattern in the inspection image.

Name Value Description
Shift Invariant 0

(Default) Searches for the color template pattern in the image, assuming it is not rotated more than 4 degrees.

Rotation Invariant 1

Searches for the color template pattern in the image with no restriction on the rotation of the template.

datatype_icon

match feature mode

Features used when looking for the color template pattern in the color image.

Name Value Description
Color and Shape 0

(Default) Searches for the color template pattern using color and shape features.

Color 1

Searches for the color template pattern using color features.

Shape 2

Searches for the color template pattern using shape features.

datatype_icon

subpixel accuracy?

Boolean value that specifies whether to return the match results with subpixel accuracy.

TRUE Returns match results with subpixel accuracy.
FALSE Does not return match results with subpixel accuracy.

If match feature mode is set to Color, the node ignores this setting.

Default: FALSE

datatype_icon

rotation angle ranges

Array of angle ranges, where each range specifies how much you expect the color template to rotate in the inspection image.

Specify a lower and upper angle, in degrees, for each range.

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

color sensitivity

Sensitivity of the color information in the image.

Set to High Sensitivity to distinguish colors with close hue values.

Default: Low

datatype_icon

search strategy

Input that specifies how the color features of the image are used during the search phase.

Name Value Description
Conservative 0

Uses a very small step size, the least amount of subsampling, and all the color information present in the template. The conservative strategy is the most reliable method to look for a template in any image at potentially reduced speed.

Balance 1

Uses values in between the aggressive and conservative strategies.

Aggressive 2

Uses a large step size, a lot of subsampling, and all the color spectrum information from the template.

Very Aggressive 3

Uses the largest step size, the most subsampling, and only the dominant color from the template to search for the template. Use this strategy when the color in the template is almost uniform, the template is well contrasted from the background and there is a good amount of separation between different occurrences of the template in the image. This strategy is the fastest way to find templates in an image.

datatype_icon

match color pattern setup data

String that contains information about the setup parameters selected for the matching phase.

Connect this output to the Match Color Pattern node.

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