A surface detection method and system
By combining the linear array camera and the linear laser scanner, using data expansion and algorithm analysis methods, the problem of difficulty in processing two-dimensional and three-dimensional information and detection in motion states in the prior art is solved, and an efficient and simplified surface detection process is achieved.
Patent Information
- Application Number
- CN202111172849.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-08
- Publication Date
- 2025-06-24
- Estimated Expiration
- 2041-10-08
AI Technical Summary
The prior art is difficult to take into account both the processing of two-dimensional information and three-dimensional information in surface detection, and the detection cannot be performed in a moving state, resulting in a long detection time, low efficiency, and complex calculations and high cost.
Through the combination of the linear array camera and the linear laser scanner, surface detection is realized, and the third data set is inserted into the two-dimensional data set using a linear proportional relationship to expand the data, making the number of rows equal to the two-dimensional data, and the correlation is analyzed through a preset algorithm for detection.
The surface detection of two-dimensional and three-dimensional information in a moving state is realized, which simplifies the calculation process, reduces the calculation difficulty and time, and occupies a small space and has better detection effect.
Smart Images

Figure CN113960046B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of surface detection, and more particularly, to a surface detection method and system. Background Art
[0002] In traditional industrial production and manufacturing, due to technical limitations, manual inspection methods are mainly used to detect surface defects of products. This method, due to manual limitations and technological backwardness, not only has a slow product inspection speed and low efficiency, but also is prone to errors during the inspection process, resulting in inaccurate inspection results.
[0003] In the prior art, technologies for surface detection using machines have emerged. However, in the field of automated inspection, as the complexity of production targets increases, simple two-dimensional inspection or three-dimensional inspection can no longer meet the growing product demand. In specific applications, customers not only require the detection of surface defects on the two-dimensional plane of the product, but also require the device to analyze its three-dimensional dimensional information.
[0004] Therefore, information processing that takes into account both two-dimensional information and three-dimensional information will become increasingly important for industrial applications. However, in the prior art, in the methods for processing two-dimensional information and three-dimensional information data in the field of surface detection, usually two independent workstations are designed to separately meet the requirements in the two-dimensional and three-dimensional aspects, resulting in high space costs. And the existing detection technologies generally require the object to be detected to be in a stationary state, and the object to be detected cannot be detected in a moving state, resulting in a long detection time and low detection efficiency. In addition, the detected two-dimensional information and three-dimensional information are also difficult to integrate, and complex calculations are required to obtain the detection results, with a long calculation time, a large amount of calculation, and a high calculation cost.
[0005] Therefore, a surface detection solution that can take into account the information processing of both two-dimensional information and three-dimensional information, can perform detection in a moving state, and has simple calculations is needed to solve the above problems. Summary of the Invention
[0006] Based on the problems existing in the prior art, the present invention provides a surface detection method and system.
[0007] The specific solutions are as follows:
[0008] A surface detection method includes the following:
[0009] Line-scan the surface to be detected through a preset line array camera to collect a first data set, and line-scan the surface to be detected through a preset line laser scanner to collect a second data set. The line array camera and the line laser scanner simultaneously scan the same position on the surface to be detected;
[0010] Among them, both the first data set and the second data set are two-dimensional data sets, with equal numbers of columns, unequal numbers of rows, and a linear proportional relationship;
[0011] Based on the linear proportional relationship, insert a third data set into the second data set for data expansion so that the number of rows of the expanded second data set is equal to that of the first data set; among them, the third data set is a two-dimensional data set and has the same number of columns as the second data set;
[0012] Analyze the correlation between the first data set and the expanded second data set through a preset algorithm to achieve surface detection of the surface to be detected.
[0013] In a specific embodiment, the process of obtaining the third data set includes:
[0014] Set a two-dimensional data set as the initial data set, where the number of rows of the initial data set is one less than the numerical value of the linear proportional relationship and the number of columns is the same as that of the second data set;
[0015] Through the luminance change corresponding to the initial data set, solve its first derivative, and the reciprocal of the first derivative of the initial data set represents the slope change of the data points in the last column and the last row of the initial data set;
[0016] Based on the slope change, calculate the data change speed of the second data set at the interpolation points, and the obtained initial data set is the third data set.
[0017] In a specific embodiment, the first data set Da is {Da(a, x)|a = 1, 2,...m, x = 1, 2,...N};
[0018] The second data set Dr is {Dr(b, y)|b = 1, 2,...,m, y = 1, 2,...N};
[0019] Among them, x and y represent the number of columns of the data set, and x = y, a and b represent the number of rows of the data set, and a = tb, b > 1;
[0020] The data set Data composed of the first data set and the second data set can be expressed as:
[0021]
[0022] Among them, t represents the linear proportional relationship, and N is a natural number;
[0023] Insert b(t - 1)*x data points into the second data set, and expand from Dr(b, y) to Dr(tb, y).
[0024] In a specific embodiment, let the initial data set be P(tb-r, x), where r < b;
[0025] The first derivative I of the initial data set x,tb,r is:
[0026]
[0027] where Da(tb, x) represents the data point at the tb-th row and the x-th column in the first data set, Dr(tb-r, x) represents the data point at the tb-r-th row and the x-th column in the second data set, and the reciprocal of I x,tb,r represents the slope change of the data point at the x-th row and the tb-r-th column in the initial data set;
[0028] Based on the slope change, calculate the data change speed of the interpolation point, and obtain the initial data set as:
[0029] P(tb-r, x) = I x,tb,r *|Dr(tb, x) - Dr(tb-b, x)|
[0030]
[0031] where I x,tb,r is the first derivative of the initial data set, r is an intermediate value, Da(tb-r,x) represents the data point at the tb-r-th row and the x-th column in the first data set, Da(tb,x) represents the data point at the tb-th row and the x-th column in the first data set, Dr(tb-r,x) represents the data point at the tb-r-th row and the x-th column in the second data set, Dr(tb,x) represents the data point at the tb-th row and the x-th column in the second data set, and P(tb-r, x) represents the third data set.
[0032] In a specific embodiment, it further includes a high-frequency controller;
[0033] The scanning areas of the line array camera and the line laser scanner form a collection line on the surface to be detected;
[0034] Control the movement of the surface to be detected through the high-frequency controller, so that the surface to be detected moves at a uniform speed relative to the collection line.
[0035] In a specific embodiment, it further includes a working light source;
[0036] The high-frequency controller outputs a high-frequency signal to the line laser scanner at a first working frequency, and the line laser scanner performs data acquisition at the first working frequency and provides a light source for the line array camera;
[0037] When the line laser scanner does not perform data acquisition, the line laser scanner stops providing light source for the line array camera, and the working light source provides light source for the line array camera.
[0038] In a specific embodiment, the operating frequency of the high-frequency controller is:
[0039] F = Nf
[0040] Where N is an integer not less than 2, f is the first operating frequency, and F is the operating frequency of the high-frequency controller;
[0041] The data volume collected by the line laser scanner is:
[0042]
[0043] Where M is an integer not less than 2, t is the data volume collected by the line array camera, and T is the data volume collected by the line laser scanner.
[0044] A surface detection system includes a line array camera, a line laser scanner, and a computing terminal;
[0045] The line array camera and the line laser scanner simultaneously scan the same position on the surface to be detected;
[0046] The line array camera is used to line-scan the surface to be detected and collect a first data set;
[0047] The line laser scanner is used to line-scan the surface to be detected and collect a second data set;
[0048] Wherein, both the first data set and the second data set are two-dimensional data sets, with equal number of columns, unequal number of rows, and a linear proportional relationship;
[0049] The computing terminal is used to insert a third data set into the second data set for data expansion based on the linear proportional relationship, so that the number of rows of the expanded second data set is equal to that of the first data; analyze the correlation between the first data set and the expanded second data set through a preset algorithm to realize the surface detection of the surface to be detected;
[0050] Wherein, the third data set is a two-dimensional data set and has the same number of columns as the second data set.
[0051] In a specific embodiment, the obtaining process of the third data set includes:
[0052] Set a two-dimensional data set as the initial data set, the number of rows of the initial data set is one less than the numerical value of the linear proportional relationship, and the number of columns is the same as the number of columns of the second data set;
[0053] By means of the luminance change corresponding to the initial data set, its first derivative is solved, so the reciprocal of the first derivative of the initial data set represents the slope change of the data points on the last column and the last row of the initial data set;
[0054] Based on the slope change, by calculating the data change speed of the second data set at the interpolation points, the obtained initial data set is the third data set.
[0055] In a specific embodiment, it further includes a working light source and a high-frequency controller, and the high-frequency controller is respectively connected to the working light source, the line laser scanner and the line array camera;
[0056] The high-frequency controller is used to control the working light source and the line laser scanner, so that the line laser scanner can provide light source for the line array camera when data is collected, and use the working light source to provide light source for the line array camera when the line laser scanner is not collecting data;
[0057] The scanning areas of the line array camera and the line laser scanner form a collection line on the surface to be detected; the high-frequency controller is further used to control the movement of the surface to be detected, so that the surface to be detected moves uniformly relative to the collection line.
[0058] The present invention has the following beneficial effects:
[0059] The present invention provides a surface detection method and system, which realizes surface detection by combining a line array camera and a line laser scanner, can simultaneously take into account the information processing of two-dimensional information and three-dimensional information, and can perform detection in a moving state, achieving a better surface detection effect. The line array camera and the line laser scanner are integrated at the same position, occupying a small space. Compared with the traditional face-to-face method, the row-to-row method adopted in this embodiment greatly reduces the calculation amount and the calculation difficulty, can greatly reduce the calculation time in actual calculation, and has a better detection effect after simplification.
[0060] To make the above objects, features and advantages of the present invention more obvious and understandable, the following specific embodiments are given and described in detail in conjunction with the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the drawings required in the embodiments. It should be understood that the following drawings only show some embodiments of the present invention, so they should not be regarded as limiting the scope. For those of ordinary skill in the art, other related drawings can be obtained based on these drawings without creative efforts.
[0062] Figure 1 It is a schematic flowchart of the surface detection method according to an embodiment of the present invention;
[0063] Figure 2 It is a schematic diagram of the positions of each module according to an embodiment of the present invention;
[0064] Figure 3 It is a schematic diagram of the data expansion principle according to an embodiment of the present invention;
[0065] Figure 4 It is a schematic diagram of the surface detection system module according to an embodiment of the present invention.
[0066] Reference numerals: 1 - linear array camera; 2 - line laser scanner; 3 - working light source; 4 - computing terminal; 5 - high-frequency controller. Specific embodiments
[0067] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0068] Embodiment 1
[0069] This embodiment proposes a surface detection method, which realizes surface detection by combining a linear array camera and a line laser scanner, can simultaneously take into account the information processing of two-dimensional information and three-dimensional information, and can perform detection in a moving state. The flowchart of the surface detection method is as shown in the accompanying drawings of the specification Figure 1 as shown. The specific solution is as follows:
[0070] A surface detection method includes the following:
[0071] 101. Line-scan the surface to be detected through a preset linear array camera to collect a first data set, and line-scan the surface to be detected through a preset line laser scanner to collect a second data set. The linear array camera and the line laser scanner simultaneously scan the same position on the surface to be detected.
[0072] 102. Based on the linear proportional relationship between the first data set and the second data set, insert a third data set into the second data set for data expansion so that the number of rows of the expanded second data set is equal to that of the first data set.
[0073] 103. Analyze the correlation between the first data set and the expanded second data set through a preset algorithm to realize the surface detection of the surface to be detected.
[0074] Among them, both the first data set and the second data set are two-dimensional data sets, with equal numbers of columns, unequal numbers of rows, and a linear proportional relationship. The third data set is a two-dimensional data set and has the same number of columns as the second data set.
[0075] In this embodiment, a linear array camera is used to detect two-dimensional information, and a line laser scanner is used to detect three-dimensional information. Moreover, two-dimensional information and three-dimensional information can be collected simultaneously in a moving state. By using the correlation between the collected data, a better surface detection effect can be achieved.
[0076] Step 1: Use a preset linear array camera to line-scan the surface to be detected to obtain a first data set, and use a preset line laser scanner to line-scan the surface to be detected to obtain a second data set.
[0077] A linear array camera is a camera that uses a linear array image sensor. The typical application fields of linear array cameras are to detect continuous materials such as metals, plastics, papers, and fibers. The object to be detected usually moves at a constant speed, and one or more cameras are used to continuously scan it row by row to uniformly detect its entire surface. As the name implies, a linear array camera scans in a "line" shape, and the scanned image is also a two-dimensional image. The coordinates of the scanning line are provided by a grating. The indication accuracy of a high-precision grating scale can be higher than the manufacturing accuracy of the pixel pitch of a area array CCD. Therefore, the accuracy of the image obtained by the linear array CCD in the scanning direction can be higher than that of the area array CCD image.
[0078] A laser scanner is an instrument that measures the dimensions and shapes of workpieces through scanning technology. A laser scanner must use a rotation motor with good stability and accuracy. When the light beam hits the multi-faceted prism driven by the motor and is reflected to form a scanning light beam. Since the multi-faceted prism is located on the front focal plane of the scanning lens and rotates uniformly, the incident angle of the laser beam relative to the mirror changes continuously, and thus the reflection angle also changes continuously. Through the action of the scanning lens, a parallel and continuous scanning line from top to bottom is formed.
[0079] In this embodiment, the linear array camera and the line laser scanner are fixed to the same working position, can detect the same area, and collect data simultaneously. Since the working principles of both the linear array camera and the line laser scanner are to collect data for one line each time, the two sensors can detect the data on the same line on the plane at the same time. Exemplarily, the side view of the motion state during scanning is shown in the attached specification Figure 2As shown in the figure, the dashed line represents the straight line where the scanning areas of the linear array camera and the line laser scanner are located. It can be seen from the attached figure that there is an intersection line between the straight lines where the scanning areas of the linear array camera and the line laser scanner are located. This intersection line is the acquisition line. By adjusting the position, the acquisition line is made to be on the surface to be detected, so as to enable the linear array camera and the line laser scanner to simultaneously collect data on the same straight line on the surface to be detected. There is relative motion between the acquisition line and the surface to be detected, including both the case where the acquisition line moves, the surface to be detected remains stationary, and the acquisition line moves at a uniform speed relative to the surface to be detected, and the case where the surface to be detected moves, the acquisition line remains stationary, and the surface to be detected moves at a uniform speed relative to the surface to be detected. Therefore, the first data set and the second data set have a high degree of position correlation.
[0080] In this embodiment, both the first data set and the second data set are two-dimensional data sets, with equal numbers of columns, unequal numbers of rows, and a linear proportional relationship. Let the first data set collected by the linear array camera be Da, which can be expressed as {Da(a, x)|a = 1, 2,...m, x = 1, 2,...N}; the second data set collected by the line laser scanner be Dr, which can be expressed as {Dr(b, y)|b = 1, 2,...m, y = 1, 2,...N};
[0081] Among them, x and y represent the number of columns of the data set, and x = y, a and b represent the number of rows of the data set, and a = tb, b > 1.
[0082] Both the data sets Da and Dr collect information of the same target at the same position. Among them, the Da data represents the two-dimensional luminance information of the target, and Dr represents the three-dimensional stereo information of the target. In addition, the sensors in the linear array camera and the line laser scanner are both digital sensors, and the data of each row collected are finite integers. For example, in the x-th row of data, Da includes 16000 data points, while Dr includes 4200 data points. Since the linear array camera and the line laser scanner are fixed, the amount of data collected in each row is also fixed, and a and b have a fixed linear proportional relationship. In the existing sensor technology, the data density of the imaging point cloud obtained by the line laser scanner is much lower than that of the imaging data of the linear array camera. Therefore, a is a multiple of b, that is, a = tb, b > 1.
[0083] Assume that the amount of data collected by the linear array camera is t, and the amount of data collected by the line laser scanner is:
[0084]
[0085] Among them, M is an integer not less than 2, and T is the amount of data collected by the line laser scanner.
[0086] Based on this, the first data set and the second data set collected can be integrated to form a complete data set. Let the data set be Data, which can be expressed as:
[0087]
[0088] Among them, t represents a linear proportional relationship, N is a natural number, x and y represent the number of columns of the data set, and x = y. a and b represent the number of rows of the data set, and a = tb, b > 1. Data represents the data set, Da represents the first data set, and Dr represents the second data set.
[0089] Step 102: Based on the linear proportional relationship between the first data set and the second data set, insert a third data set into the second data set for data expansion so that the number of rows of the expanded second data set is equal to that of the first data set.
[0090] Due to the high positional correlation between the first data set and the second data set, the second data set Dr(b, x) can be expanded to Dr(tb, x). The principle of data expansion is shown in the attached instructions of the specification. Figure 3 As shown, since both the data sets Da and Dr are collected at the same position of the same target, where the Da data represents the two-dimensional luminance information of the target and Dr represents the three-dimensional stereoscopic information of the target. Therefore, the method F(Da, Dr, b, x) realizes the expansion of the sparse data set Dr(b, x) into a dense data set Dr(tb, x) through calculation, inserting a specific number of data points into the Dr data set, that is, inserting b(t - 1)*x data points into the second data set, expanding from Dr(b, y) to Dr(tb, y). Let the inserted data points form the third data set, then the acquisition process of the third data set includes:
[0091] S1: Set a two-dimensional data set as the initial data set, where the number of rows of the initial data set is one less than the numerical value of the linear proportional relationship and the number of columns is the same as that of the second data set;
[0092] S2: Solve the first derivative through the luminance change corresponding to the initial data set, so the reciprocal of the first derivative of the initial data set represents the slope change of the data points in the last column and the last row of the initial data set;
[0093] S3: Based on the slope change, calculate the data change speed of the second data set at the interpolation points, and the obtained initial data set is the third data set.
[0094] Specifically, let the initial data set be P(tb - r, x), r < b; through the luminance change corresponding to the two-dimensional data in the initial data set, the first derivative Ix can be obtained, and the first derivative I of the initial data set x,tb,r is:
[0095]
[0096] Among them, Da(tb-r, x) represents the data point at the tb-rth row and the xth column in the first dataset, Da(tb, x) represents the data point at the tb-th row and the xth column in the first dataset, r is an intermediate value, and I x,tb,r The reciprocal of represents the slope change of the data point at the xth row and the tb-rth column in the initial dataset;
[0097] Based on the slope change, calculate the data change speed of the interpolation point to obtain the initial dataset as:
[0098] P(tb-r, x) = I x,tb,r *|Dr(tb, x) - Dr(tb - b, x)|
[0099]
[0100] Among them, r is an intermediate value, Da(tb-r, x) represents the data point at the tb-rth row and the xth column in the first dataset, Da(tb, x) represents the data point at the tb-th row and the xth column in the first dataset, dr(tb-r, x) represents the data point at the tb-rth row and the xth column in the second dataset, Dr(tb, x) represents the data point at the tb-th row and the xth column in the second dataset, and P(tb-r, x) represents the third dataset.
[0101] After obtaining the third dataset, the second dataset can be extended to obtain the extended second dataset. The extended second dataset has the same number of rows and columns as the first dataset, so that the data collected by the line array camera and the line laser scanner are in one-to-one correspondence in each row, simplifying the traditional face-to-face data into row-to-row data.
[0102] The traditional method uses a face-to-face approach, which can be understood as requiring a large number of complex operations to calculate the correlation between the data of one face and the data of another face, and then obtaining the change rate through the second derivative. The entire process takes several minutes even when using a computer. The row-to-row method is equivalent to simplifying the work of calculating the correlation through hardware settings and can be achieved only through simple first derivatives. Compared with the traditional face-to-face method, the row-to-row method adopted in this embodiment can greatly reduce the amount of calculation and the calculation difficulty, significantly reduce the calculation time in actual calculations, and has a better simplification effect.
[0103] In this embodiment, the scanning areas of the linear array camera and the line laser scanner form a collection line on the surface to be detected, and the collection line moves uniformly relative to the surface to be detected. The movement of the linear array camera and the line laser scanner can be controlled by a dedicated high-frequency controller so that they move uniformly relative to the surface to be detected; alternatively, the movement of the surface to be detected can be controlled so that the surface to be detected moves uniformly relative to the collection line. The relative movement speed can be adjusted according to the actual application to achieve high-speed movement and further reduce the data acquisition time.
[0104] In addition, a working light source needs to be set to provide light for the linear array camera. Based on the characteristics of the line laser scanner, the line laser scanner can also be specifically used as a light source. In this embodiment, the working frequencies of the line laser scanner and the working light source are controlled by a high-frequency controller, so that the two devices operate alternately and provide light for the linear array camera alternately. The high-frequency controller outputs a high-frequency signal to the line laser scanner at a first working frequency, and the line laser scanner performs data acquisition at the first working frequency and provides light for the linear array camera; when the line laser scanner is not performing data acquisition, at this time the line laser scanner is not operating, and the working light source provides light for the linear array camera. In a specific application, the high-frequency controller alternately sends high-frequency signals to the linear array camera and the line laser scanner, and the linear array camera and the line laser scanner acquire data according to the high-frequency signals. The working frequency of the high-frequency controller is an integer multiple of the working frequency of the line laser scanner. Assuming that the line laser scanner acquires data at a first working frequency f, the working frequency of the high-frequency controller is:
[0105] F = Nf
[0106] where N is an integer not less than 2, and f is the working frequency of the line laser scanner.
[0107] Preferably, a dedicated controller can be used to synchronously control the movement of the working light source, the linear array camera, and the line laser scanner. The working light source is located between the areas formed by the linear array camera, the line laser scanner, and the collection line. The positional relationship among the working light source, the linear array camera, and the line laser scanner is as shown in the accompanying drawings of the specification Figure 2 as shown.
[0108] This embodiment provides a surface detection method that realizes surface detection by combining a linear array camera and a line laser scanner. It can simultaneously take into account the information processing of two-dimensional and three-dimensional information and can perform detection in a moving state, achieving a better surface detection effect. The linear array camera and the line laser scanner are integrated at the same position, occupying less space. Compared with the traditional face-to-face method, the row-to-row method adopted in this embodiment greatly reduces the amount of calculation and the calculation difficulty, can significantly reduce the calculation time in actual calculation, and has a better simplified effect.
[0109] Embodiment 2
[0110] This embodiment proposes a surface detection system, which adopts a surface detection method proposed in Embodiment 1. The schematic diagram of the modules of the surface detection system is as shown in the appended Figure 4 description. The specific solution is as follows:
[0111] A surface detection system includes a line array camera 1, a line laser scanner 2, a working light source 3, a high-frequency controller 5, and a computing terminal 4. The line array camera 1 is used for line scanning the surface to be detected to obtain a first data set; the line laser scanner 2 is used for line scanning the surface to be detected to obtain a second data set. Multiple control units are set in the controller 5 to implement controls with different functions.
[0112] Among them, the line array camera 1 and the line laser scanner 2 can perform synchronous scanning or asynchronous scanning, and the scanning area each time can be the same or different. In this embodiment, the line array camera 1 and the line laser scanner 2 simultaneously scan the same position on the surface to be detected, that is, the scanning is synchronous and the scanning area is synchronous.
[0113] Specifically, the line array camera 1 and the line laser scanner 2 simultaneously scan the same position on the surface to be detected. In this embodiment, the line array camera 1 and the line laser scanner 2 are fixed to the same working position, and can detect the same area and collect data simultaneously. Since the working principles of both the line array camera 1 and the line laser scanner 2 are to collect data of one line each time, the two sensors can simultaneously detect the data on the same line on the plane. The line array camera 1 emits a first scanning line to the surface to be detected of the detection object, and line scans the surface to be detected to obtain a first data set; the line laser scanner 2 emits a second scanning line to the surface to be detected and line scans the surface to be detected to obtain a second data set. Exemplarily, the side view of the motion state during scanning is shown in the appended Figure 2 description. Among them, the dotted line represents the plane where the scanning areas of the lines of the line array camera 1 and the line laser scanner 2 are located. It can be seen from the attached drawing that the first scanning line and the second scanning line overlap, and this intersection line is the acquisition line. By adjusting the position, the acquisition line is on the surface to be detected, so as to enable the line array camera 1 and the line laser scanner 2 to simultaneously collect the data on the same straight line on the surface to be detected. There is relative motion between the acquisition line and the surface to be detected, including both the acquisition line moving, the surface to be detected not moving and the acquisition line moving at a uniform speed relative to the surface to be detected, and the surface to be detected moving, the acquisition line not moving and the surface to be detected moving at a uniform speed relative to the surface to be detected.
[0114] Among them, both the first data set and the second data set are two-dimensional data sets, with equal number of columns, unequal number of rows and a linear proportional relationship;
[0115] A computing terminal 4 is configured to insert a third data set into a second data set based on a linear proportional relationship for data expansion, so that the number of rows of the expanded second data set is equal to that of the first data set; and analyze the correlation between the first data set and the expanded second data set through a preset algorithm to implement surface detection of the surface to be detected.
[0116] Among them, the third data set is a two-dimensional data set and has the same number of columns as the second data set. The process of obtaining the third data set includes: setting a two-dimensional data set as the initial data set, where the number of rows of the initial data set is one less than the numerical value of the linear proportional relationship and the number of columns is the same as that of the second data set; solving the first derivative through the luminance change corresponding to the initial data set, so the reciprocal of the first derivative of the initial data set represents the slope change of the data points in the last column and the last row of the initial data set; based on the slope change, calculating the data change speed of the second data set at the interpolation points, and the obtained initial data set is the third data set.
[0117] In addition, a working light source 3 needs to be set to provide light for the line array camera 1. Due to the characteristics of the line laser scanner 2, the line laser scanner 2 can also be specifically used as a light source. In this embodiment, the high-frequency controller 5 controls the line laser scanner 2 and the working light source 3 to operate alternately to provide light for the line array camera 1 alternately. The high-frequency controller 5 controls the working frequencies of the working light source 3 and the line laser scanner 2, so that the line laser scanner 2 can provide light for the line array camera 1 when data is being collected, and the working light source 3 is used to provide light for the line array camera 1 when the line laser scanner 2 is not collecting data. The line laser scanner 2 can provide light for the line array camera 1 while collecting data, and when the line laser scanner is not collecting data, the working light source 3 is used to provide light for the line array camera 1.
[0118] In a specific application, every time the high-frequency controller 5 issues a collection signal, the line array camera 1 and the line laser scanner 2 will collect data once. The working frequency of the high-frequency controller 5 is an integer multiple of the working frequency of the line laser scanner 2. Assuming that the line laser scanner 2 collects data at the first working frequency f, the working frequency of the high-frequency controller 5 is:
[0119] F = Nf
[0120] Among them, N is an integer not less than 2, and f is the first working frequency of the line laser scanner 2.
[0121] In addition, a dedicated controller 5 can be used to perform high-frequency synchronous control on the relative movement between the surface measurement system and the surface to be detected, so that the acquisition line is always located on the surface to be detected, and the surface to be detected moves at a constant speed relative to the acquisition line. The movement speed can be adjusted according to actual applications to achieve high-speed movement, further reducing the data acquisition time. Preferably, the working light source 3 is located between the areas formed by the line array camera 1, the line laser scanner 2, and the acquisition line. The positional relationship among the working light source 3, the line array camera 1, and the line laser scanner 2 is as shown in the attached Figure 2 description. The surface detection system of this embodiment can operate in a high-frequency environment above 100KHz.
[0122] This embodiment proposes a surface detection system, which systematizes the surface detection method of Embodiment 1 to make it more practical.
[0123] The present invention provides a surface detection method and system, which realizes surface detection by combining a line array camera and a line laser scanner. It can take into account the information processing of two-dimensional information and three-dimensional information at the same time, and can perform detection in a moving state, achieving a better surface detection effect. The line array camera and the line laser scanner are integrated at the same position, occupying less space. Compared with the traditional face-to-face method, the row-to-row method adopted in this embodiment greatly reduces the calculation amount and the calculation difficulty, can significantly reduce the calculation time in actual calculation, and the simplified detection effect is better.
[0124] Those of ordinary skill in the art should understand that the above-mentioned modules or steps of the present invention can be implemented by a general computing device. They can be concentrated on a single computing device or distributed on a network composed of multiple computing devices. Optionally, they can be implemented by program codes executable by a computer device, so that they can be stored in a storage device and executed by a computing device, or they can be separately made into individual integrated circuit modules, or multiple modules or steps among them can be made into a single integrated circuit module to implement. In this way, the present invention is not limited to any specific combination of hardware and software.
[0125] Note that the above is only the preferred embodiment of the present invention and the applied technical principle. Those skilled in the art will understand that the present invention is not limited to the specific embodiments here, and various obvious changes, re-adjustments, and substitutions can be made by those skilled in the art without departing from the protection scope of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments. Without departing from the concept of the present invention, more other equivalent embodiments can be included, and the scope of the present invention is determined by the scope of the appended claims.
[0126] The above are only several specific implementation scenarios of the present invention. However, the present invention is not limited thereto, and any changes that can be conceived by those skilled in the art shall fall within the protection scope of the present invention.
Claims
1. A surface detection method, characterized in that, The following are included: The line array camera scans the surface to be detected line by line to collect the first data set, and the line laser scanner scans the surface to be detected line by line to collect the second data set. The line array camera and the line laser scanner scan the same position on the surface to be detected simultaneously. Among them, both the first data set and the second data set are two-dimensional data sets, with equal number of columns, unequal number of rows, and a linear proportional relationship. Based on the linear proportional relationship, insert the third data set into the second data set for data expansion so that the number of rows of the expanded second data set is equal to that of the first data set. Among them, the third data set is a two-dimensional data set and has the same number of columns as the second data set. Analyze the correlation between the first data set and the expanded second data set through a preset algorithm to achieve surface detection of the surface to be detected. Among them, the acquisition process of the third data set includes: Set a two-dimensional data set as the initial data set. The number of rows of the initial data set is the numerical value of the linear proportional relationship minus one, and the number of columns is the same as that of the second data set. Solve the first derivative through the luminance change corresponding to the initial data set. The reciprocal of the first derivative of the initial data set represents the slope change of the data points in the last column and the last row of the initial data set. Based on the slope change, calculate the data change speed at the interpolation points of the second data set. The obtained initial data set is the third data set.
2. The surface detection method according to claim 1, wherein The first data set Da is {Da(a, x)|a = 1, 2,...m, x = 1, 2,...N}; The second data set Dr is {Dr(b, y)|b = 1, 2,...m, y = 1, 2,...N}; Among them, x and y represent the number of columns of the data set, and x = y. a and b represent the number of rows of the data set, and a = tb, b > 1; The data set Data composed of the first data set and the second data set can be expressed as: Among them, t represents the linear proportional relationship, and N is a natural number; Insert b(t - 1)*x data points into the second data set, and expand from Dr(b, y) to Dr(tb, y).
3. The surface detection method according to claim 2, characterized in that, Let the initial data set be P(tb - r, x), r < b; The first derivative I of the initial data set x,tb,r is as follows: Among them, Da(tb, x) represents the data point at the tb-th row and the x-th column in the first dataset, Dr(tb - r, x) represents the data point at the (tb - r)-th row and the x-th column in the second dataset, and the reciprocal of I x,tb,r represents the slope change of the data point at the x-th row and the (tb - r)-th column in the initial dataset; Based on the slope change, calculate the data change speed at the interpolation points to obtain the initial data set as: P(tb-r, x) = I x,tb,r * |Dr(tb, x) - Dr(tb - b, x)| where I x,tb,r is the first derivative of the initial data set, r is an intermediate value, Da(tb - r, x) represents the data point at the (tb - r)-th row and the x-th column in the first data set, Da(tb, x) represents the data point at the tb-th row and the x-th column in the first data set, Dr(tb - r, x) represents the data point at the (tb - r)-th row and the x-th column in the second data set, Dr(tb, x) represents the data point at the tb-th row and the x-th column in the second data set, and P(tb - r, x) represents the third data set.
4. The surface detection method according to claim 1, characterized in that It also includes a high-frequency controller; The scanning areas of the line array camera and the line laser scanner form a collection line on the surface to be detected; Control the movement of the surface to be detected through the high-frequency controller so that the surface to be detected moves at a constant speed relative to the collection line.
5. The surface detection method according to claim 4, wherein It also includes a working light source; The high-frequency controller outputs a high-frequency signal to the line laser scanner at the first working frequency. The line laser scanner performs data acquisition at the first working frequency and provides a light source for the line array camera; When the line laser scanner is not performing data acquisition, provide a light source for the line array camera through the working light source.
6. The surface detection method according to claim 5, wherein The working frequency of the high-frequency controller is: F = Nf Wherein, N is an integer not less than 2, f is the first operating frequency, and F is the operating frequency of the high-frequency controller; The data volume collected by the line laser scanner is: Wherein, M is an integer not less than 2, t is the data volume collected by the line array camera, and T is the data volume collected by the line laser scanner.
7. A surface detection system, characterized in that, It includes a line array camera, a line laser scanner, and a computing terminal; The line array camera and the line laser scanner simultaneously scan the same position on the surface to be detected; The line array camera is used to line-scan the surface to be detected and collect a first data set; The line laser scanner is used to line-scan the surface to be detected and collect a second data set; Wherein, both the first data set and the second data set are two-dimensional data sets, with equal number of columns, unequal number of rows, and a linear proportional relationship; The computing terminal is used to insert a third data set into the second data set for data expansion based on the linear proportional relationship, so that the number of rows of the expanded second data set is equal to that of the first data; analyze the correlation between the first data set and the expanded second data set through a preset algorithm to achieve surface detection of the surface to be detected; Wherein, the third data set is a two-dimensional data set and has the same number of columns as the second data set; the acquisition process of the third data set includes: Set a two-dimensional data set as the initial data set, the number of rows of the initial data set is one less than the numerical value of the linear proportional relationship, and the number of columns is the same as the number of columns of the second data set; Solve the first derivative through the luminance change corresponding to the initial data set, so the reciprocal of the first derivative of the initial data set represents the slope change of the data points in the last column and the last row of the initial data set; Based on the slope change, by calculating the data change speed of the second data set at the interpolation points, the obtained initial data set is the third data set.
8. The surface inspection system according to claim 7, characterized in that, It further includes a working light source and a high-frequency controller, and the high-frequency controller is respectively connected to the working light source, the line laser scanner, and the line array camera; The high-frequency controller is used to control the working light source and the line laser scanner, so that the line laser scanner can provide light for the line array camera when data is being collected, and use the working light source to provide light for the line array camera when the line laser scanner is not collecting data; The scanning areas of the line array camera and the line laser scanner form a collection line on the surface to be detected; the high-frequency controller is further used to control the movement of the surface to be detected, so that the surface to be detected moves uniformly relative to the collection line.
Citation Information
Patent Citations
Surface detection device
CN216449449U