Back to Aurora Vision Studio website

You are here: Start » Filter Reference » Computer Vision » Image Analysis » MeasureObjectWidth

MeasureObjectWidth


Module: FoundationPro

Measures the width of an object using stripe detection.

Name Type Range Description
Input value inImage Image Input image
Input value inScanField SegmentScanField Field in which measurement scans are performed
Input value inScanFieldAlignment CoordinateSystem2D* Adjusts the scan field to the position of the inspected object
Input value inScanCount Integer 2 - Number of scans to be performed
Input value inScanWidth Integer 1 - Width of each single scan
Input value inImageInterpolation InterpolationMethod Interpolation method used in extraction of image pixel values
Input value inStripeScanParams StripeScanParams Parameters controlling the object stripe extraction process
Input value inMeasureMethod MeasureObjectMethod Method used to measure the object
Input value inStripeSelection Selection Selection mode of edges of the object
Input value inLocalBlindness LocalBlindness* Defines conditions in which weaker edges can be detected in the vicinity of stronger edges
Input value inOutlierSuppression MEstimator* Selects a method for ignoring incorrectly detected points
Input value inOutlierCount Integer 0 - Determines how many points are not count when object width is measured
Output value outObjectWidth Real? Width of the object
Output value outSegment1 Segment2D? First edge of the object
Output value outSegment2 Segment2D? Second edge of the object
Output value outAlignedScanField SegmentScanField Field in which the scans are performed
Output value outStripes Stripe1D?Array Detected stripes
Output value outBrightnessProfiles ProfileArray Extracted image profiles
Output value outResponseProfiles ProfileArray Profiles of the edge (derivative) operator
Diagnostic input diagScanSegments Segment2DArray Segments along which the scans are performed

Description

The filter measures the width of an object present in an image. Internally, it performs a series of scans with ScanSingleStripe filter along inScanCount parallel scan segments constructed from inScanField. The so obtained points are then used for computing two parallel segments by means of a slightly modified segment fitting routine. The process is supported by inOutlierSuppression parameter. Finally, having the aforementioned stripe widths and fitted segments' direction, the object width can be computed using a selected inMeasureMethod method. The inOutlierCount stripe widths most differing from the median width are not used in this step. For the filter to work properly, the scan segments do not have to be necessarily perpendicular to the object edges.

Hints

  • Connect the inImage input with an appropriate image source. Make sure that this image is available (the program was previously run).
  • If the object location is variable, connect an appropriate local coordinate system to inScanFieldAlignment.
  • Define inScanField by marking a directed rectangle within which the measurement will be done.
  • Define inStripeScanParams.StripePolarity to detect a particular edge type, and only that type.
  • If the noise level is high, try increasing inScanWidth and/or inStripeScanParams.SmoothingStdDev.
  • If some points are not found, try decreasing inStripeScanParams.MinMagnitude.
  • If the object is more narrow than 6 pixels, change inStripeScanParams.ProfileInterpolation to Quadratic3.
  • Experiment with inOutlierSuppression and inOutlierCount to deal with some amount of incorrectly detected points.
  • Increase inScanCount to improve accuracy.
  • Experiment with various values for inMeasureMethod to obtain best possible precision.

Examples

Description of usage of this filter can be found in examples and tutorial: L-pipe measurements, Plate Measurement, Plate Measurement (Advanced), Measure Objects .

MeasureObjectWidth performed on the sample image. Green segments are diagScanSegments, the other two are found object edges.

Complexity Level

This filter is available on Basic Complexity Level.

See Also

  • ScanSingleStripe – Locates the strongest pair of edges across a given path (without a scan map).
  • FitSegmentToEdges – Performs a series of 1D edge detections and finds a segment that best matches the detected points.