Two-dimensional dimension and contour measurement algorithm services
For part edges, plane contours and two-dimensional point sets, it provides algorithm evaluation and project development for sub-pixel edges, straight line and circle fitting, width, Feret diameter, contour deviation and two-dimensional straightness. The result can be output as a pixel quantity, and then converted into an agreed physical unit after being effectively calibrated.
Applicable objects and measurement tasks
Suitable for 2D vision tasks with stable imaging of contours, measurement positions and definable datums, such as hole axis sections, panel edges, wire widths, stamping profiles, cut part profiles and plane geometry inspection before assembly.
- Position positive and negative edges along specified sample lines and calculate spacing.
- Fits a line, circle, or rotated envelope rectangle to a 2D point set.
- Calculate the maximum and minimum Feret diameter, local section width and direction.
- Compare the registered reference contour and the observed contour, and output the deviation with direction.
- Calculate the minimum area straightness result under the agreed method for finite two-dimensional sampling points.
Ordinary 2D images cannot recover groove depth, complete 3D topography, or arbitrary geometric tolerances out of thin air. Structured light, laser triangulation, rotational sampling or other 3D measurement solutions should be evaluated when height, flatness, coaxiality or 3D reference systems are involved.
Outputable measurement results
| output | unit or form | Prerequisites for use |
|---|---|---|
| sub-pixel edge position | px; after calibration, it can be used in length units such as mm | Edge polarity, sampling direction and contrast stability |
| Line or circle parameters | Position, direction, circle center, radius and fitting residuals | Point sets come from explicitly measured edges, model with exclusion rules fixed |
| Width and Feret diameter | px or calibrated length | The contour is closed, the scale is effective, and the sampling position is clear |
| Rotate envelope rectangle | Center, angle, length and width | Does not replace all dimensional and geometric tolerances |
| Contour deviation | Signed distance, Hausdorff or Chamfer distance | The reference and observation are in the same coordinate system, and the registration error is additional |
| Two-dimensional straightness | Minimum envelope parallel band width and direction | Only for limited two-dimensional sampling points and agreed evaluation methods |
The results should be accompanied by coordinate system, units, calibration version, ROI, fitting method, number of valid points and status. Unmeasurable, model degradation, out of calibration range and unqualified input quality are output respectively.
Technical route and key points for selection
| Task | Common methods | Key points for method selection |
|---|---|---|
| Edge positioning | Gradient calipers and sub-pixel interpolation | Sampling lines, edge polarity, contrast and filtering need to be fixed |
| Line and circle fitting | Least squares, geometric distance and robust fitting | Choose method based on outliers, model type, and reproducibility requirements |
| Line segment extraction | Hough line segments and geometric filtering | Filter based on product edge direction, location and length rules |
| width and envelope | Feret diameter, normal section and rotated rectangle | Distinguish between contour global shape and specified section dimensions |
| Contour deviation | Signed distance, Hausdorff and Chamfer distance | First control the registration error, sampling density and direction definition |
| Two-dimensional straightness | Minimum area parallel zone assessment | Confirm sampling and evaluation caliber according to drawing standards |
The typical process is: imaging and calibration → ROI and edge definition → sub-pixel extraction → model fitting or contour statistics → coordinate and unit conversion → quality status and result output.
Input data and imaging conditions
Before starting the project, drawings, measurement locations, dimensional ranges, tolerances, datums and standards adopted, as well as original images of normal, out-of-tolerance and difficult-to-measure samples must be provided. Provide both physical and independent reference measurement results when conditions permit.
Imaging information includes camera, lens, light source, field of view, working distance, workpiece attitude, fixture, trigger and motion status. Bevels, burrs, oil films, transparent edges, reflections, depth of field, and occlusions alter image edges and need to be covered in the sample.
When target accuracy approaches pixel scale or tolerance boundaries, telecentric imaging, distortion, mounting variation, calibration residuals, reference instrumentation, and ambient temperature should be evaluated and theoretical resolution should not be used as a substitute for system error budget.
Verification methods and applicable conditions
The project uses representative workpieces and independent reference values to check edge positions, fitting residuals, dimensional errors, repeated clamping, calibration drift and unmeasured states respectively. Samples cover measurement ranges, tolerance boundaries, surface variations, and field environments.
Physical accuracy and processing cycle time shall be accepted under the agreed camera, lens, calibration, tooling, platform and software version. When it comes to three-dimensional flatness, coaxiality, complete GD&T assessment or legal metrology, corresponding measurement links and standard methods need to be configured.
Project implementation and delivery
- Requirements and benchmark confirmation: Fixed measurement objects, sections, datums, tolerances, units and downstream determinations.
- Imaging and algorithm verification: Examine marginal testability, technical roadmaps, errors, and failures on a representative sample.
- First type adaptation and interface: Access to collection, calibration, parameters, measurements, status, logs and PLC or host computer interfaces.
- Independent sample acceptance: Covers range, attitude, surface, re-clamping and environmental changes to form error distribution and limits.
The scope of delivery may include measurement procedures, call libraries, configuration and calibration files, interface descriptions, sample and result lists, validation reports and release notes. The camera, lens, light source, fixture, motion mechanism and legal measurement procedures are confirmed separately.
Acceptance method
| Acceptance items | suggested record | Things to note |
|---|---|---|
| Accuracy | Mean absolute error, maximum absolute error, deviation distribution | Use independent reference measurements across the full working range |
| Repeatability | Fixed posture continuous measurement and re-clamping results | Don’t replace repeatability with accuracy |
| Coverage and rejection | Normal, out of tolerance, boundary and unmeasurable samples | Separate statistics on failure reasons and manual review paths |
| Calibration and Drift | Calibration residuals, out-of-range samples, temperature and time changes | Fixed calibration version and record recalibration conditions |
| Beats and Resources | Algorithm time consumption, acquisition and transmission, equipment actions and result updates | Tested under target platform and actual task combinations |
Decision rules for approaching tolerance boundaries, reference instrument uncertainties and measurement system analysis requirements should be determined prior to acceptance.
Equipment licensing and ongoing service
Software usage rights can be registered according to agreed equipment or workstations, measurement scenarios and versions. Operational maintenance covers problem repair and retesting of the original delivery scope; workpiece change, expansion of size range, tightening of tolerances, replacement of camera lens, change of measurement position or platform migration require change assessment.
Continuous optimization is based on comparison of old and new data and regression verification. The original delivery scope, new requirements, designated version running license, annual subscription, machine replacement and offline recovery rules are separately agreed in the contract.
FAQ
Does the higher the pixel count of the camera, the higher the measurement accuracy?
The two do not correspond directly. Pixel count is only one input factor, actual error is also affected by field of view, lens, depth of field, distortion, edge quality, mounting, calibration and reference methods.
Can sub-pixel edges be directly converted to micron accuracy?
No. Sub-pixel is a coordinate estimation method, and the physical accuracy needs to be verified with actual imaging proportions and independent values, and errors in different workpieces, locations, and environments must be counted.
Can 2D images detect depth or complete concentricity?
A single 2D view usually cannot. Depth, complete coaxiality and three-dimensional reference relationships require additional viewing angles, motion sampling or three-dimensional sensors, and the evaluation method is determined according to the drawing standards.
Can existing cameras and light sources continue to be used?
It can be evaluated first with the original image. Whether to retain is determined by edge measurability, field of view, working distance, tolerance and reference measurement comparison, and cannot be judged based on the equipment model alone.
Define the Development Scope with Samples and Device Requirements
Two-dimensional dimension and contour measurement algorithm services
Please describe the task object, original picture or video, target indicators, device platform, interface and sample situation.
Phone: 13910119357xuzhiyang0928@gmail.com