Publications / 2025 / Photometric stereo-based defect detection for lithium battery top covers

Photometric stereo-based defect detection for lithium battery top covers

Huayong Li, Weijin Xie, Wei Pan
Seventh International Conference on Image Processing and Machine Vision (IPMV 2025), vol. 13636, 100-107

In one sentenceA line-scan camera strobes four light partitions in turn to capture photometric-stereo images of moving battery top covers; enhanced curvature maps then make shallow scratches and pits detectable.

The problem

Cylindrical lithium batteries pick up scratches and pits on their top covers during production, from collisions, friction and other external forces. Human visual inspection is still common, but it is inefficient, inaccurate and prone to human error. Ordinary 2D machine vision lacks depth information: on a reflective metal surface it struggles in bright and dark areas, and text or dirt is easily confused with real defects. 3D methods such as structured light and fringe projection detect defects more precisely, but they are costly and data-intensive.

Photometric stereo (PS) takes a middle path. It photographs the surface under several lighting directions and recovers surface normals and curvature from the brightness changes, which makes it effective at revealing subtle surface variations. Traditional PS, however, is limited to static objects, which does not suit a production line, and very subtle defects such as shallow scratches remain hard to detect.

Four grayscale images of the same round battery top cover side by side, each lit from a different direction, with the bright rim and faint surface marks changing from image to image.
The four images of a battery top cover, one per light-source partition. Fig. 5 of the paper.

How it works

The method changes both the hardware and the algorithm. A line-scan camera images the cover while it moves, and a four-partition spherical integrating light source is strobed so that consecutive scan lines are lit from different directions. The usual circular opening at the top of the dome is replaced by a narrow slit, which reduces shadow artefacts. The four images are then turned into albedo and curvature maps on the GPU with CUDA, the curvature map is enhanced, and defects are extracted with image processing.

  1. Time-division acquisition. The motion platform’s encoder emits a line signal. A frequency divider produces four signals that switch the four light partitions in turn while triggering the camera, so each scan line is lit by one partition.
  2. Four images in one pass. Sorting the interleaved lines by partition gives four images of the moving cover, each under a different lighting direction.
  3. Normals by least squares. Under the Lambertian model, a pixel’s brightness is I = ρ L · N, with surface reflectance (albedo) ρ, light direction L and surface normal N. Four lights give four equations per pixel, solved by least squares. The albedo image shows foreign objects and contaminants; the normals give the surface gradients and a mean curvature image, which shows scratches, wrinkles and other defects.
  4. Enhancement. Contrast stretching widens the grey-level differences in the curvature image. A weighted least-squares filter, an edge-preserving smoother, then suppresses the texture of the workpiece while keeping defects such as scratches.
  5. Defect extraction. A region of interest is selected and the image is filtered and resampled. A difference image is formed between the original and the preprocessed (filtered and resampled) image, then thresholded; morphological operations refine the regions, and defects are kept according to their shape and grey-level features.
Block diagram: an encoder row signal enters a frequency division controller, which outputs a line signal that triggers camera capture and, through event splitting, Signals 1 to 4 that drive light source partitions 1 to 4.
Signal flow of the acquisition system. The encoder’s line signal goes to a frequency-division controller, which triggers the camera and splits the events into four signals, one per light-source partition. Fig. 1 of the paper.
Flow chart: image input, draw the ROI, filtering processing, sampling processing, image difference, image binarization, morphological, filter according to defect characteristics, result output.
The defect detection pipeline applied to the synthesised photometric stereo image. Fig. 3 of the paper.

Results

The system runs on an industrial computer with an Intel Core i5-12500 processor and an Nvidia GeForce RTX 3060 GPU. The light direction vectors are first calibrated with a ring light, and the four images captured along these directions are processed in parallel with CUDA to produce the albedo and mean curvature images. The enhanced curvature image was compared with the method of Ren et al. on five image-quality metrics: sharpness, information entropy, variance, PSNR and SSIM (the last two are peak signal-to-noise ratio and structural similarity). The proposed method scored higher on all five (entropy 4.70 vs 4.16, PSNR 12.37 vs 10.84, SSIM 0.527 vs 0.512), which the authors read as stronger defect contrast with the original image structure preserved. The authors also compared CPU parallel computation with Intel TBB against CUDA on the GPU over different image sizes, and found that GPU acceleration significantly improves computational efficiency.

Future work will extend the algorithm to non-Lambertian surfaces and further improve real-time processing efficiency.

Two square images of the battery top cover: on the left a dark albedo image with a bright rim and inner ring, on the right a flat grey mean curvature image in which the outlines appear faintly.
Albedo image (left) and mean curvature image (right) computed from the four captures. Fig. 6 of the paper.
Left: a black binarized image of the cover with white speckle and several bright line segments. Right: the grey cover image with a blue circle marking the region and the detected defects marked in green.
Binarized image (left) and detection result (right), with the detected defects marked in green. Fig. 7 of the paper.
A grid of three rows and four columns: two line-shaped scratches and one small spot-like defect, each shown in four processing stages ending in a white defect shape on black.
Close-ups of three defects through the extraction process; the right column shows the extracted defect regions. Fig. 8 of the paper.

Cite

@inproceedings{li2025photometric,
  title={Photometric stereo-based defect detection for lithium battery top covers},
  author={Li, Huayong and Xie, Weijin and Pan, Wei},
  booktitle={Seventh International Conference on Image Processing and Machine Vision (IPMV 2025)},
  volume={13636},
  pages={100--107},
  year={2025},
  organization={SPIE},
  doi={10.1117/12.3062071}
}
Type
Paper Conference
Topic
Industrial Inspection
Venue
Seventh International Conference on Image Processing and Machine Vision (IPMV 2025), vol. 13636, 100-107
Year
2025
DOI