The invention relates to the field of
image processing, and particularly discloses a welded
pipe surface defect detection method based on
robot visual inspection. The method comprises the steps that a
robot carries a binocular camera and an annular LED
light source and moves at a
constant speed in the axial direction of a welded
pipe to collect orthographic and inclined views, and a three-dimensional
point cloud is constructed; and establishing a parameterized mapping function based on the
point cloud, and converting the 3D coordinate into a 2D expansion surface coordinate. In the
convolutional neural network, a first layer is inserted into a
spatial transformation network to correct
distortion of the expanded image, deformable
convolution is adopted to extract edge, local deformation and specific defect response features, and standard
convolution is combined to extract global features; and fusing multi-scale features and adding an attention mechanism to improve the weight of a
defect region, and outputting a defect category and a bounding box offset after generating a candidate box. The method effectively solves the problems of stretching, deformation and defect
distortion of welded
pipe curved surface imaging, reduces the imaging difference of the same defect, and remarkably improves the defect positioning precision and recognition accuracy.