高级检索

基于改进Canny算法的单目相机三维重建标定方法

Research on 3D Reconstruction Calibration Method of Monocular Camera Based on Improved Canny Algorithm

  • 摘要: 针对传统相机标定方法标定精度较低且在环境干扰较强的场景下出现边缘模糊、无法满足高精度三维重建需要的问题,提出一种改进的Canny边缘检测算法以提升标定精度。该算法首先利用高斯滤波和导向滤波对标定图像进行处理,在滤除环境噪声的同时保证图像边缘的完整性和平滑性;然后采用四向卷积模板的Sobel算子计算边缘梯度,提高梯度计算的准确性并防止边缘细节缺失;最后通过Otsu算法自适应获取边缘阈值,增强算法对阈值检测的自适应性,并基于张正友标定法完成图像标定。为验证算法的有效性与鲁棒性,在20张标定板图像中别添加标准差为30的高斯噪声和密度为20%的椒盐噪声以模拟强干扰环境并进行标定实验。结果表明:相较于传统和改进Canny算法,本文算法对高斯噪声与椒盐噪声均具有显著的抑制效果,且边缘提取质量更优,使相机标定的重投影误差分别降低了54.1%和32.5%。在标准工件测量测试中,本文方法的平均绝对误差控制在0.1~0.3 mm范围,具有更高的测量精度且均方根误差更小(在0.15~0.30 mm范围),具备良好的工程应用价值。

     

    Abstract: To address the issue of low calibration accuracy in traditional camera calibration methods and edge blurring under strong environmental interference, which cannot meet the requirements of high-precision 3D reconstruction, an improved Canny edge detection algorithm was proposed to enhance calibration accuracy. First, the calibration images were processed using Gaussian filtering and guided filtering to eliminate environmental noise while maintaining edge integrity and smoothness. Then, a four-directional convolution template-based Sobel operator was employed to calculate edge gradients, improving gradient computation accuracy and preventing edge detail loss. Finally, the Otsu algorithm was utilized to adaptively determine edge thresholds, enhancing the algorithm's adaptability to threshold detection, and Zhang’s calibration method was applied to complete the image calibration. To verify the effectiveness and robustness of the proposed algorithm, Gaussian noise with a standard deviation of 30 and salt-and-pepper noise with a density of 20% were added to 20 calibration board images to simulate a high-interference environment, and calibration experiments were conducted. The results demonstrate that compared with traditional and improved Canny algorithms, the proposed algorithm exhibits significant suppression effects on both Gaussian noise and salt-and-pepper noise while achieving superior edge extraction quality, reducing the camera calibration reprojection errors by 54.1% and 32.5% respectively. In standard workpiece measurement tests, the proposed method maintains mean absolute errors within 0.1-0.3 mm range with higher measurement accuracy and smaller root mean square errors (0.15-0.30 mm), demonstrating excellent engineering application value.

     

/

返回文章
返回