###### Abstract  
A visual measurement method based on a key point detection network is proposed for the difficulty of fitting the cross-sectional profile of ultra-narrow gap welds and the low efficiency and accuracy of manual measurement of geometric parameters. First, the HRnet (High-Resolution Net) key point detection algorithm was used to train the feature point detection model, and 18 profile feature points in a \"measurement unit\" were extracted. Secondly, the feature point coordinates are transformed from the image coordinate system to the weld coordinate system, and the weld profiles are fitted by the least squares method. Finally, the measurement system is calibrated with a coplanar linear calibration algorithm to perform pixel distance to actual distance conversion for quantitative detection of geometric dimensions. The experimental results show that the accuracy of the proposed method for key point localization is 95.6%, the mean value of the coefficient of determination R-square for curve fitting is greater than 94%, the absolute error of measurement is between 0.06 and 0.15 mm, and the relative error is between 1.27% and 3.12%. The measurement results are more reliable, and the efficiency is significantly improved compared to manual measurement. weld cross-sectional shape; key point detection; curve fitting; camera calibration 202313455 10  
the weld profile feature points using the image processing method of edge detection, and exponential and Gaussian functions were fitted to the upper and lower edges of the weld to obtain the geometric model of the weld profile [10]. [PERSON] et al. manually took a pole point at certain polar angle intervals on the weld profile based on the polar coordinate system. They used the method of cubic interpolation with MATLAB to fit the weld cross-sectional profile [11]. Researchers commonly use the analytic coefficients of the geometric model as output variables of the weld profile prediction model for weld profile prediction. The second type is the measurement of geometric dimensions such as weld fusion width, fusion depth, and weld height to describe the weld shape quantitatively. The measurement is mainly performed manually using measuring instruments directly, or manually using measurement software for image measurement. [PERSON] et al. manually measured the weld cross-sectional fusion width and fusion depth using calipers during parametric optimization modeling [12]. [PERSON] et al. used Image-pro software to measure the weld cross-section's fusion width and weld height during the optimization of the laser-arc composite welding process parameters [13]. When extracting the ultra-narrow gap single-layer weld profile, the efficiency of manually locating individual points and then using the interpolation method to extract feature points is low. At the same time, the edge of the weld profile is blurred, and the error of taking feature points by the edge detection method is also relatively large. When measuring geometric dimensions, adjacent welds are fused, and the weld fusion depth measurement points and weld height measurement points cannot be directly observed, but can only be located by experience, and the measurement accuracy is limited by the experience of the measurement personnel, and the efficiency is not high when processing a large amount of data. Currently, with the development of deep learning, the emergence of the key point detection model provides a new idea for the efficient extraction of weld profile feature points and now has a wide range of applications in industrial image processing. [PERSON] et al. proposed a single tillers rice key point prediction and skeleton extraction method based on an hourglass network model to obtain phenotypic parameters, such as spike length, by detecting rice key points to speed up rice breeding [14]. [PERSON] et al. proposed a semi-supervised skeletal image key point detection framework to accurately extract the key point locations in human hip joints to measure anatomical parameters [15].