Photometric stereo-based defect detection for lithium battery top covers

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.

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.

- 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.
- Four images in one pass. Sorting the interleaved lines by partition gives four images of the moving cover, each under a different lighting direction.
- 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.
- 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.
- 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.


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.



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}
}