CN-121994170-A - Flatness online detection method, system and storage medium based on line laser profiler
Abstract
The invention discloses a flatness online detection method, a flatness online detection system and a storage medium based on a line laser profiler. The method comprises the steps of obtaining two-dimensional height array data of the surface of a measured piece, unifying images to a standard geometric coordinate system through four-edge boundary straight line fitting and perspective transformation, calculating robust statistics in joint bandwidth aiming at an image joint, adaptively selecting a constant bias mode or carrying out leveling treatment according to a linear mode, adopting a straight ruler method based on stability scores, optimizing supporting point pairs under the condition of meeting no jacking constraint, calculating flatness indexes and generating a visual thermodynamic diagram. The invention solves the problems of low sampling coverage rate, large seam interference and poor detection consistency in the prior art, and realizes the online detection of the full surface and high-precision flatness on the high-beat production line.
Inventors
- SHEN XUEWEN
Assignees
- 南京光衡工业技术有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20260115
Claims (10)
- 1. The online flatness detection method based on the line laser profiler is characterized by comprising the following steps of: s1, acquiring data, namely acquiring two-dimensional height array data of the surface of a measured piece through a line laser profiler; S2, geometric unification processing, namely performing four-edge boundary straight line fitting on the two-dimensional height array data, obtaining four corner coordinates through analysis and intersection, unifying images to a standard geometric coordinate system by utilizing a perspective transformation matrix, and obtaining a corrected height map; S3, seam self-adaptive leveling, namely, calculating a line average value difference sequence in seam bandwidth aiming at a spliced seam area in the corrected height map, and carrying out leveling treatment on the image by self-adaptively selecting a constant bias mode or a line-based mode based on a steady statistic; S4, calculating flatness, namely selecting candidate supporting point pairs from the leveled height map by adopting a ruler method based on stability grading, calculating optimal supporting point pairs and outputting flatness indexes on the premise of meeting the condition of no jacking constraint.
- 2. The online flatness detection method based on a line laser profiler according to claim 1, wherein the specific method for performing four-edge boundary straight line fitting in step S2 is as follows: Extracting boundary point sets in four regions of interest (ROI) of an image, namely an upper region, a lower region, a left region and a right region, and solving straight line parameters in a mode of minimizing sum of absolute values of residual errors And So that Minimum; And solving the perspective matrix by using Direct Linear Transformation (DLT) to finish geometric correction.
- 3. The online flatness detection method based on a line laser profiler according to claim 1, wherein the seam adaptive leveling in step S3 specifically comprises: Calculating a line average value difference sequence of the left and right spliced images in the joint bandwidth ; Calculating the median of the sequences And median absolute deviation Setting a robust standard deviation And an interior point determination threshold ; Screening meets Inner point row set of (2) ; If the constant bias mode is determined, the median of the inner point set is calculated as the constant bias amount And performing amplitude limiting treatment; If it is determined that the line mode is in accordance with the line mode, the set of interior points is set Performing linear fitting If the difference between the top and bottom of the fitting straight line exceeds a set threshold value, adopting a linear function As offset, and carrying out amplitude limiting treatment; the calculated offset is applied to the corresponding row of the one-side image.
- 4. The online flatness detection method based on a line laser profiler as set forth in claim 3, wherein the clipping process in calculating the offset in step S3 means: By means of The function limits the offset to a set range In which Is the preset maximum allowable adjustment amount.
- 5. The online flatness detection method based on a line laser profiler according to claim 1, wherein the straight ruler method based on stability score in step S4 specifically comprises: extracting end points and local maxima from a height sequence to form a candidate point set ; Arbitrary taking two points in a candidate point set ( ) Structure ruler line Wherein Is the slope of the slope, Is the intercept; judging without jack-up constraint if any point between two points Is higher than the height of (2) Satisfy the following requirements The point pair is an effective supporting point pair, wherein To allow for gap tolerance; stability score calculation for effective support Point pairs :
- 6. Wherein, the A penalty term for the offset of the center of gravity of the support section from the center position; And selecting the point pair with the highest score as the optimal supporting point pair, and calculating a convex value or concave value index according to the point pair.
- 7. The online flatness detection method based on line laser profiler as set forth in claim 1, further comprising the step of S5, roll mark evaluation; and setting a band zone at the upper edge and the lower edge of the height map, calculating the maximum sinking depth in the band zone for each column of data, and taking the larger value in the upper band zone and the lower band zone as a roller printing index.
- 8. The online flatness detection method based on line laser profiler as set forth in claim 1, further comprising the step of S6 of online visual output; performing zero value estimation replacement on invalid pixels in the height map; calculating low-score values of a height map And high quantile value Linearly stretching and mapping the pixel value to an 8-bit gray scale space; And applying pseudo color mapping and edge weighted mixing to output a thermodynamic diagram.
- 9. Flatness on-line measuring system based on line laser profiler, characterized by comprising: The data acquisition module is used for acquiring the two-dimensional height array data of the surface of the measured piece through the line laser profiler; The geometric unification processing module is used for performing four-edge boundary straight line fitting on the two-dimensional height array data, obtaining four corner coordinates through analysis and intersection, and unifying the images to a standard geometric coordinate system by utilizing a perspective transformation matrix; The joint self-adaptive leveling module is used for calculating a line average value difference sequence in joint bandwidth aiming at a joint area in an image, calculating the median and the median absolute deviation of the sequence as steady statistic, self-adaptively selecting a constant bias mode or a line linear mode according to the steady statistic, calculating the bias and applying the bias to the image to eliminate the joint deviation; the flatness calculation module is used for executing a straight ruler method based on stability scores, extracting candidate supporting point sets from the height data, constructing straight ruler lines of candidate point pairs, calculating stability scores according to the heights, spans and gravity center deviation of the supporting points under the condition that the middle points are not higher than the straight ruler lines and the tolerance is not jacked, and selecting the point pair with the highest score as a reference to calculate flatness indexes; and the visual output module is used for carrying out split value stretching and pseudo color mapping on the processed height data to generate a flatness detection thermodynamic diagram.
- 10. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any one of claims 1 to 7.
Description
Flatness online detection method, system and storage medium based on line laser profiler Technical Field The invention relates to the technical field of industrial detection, in particular to a flatness online detection method, a flatness online detection system and a storage medium based on a line laser profiler. Background In the production and manufacturing process of plate products such as ceramics, stones, glass and the like, the surface flatness of the products is one of the key indexes for measuring the quality. If the surface of the plate is warped, concave or convex, the appearance is not only affected, but also the subsequent paving or processing is difficult. Therefore, it is important to accurately and rapidly detect the flatness of the plate. The existing flatness detection means are mainly divided into two types, namely contact type measurement and non-contact type measurement. Conventional contact measurement typically relies on manual operation, uses a guiding rule and a feeler gauge to measure the surface of the measured piece off-line, and records the maximum gap thickness as flatness data. The method has low equipment cost, but has the problems of low detection efficiency, incapability of tracing data in real time and the like. Meanwhile, as the measurement result is greatly influenced by experience of operators and a force mode, the subjectivity of the detection result is strong, the consistency is difficult to ensure, and the online detection requirement of large-scale continuous production is difficult to meet. With the development of automation technology, detection schemes based on point laser displacement sensors are widely used. The scheme is to guide a point laser sensor through a mechanical mechanism, conduct one-dimensional path scanning along four sides and two diagonal lines of a measured piece, obtain a plurality of height curves, and estimate flatness through an endpoint connecting line or interpolation method. However, the scheme based on one-dimensional track sampling has natural limitations that firstly, the sampling coverage rate is insufficient, only specific linear tracks can be covered, local warping or special-shaped defects outside the tracks are easy to miss-detect, secondly, the detection result is highly sensitive to the repeatability of mechanical motion tracks and the transmission gesture of a detected piece, deflection or positioning errors of the workpiece are easy to be directly conducted into measurement errors, and finally, the point scanning mode usually needs track-by-track motion sampling, the detection beat is limited by mechanical acceleration and deceleration and zero return processes, and full detection of high-speed running water is difficult to realize. In summary, the existing flatness detection technology is difficult to simultaneously meet the requirements of full surface coverage, high precision, high consistency and online high-speed detection, and cannot provide complete two-dimensional morphology information for closed-loop optimization of the production process. Disclosure of Invention In order to overcome the defects existing at present, the invention provides a flatness online detection method based on a line laser profiler, which comprises the following steps: s1, acquiring data, namely acquiring two-dimensional height array data of the surface of a measured piece through a line laser profiler; S2, geometric unification processing, namely performing four-edge boundary straight line fitting on the two-dimensional height array data, obtaining four corner coordinates through analysis and intersection, unifying images to a standard geometric coordinate system by utilizing a perspective transformation matrix, and obtaining a corrected height map; S3, seam self-adaptive leveling, namely, calculating a line average value difference sequence in seam bandwidth aiming at a spliced seam area in the corrected height map, and carrying out leveling treatment on the image by self-adaptively selecting a constant bias mode or a line-based mode based on a steady statistic; S4, calculating flatness, namely selecting candidate supporting point pairs from the leveled height map by adopting a ruler method based on stability grading, calculating optimal supporting point pairs and outputting flatness indexes on the premise of meeting the condition of no jacking constraint. Further, the specific method for performing four-edge boundary straight line fitting in the step S2 is as follows: Extracting boundary point sets in four regions of interest (ROI) of an image, namely an upper region, a lower region, a left region and a right region, and solving straight line parameters in a mode of minimizing sum of absolute values of residual errors AndSo thatMinimum; And solving the perspective matrix by using Direct Linear Transformation (DLT) to finish geometric correction. Further, the seam self-adaptive leveling in step S3 specifically includes: Calculating a line aver