Research / 02

2021–2024

Inline Optical Inspection

Inline 2D optical inspection for detecting micrometric deviations during mechanical-part manufacturing.

  • Optical inspection
  • Image processing
  • Machine vision
  • Manufacturing
Editorial illustration of an optical inspection head scanning a machined component against a dimensional grid.

Overview

Turning a camera image into a dimensional measurement takes more than detecting an edge. Optics, illumination, calibration and geometric reasoning must work together to compare the observed profile with the intended part.

This case study brings together two related applications: inspection of machined components and machine-integrated profile scanning. Both shared an image-to-measurement core adapted to different acquisition and manufacturing conditions.

My contribution

I worked across optics and illumination, calibration and metrology, image-processing and geometric-measurement algorithms, software and GUI development, machine integration and experimental testing. My contribution connected acquisition with the algorithms and operator workflows needed to obtain usable dimensional results.

I co-authored the preliminary validation report, authored the machine-inspection GUI user guide and contributed geometric-measurement software. Development and experimental results were collaborative team work.

From image to metric profile

Acquire a useful edge

The optical setup combined a monochrome global-shutter camera, telecentric optics and controlled illumination. Calibration established metric coordinates across the field of view. Lighting and exposure made the physical edge observable despite surface appearance and machining residues.

Original monochrome reference-part image from the exposure study.
Reference component at 3000 µs exposure: image contrast is the starting point for dimensional inspection.Preliminary validation · February 2023
The same component under coaxial and dark-field illumination, revealing different edge and surface details.
Coaxial and dark-field illumination reveal different aspects of the same part.Original acquisition pair · Different exposure settings

Refine the contour below the pixel grid

An initial contour supplied the local geometry. Neighbouring points were used to estimate normals, and intensity transitions along those normals refined the boundary to sub-pixel coordinates. Calibration converted the extracted profile into metric space.

An acquired edge and an enlarged detail comparing the pixel-grid contour with the refined sub-pixel boundary.
From a pixel-grid contour to a refined sub-pixel edge.Original algorithm illustration

Align with CAD and measure selected features

DXF geometry defined the nominal profile and inspection regions. Alignment brought the observed contour into that reference frame; local fitting and robust distance estimation produced linear, angular and diameter measurements.

The final prototype added learning-assisted alignment to handle pose changes and mirrored orientations. Part-specific keypoint detection supported registration, while dimensional measurement remained tied to the calibrated contour.

Reference-part validation

At 3000 µs exposure, a preliminary experiment found absolute differences of 1.5–3.9 µm across four independently measured reference dimensions, averaging approximately 2.4 µm.

Signed optical-to-reference differences of −2.1, −3.9, −1.5 and +2.2 micrometres, with a mean absolute difference of 2.43 micrometres.
Optical measurement differences across four reference features · February 2023.

These results characterize the controlled reference setup. The machine-integrated application used the same measurement principles in a different acquisition context.

Final prototype and production lessons

The complete inspection tool combined acquisition, contour extraction, CAD alignment, dimensional measurement and result monitoring. Processing took 0.5–1.5 seconds per part, depending on contour complexity and measurement count. The final report describes burr-free reference measurements as consistent with the ±5 µm target.

A real archived component profile and an enlarged corner showing recalculated local normal directions.
An acquired profile becomes measurable geometry, with local edge directions shown in detail.Archived CSV profile · Explanatory geometric reconstruction

Manufacturing-line trials exposed a decisive limitation: nearly straight, redeposited machining burrs could resemble the intended edge. On the tested component, this prevented reliable process-drift detection.

Microscope image of a machined edge and burr, with an edge overlay and 100 micrometre scale.
A regular-looking burr can hide the geometry the system is meant to measure.Production trial · Final project report

Machine-integrated scanning

In the second application, the nominal profile was divided into capture locations. The machine positioned the camera, acquired successive images and retained their extracted profiles. Camera-to-machine calibration connected optical measurements to axis and tool coordinates.

Machine-inspection interface for geometry import, capture segmentation and measurement definition.
Planning image acquisition and measurements from the nominal geometry.Operator guide · March 2024

A coarse/fine autofocus sequence supported acquisition with configurable travel, step size and settling time. Python application logic and modular native interfaces separated camera access, calibration, focus, machine communication and geometric measurement. Saved projects retained settings, images and profiles together.

Engineering takeaways

  • Optics and algorithms: design image quality and contour processing as one measurement chain.
  • Geometric metrology: connect sub-pixel profiles with CAD-defined features and metric calibration.
  • Reusable software: adapt the measurement core to inspection stations and machine workflows.
  • Real-process validation: use production trials to expose limits beyond the controlled bench.

Project context / Sources

This case study uses the supplied Optical Inspection — Project Presentation package: the February 2023 preliminary validation, March 2024 machine-inspection guide, shared software and final production-prototype reports. Numerical results belong to the production-part experiments; the second application contributes integration and workflow evidence.

InnoInspect on SUPSI ARIS