CN-121999239-A - Method, device, computer equipment and medium for extracting data in resistance spot welding process
Abstract
The application relates to a method, a device, computer equipment and a medium for extracting data in a resistance spot welding process, wherein the method comprises the steps of performing frame cutting and color analysis on an original resistance spot welding data image to obtain a frame-free image and image color information; the method comprises the steps of determining origin coordinates of coordinate axes in an image, extracting pixel sets of a current curve and a resistance curve based on image color information, extracting pixel sets of a current reference line and a resistance reference line from the image to determine pixel coordinates of a current intersection point and a resistance intersection point, extracting real coordinates of the current intersection point and the resistance intersection point from the image, converting the pixel coordinates of each pixel in the pixel sets of the current curve and the resistance curve into real coordinates based on the origin coordinates, the pixel coordinates and the real coordinates to obtain real coordinate sets of the resistance curve and the current curve, and executing missing value filling operation when lengths of the two real coordinate sets are inconsistent to obtain a standard coordinate set. The application can extract accurate resistance spot welding process data.
Inventors
- CHEN XIANGXIANG
- CHEN GENG
- GAO YANJUN
- ZHANG QIANG
Assignees
- 浙江吉利控股集团有限公司
- 吉利汽车研究院(宁波)有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20251208
Claims (10)
- 1. A method of extracting data from a resistance spot welding process, the method comprising: Performing frame cutting on an original resistance spot welding data image to obtain a borderless image, and performing color analysis on the borderless image to obtain image color information; Performing coordinate axis identification on the borderless block image to determine origin coordinates of the coordinate axes; respectively extracting pixel sets of a current curve and a resistance curve from the borderless block image based on the image color information; Extracting pixel sets of a current reference line and a resistance reference line from the borderless block image through color recognition, frequency statistics and contour detection, determining pixel coordinates of a current intersection point and a resistance intersection point based on the pixel sets of the current reference line and the resistance reference line, extracting real coordinates of the current intersection point and the resistance intersection point from the borderless block image based on the image color information and character recognition, and converting pixel coordinates of each pixel in the pixel sets of the current curve and the resistance curve into real coordinates based on the origin coordinates, the pixel coordinates of the current intersection point and the resistance intersection point and the real coordinates of the current intersection point to obtain a real coordinate set of the resistance curve and the current curve; And when the lengths of the current curve and the real coordinate set of the current curve are inconsistent, performing missing value filling operation to obtain the standard coordinate set of the current curve and the current curve.
- 2. The method of claim 1, wherein the performing coordinate axis recognition on the borderless block image to determine origin coordinates of coordinate axes comprises: Sequentially carrying out gray level processing, reverse binarization processing and morphological closing operation on the borderless block image to obtain a rough line coordinate axis outline; Skeletonizing the rough line coordinate axis outline to obtain a single-pixel coordinate axis skeleton; and extracting the pixel coordinates of the coordinate axis origin from the single-pixel coordinate axis skeleton.
- 3. The method of claim 2, wherein extracting pixel coordinates of a coordinate axis origin from the single-pixel coordinate axis skeleton comprises: extracting pixel coordinates of four vertexes of a coordinate axis from the single-pixel coordinate axis skeleton through polygon approximation; and determining the pixel coordinates of the coordinate axis origin based on the pixel coordinates of the four vertexes.
- 4. The method of claim 1, wherein the extracting pixel sets of a current curve and a resistance curve from the borderless block image based on the image color information, respectively, comprises: extracting initial pixel sets of a current curve and a resistance curve from the borderless block image based on the image color information; Noise filtering is carried out on the initial pixel sets of the current curve and the resistance curve respectively through statistical analysis; And respectively carrying out preheating trough detection and data filling on the initial pixel sets of the current curve and the resistance curve subjected to noise filtering to obtain the pixel sets of the current curve and the resistance curve.
- 5. The method of claim 4, wherein the pre-heat valley detection and data filling of the initial set of pixels of the noise filtered current curve and the resistance curve, respectively, comprises: taking the initial pixel set of the current curve and the initial pixel set of the resistance curve after noise filtering as target pixel sets respectively, and carrying out the following processing: Screening pixels with pixel abscissas in a preset interval from the target pixel set, and arranging the screened pixels in ascending order according to the pixel abscissas to obtain a first pixel subset; Calculating a pixel abscissa interval of each pair of adjacent pixels in the first subset of pixels; When the pixel abscissa interval of any pair of adjacent pixels is larger than a preset interval threshold, taking an abscissa interval corresponding to the pixel abscissa interval as a preheating trough interval; Filling pixels in the preheating trough interval by taking the ordinate of the origin coordinate as a filling value to obtain a second pixel subset; the first subset of pixels and the second subset of pixels are combined.
- 6. The method of claim 1, wherein the converting the pixel coordinates of each pixel in the pixel set of the current curve and the resistance curve to real coordinates based on the origin coordinates, the pixel coordinates of the current intersection and the resistance intersection, and the real coordinates of the current intersection and the resistance intersection comprises: For each pixel in the set of pixels of the current curve and the resistance curve, converting the pixel abscissa of the pixel to the true abscissa and the pixel ordinate of the pixel to the true ordinate by: ; Wherein, the And Respectively representing the pixel abscissa and the pixel ordinate of the pixel; And A pixel abscissa and a pixel ordinate respectively representing the origin coordinates; when the pixel is taken from the set of pixels of the current curve, And The pixel abscissa and the pixel ordinate representing the current intersection respectively, And Respectively representing the real abscissa and the real ordinate of the current intersection point; when the pixel is taken from the set of pixels of the resistance curve, And Respectively representing the pixel abscissa and the pixel ordinate of the resistor intersection, And And respectively representing the real abscissa and the real ordinate of the resistor intersection point.
- 7. The method of claim 1, wherein extracting the true coordinates of the current intersection and the resistance intersection from the borderless block image based on the image color information and text recognition comprises: Positioning coordinate display frames of the current intersection point and the resistance intersection point from the borderless block image based on the image color information; And respectively carrying out character recognition on the coordinate display frames of the current intersection point and the resistance intersection point to obtain the real coordinates of the current intersection point and the resistance intersection point.
- 8. A resistance spot welding process data extraction apparatus, the apparatus comprising: the preprocessing module is used for carrying out frame cutting on the original resistance spot welding data image to obtain a borderless image, and carrying out color analysis on the borderless image to obtain image color information; The coordinate axis identification module is used for carrying out coordinate axis identification on the borderless block image so as to determine origin coordinates of the coordinate axes; The spot welding process data extraction module is used for respectively extracting pixel sets of a current curve and a resistance curve from the borderless block image based on the image color information; The coordinate conversion module is used for respectively extracting pixel sets of a current reference line and a resistance reference line from the borderless block image through color recognition, frequency statistics and contour detection, determining pixel coordinates of a current intersection point and a resistance intersection point based on the pixel sets of the current reference line and the resistance reference line, positioning a coordinate display frame of the current intersection point and the resistance intersection point in the borderless image based on the image color information, carrying out text recognition on the coordinate display frame to obtain real coordinates of the current intersection point and the resistance intersection point, and converting pixel coordinates of each pixel in the pixel sets of the current curve and the resistance curve into real coordinates to obtain a real coordinate set of the resistance curve and the current curve; And the data verification module is used for executing missing value filling operation when the lengths of the resistance curve and the real coordinate set of the current curve are inconsistent, so as to obtain the standard coordinate set of the current curve and the resistance curve.
- 9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method according to any one of claims 1 to 7.
- 10. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any one of claims 1 to 7 when the computer program is executed by the processor.
Description
Method, device, computer equipment and medium for extracting data in resistance spot welding process Technical Field The embodiment of the application relates to the technical field of data extraction in a resistance spot welding process, in particular to a method, a device, computer equipment and a medium for extracting data in the resistance spot welding process. Background Resistance spot welding is an important role in the automotive manufacturing field as a widely used metal joining process. The welding quality directly affects the strength, the sealing performance and the safety of the structural member. In order to realize quality monitoring and traceability of a welding process, it is important to acquire accurate welding process data (such as welding current, dynamic resistance and the like). These data are typically collected and recorded by a monitoring system built into the spot welding apparatus for subsequent quality analysis, process optimization and fault diagnosis. However, in actual production sites, especially in the context of using imported or closed control system devices, raw process data is often encrypted or access restricted by the device vendor. If the user needs to acquire complete time sequence process data, the user usually needs to pay high additional authorization cost or rely on special software provided by manufacturers to derive limited information, so that the autonomous monitoring capability and the data management level of the enterprise for the welding process are severely restricted. Although digitized process data cannot be obtained directly, most spot welding devices support the local storage of process curves in the form of images. The images contain rich time sequence information, such as current-time curves, resistance-time curves and the like, and have higher readability and information density. If the original numerical data can be automatically and accurately restored from the image, the data acquisition cost is greatly reduced, and the usability and flexibility of the production data are improved. At present, although a general chart digitizing tool such as WebPlotDigitizer can realize manual or semi-automatic extraction of curves in images, the operation is complex, the automation degree is low, and the requirement of large-scale and high-efficiency data processing on an industrial site cannot be met. Disclosure of Invention The application aims at the defects and the shortcomings and provides a method, a device, computer equipment and a medium for extracting data in a resistance spot welding process. According to the method, on the premise that an original equipment database is not required to be accessed, the standardized output and the subsequent analysis and utilization of the data can be realized through the numerical data of the welding process in the derived original resistance spot welding data image by the computer vision technology. According to a first aspect, the application provides a method for extracting data in a resistance spot welding process, which comprises the steps of carrying out frame cutting on an original resistance spot welding data image to obtain a frame-free image, carrying out color analysis on the frame-free image to obtain image color information, carrying out coordinate axis identification on the frame-free image to determine origin coordinates of coordinate axes, respectively extracting pixel sets of a current curve and a resistance curve from the frame-free image based on the image color information, respectively extracting pixel sets of a current reference line and a resistance reference line from the frame-free image through color identification, frequency statistics and contour detection, determining pixel coordinates of the current intersection point and the resistance intersection point based on the pixel sets of the current reference line and the resistance reference line, extracting real coordinates of the current intersection point and the resistance intersection point from the frame-free image based on the image color information and character identification, converting pixel coordinates of each pixel in the pixel sets of the current curve and the resistance curve into real coordinates to obtain real coordinates of the current curve and the real coordinates of the resistance curve, and executing a standard curve operation curve when lengths between the current curve and the real coordinates of the current curve are inconsistent. In a further technical scheme, coordinate axis identification is carried out on the borderless block image to determine the origin coordinates of the coordinate axes, and the method comprises the steps of sequentially carrying out gray level processing, reverse binarization processing and morphological closing operation on the borderless block image to obtain a rough line coordinate axis outline, carrying out skeletonization processing on the rough line coordinate axis outline to obtain a