Skip to content

3D Flatness

Operator Function

Using the average point method, calculate an average point in each region, and use these average points to fit a reference plane. Calculate the peak-to-reference flatness deviation and reference-to-valley flatness deviation. The final flatness = peak-to-reference flatness deviation - reference-to-valley flatness deviation.

Reference: ISO 12781-1:2011(en) Geometrical product specifications (GPS) — Flatness — Part 1: Vocabulary and parameters of flatness

Parameter Introduction

Input Parameters

ParameterRangeDefault ValueDescriptionIllustration
Input Image0-80IM number for image input

Calculation Parameters

ParameterRangeDefault ValueDescriptionImage
Region Point SelectionAll Points/Average PointAll PointsSee Region Point SelectionRegion Point Selection
Number of Regions1Set the number of detection regions. For Average Point mode, at least 4 ROI regions must be set and the regions cannot be collinear.
Filter MethodNone/Percentile FilterNoneNone: Do not use any filtering method
Percentile Filter: Use percentile filtering method to filter points in each region and remove outliers. See Percentile Filter

Region Point Selection

Currently, two point selection methods are provided: All Points and Average Point modes.

ParameterRangeDefault ValueDescriptionImage
All PointsIn this mode, all points in the ROI participate in flatness calculation.
Average PointIn this mode, the average point of all points in each region is calculated, and then the average point is included in the calculation.

Note: The average point flatness calculation method, on one hand, preserves the statistical information of all points in the region, to some extent suppressing the influence of noise points, making the calculation results more stable; on the other hand, since only average points are used for calculation, it is also faster. However, if using the Average Point mode, at least 4 ROI regions must be set and the regions cannot be collinear.

Percentile Filter Mode

If enabled, percentile filtering will be performed on points in each region.

ParameterRangeDefault ValueDescriptionImage
Low PercentageCalculate the low threshold in the Z direction based on the input percentage, removing all points below this threshold
High PercentageCalculate the high threshold in the Z direction based on the input percentage, removing all points above this threshold

Result Display

ParameterRangeDefault ValueDescriptionIllustration
Heighttrue/falsefalseRegion height value. If enabled, display in the image
Height Measurement Pointstrue/falsefalseHeight position points. If enabled, display in the image
ROI Point Settrue/falsefalseRegion point set selected by ROI box. If enabled, display in the image

Output Parameters

NameTypeRangeDescription
Resultbooltrue/falsetrue for success
false for failure
Warningbooltrue/falsetrue indicates a warning
false indicates no warning
MessagestringOutput success, error, or warning messages
TimefloatOperator execution time, unit: ms
region_heightfloat[]Region height array
flatness_valuefloatFlatness value

Exception Troubleshooting

No.Exception InformationCorresponding ParameterSolution
1High and low percentages cannot both be 50.0Adjust high and low percentages, cannot both be 50
2Input value is {0}, invalid height statistics methodHeight ModeOnly Minimum, Maximum, Mean, Median supported
3Global flatness test failed1. Check if input point cloud is empty
2. Check if high and low percentages are both greater than 0 and less than 50
4At least 4 regions need to be set in this modeSelect at least 4 different regions, and the center points of the regions should not be on a straight line
6Input value is {0}, invalid region point selection methodRegion Point SelectionOnly All Points, Single Average Point supported

Example Introduction

Engineering Design

  1. Select the 3D Load Point Cloud tool.
  2. Select 2 Call Program tools to perform position adjustment and plane fitting respectively.
  3. Select 2 3D Flatness tools, using Average Point mode and All Points mode respectively.

Tool Usage

  1. Select the IM number of the input image.

  2. Set the parameters.

  3. Click Test to check if the image window and parameters meet expectations.

  4. If there are no issues, click Save. Run the operator in the run list, and then view the running results in the corresponding IM.

Local Image

AI-Vision, Making 3D Measurement Easier