Road pavement construction quality detection method and system
By calculating the shadow probability parameters and degree of damage coefficient in the grayscale image of the road surface, distinguishing the shadow area and defect area, the problem of shadow misidentification under the influence of light is solved, and the accuracy of road surface construction quality inspection is improved.
Patent Information
- Application Number
- CN202411273436.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-12
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2044-09-12
AI Technical Summary
In road construction quality inspection, the shaded area caused by lighting factors is similar to the gray value of the defective area, which may cause the shadow area to be misidentified as a defective area, affecting the accuracy of the detection results.
By collecting the grayscale images and sun positions on the road surface, using threshold segmentation to obtain the suspected defect areas, calculate the collinear factor and shadow probability parameters of the grayscale gradient characteristics, filter out the shadow areas, and destroy the grayscale gradient uniformity in the shadow areas according to the grayscale gradient uniformity in the shadow areas Degree obtains the degree of damage coefficient, and then determines the defect area in the shadowed area.
It improves the accuracy of identification of defective areas in road surface images, enhances the accuracy of road construction quality inspection, and reduces the possibility of misidentification of shadowed areas.
Smart Images

Figure CN118781121B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image processing, and in particular to a method and system for detecting road pavement construction quality. Background Art
[0002] During the road construction process, due to factors such as concrete material shrinkage, temperature stress, and uneven roadbed settlement, cracks, broken boards, and depressions may appear on the road surface; these road surface quality problems not only affect the driving safety and riding comfort of vehicles, but also may accelerate the destruction of the road surface structure and affect the service life of the road surface if they are not discovered in time. Therefore, in order to ensure road traffic safety, it is necessary to test the road surface construction quality.
[0003] When performing defect detection on road pavement construction quality, the threshold segmentation result of the road pavement image is usually directly used as the area with construction quality defects; however, due to the influence of lighting factors, the obstructions on both sides of the road will form a shadow area on the road surface, and the grayscale value of the shadow area is similar to the defect area, so the shadow area may be mistakenly identified as a defect area, thereby affecting the accuracy of the road construction quality detection results. Summary of the invention
[0004] The invention provides a road pavement construction quality detection method and system to solve the existing problems.
[0005] A road pavement construction quality detection method and system of the present invention adopts the following technical solutions:
[0006] An embodiment of the present invention provides a method for detecting road pavement construction quality, the method comprising the following steps:
[0007] Collecting the road surface grayscale image of the road to be inspected, the longitude and latitude of the road surface grayscale image, and the sun position at the time of collecting the road surface grayscale image;
[0008] The suspected defect area in the road grayscale image is obtained by using threshold segmentation; the collinearity factor of the grayscale gradient feature of the suspected defect area is obtained according to the gradient vector of the pixel points in the suspected defect area and the line projection of the center points of the sun and shadow areas; the suspected defect area is divided into several sub-blocks according to the grayscale gradient direction of the suspected defect area, and the grayscale gradient degree of the suspected defect area is obtained through the average grayscale difference of adjacent sub-blocks; the shadow probability parameter of the suspected defect area is obtained according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, and the shadow area is screened out according to the shadow probability parameter of the suspected defect area; the damage degree coefficient of all pixel points in the shadow area is obtained according to the degree of damage of the defect area in the shadow area to the uniformity of the grayscale gradient inside the shadow area;
[0009] The independent defect area in the suspected defect area is obtained, and the defect area in the shadow area is obtained according to the damage degree coefficient of the pixel points in the shadow area. Finally, the road surface quality is inspected.
[0010] Preferably, the method of obtaining the suspected defect area in the road surface grayscale image by using threshold segmentation includes the following specific methods:
[0011] Adaptive threshold segmentation is used to segment the pavement grayscale image to obtain the segmentation threshold of the pavement grayscale image. The area formed by the pixels in the pavement grayscale image whose grayscale value is less than the segmentation threshold is recorded as the suspected defect area.
[0012] Preferably, the collinearity factor of the grayscale gradient feature of the suspected defect area is obtained according to the gradient vector of the pixel points in the suspected defect area and the line projection of the center points of the sun and shadow areas, and the specific method includes:
[0013] The Sobel operator is used to obtain the gradient vector of each pixel point in any suspected defect area, and the gradient vectors of all pixel points in any suspected defect area are accumulated to obtain the gradient change degree of the suspected defect area, and the unit vector of the gradient change degree is recorded as the unit direction vector of the grayscale gradient of the suspected defect area;
[0014] Constructing a 3D coordinate system , the central pixel point of the road grayscale image is taken as the origin of the three-dimensional coordinate system, where represents the origin of the three-dimensional coordinate system, The axis represents the horizontal axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system; a sun reference point is constructed in the three-dimensional coordinate system according to the sun position;
[0015] Define the line connecting the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system. The projection on the plane is the first projection of the suspected defect area. The first projection vector is constructed based on the first projection. The length of the first projection is used as the modulus length of the first projection vector. The direction from the coordinates on the plane to the coordinates of the center point of the suspected defect area is taken as the direction of the first projection vector, and the unit vector of the first projection vector is taken as the unit direction vector of the first projection of the suspected defect area;
[0016] For The specific calculation method of the collinearity factor of the grayscale gradient characteristics of a suspected defect area is:
[0017]
[0018] In the formula, Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; The unit direction vector representing the grayscale gradient of the k-th suspected defect area; Indicates The unit direction vector of the first projection of the suspected defect area; Represents the cosine function.
[0019] Preferably, the specific method of constructing a solar reference point in a three-dimensional coordinate system according to the solar position is:
[0020] The SunCalc tool is used to calculate the azimuth and altitude of the sun relative to the ground by combining the longitude and latitude of the road grayscale image and the time when the road grayscale image was collected. The azimuth refers to the angle of the sun relative to the north, and the altitude refers to the angle of the sun relative to the horizon. The azimuth and altitude are used to convert the sun's position into coordinates in a three-dimensional coordinate system. The longitude and latitude of the suspected defect area are converted into a position in a three-dimensional coordinate system. The three-dimensional coordinate position of the sun is combined with the three-dimensional coordinate position of the road surface to determine the position of the sun reference point in the three-dimensional coordinate system.
[0021] Preferably, the method of dividing the suspected defect area into a plurality of sub-blocks according to the grayscale gradient direction of the suspected defect area, and obtaining the grayscale gradient degree of the suspected defect area by the average grayscale difference of adjacent sub-blocks includes the following specific methods:
[0022] Build a The sliding window is the preset side length of the sliding window, and the sliding step size of the sliding window is set to , along the direction of the first projection vector, the suspected defect area is traversed through the sliding window, and the area contained in the sliding window at each position in the traversal process is recorded as a sub-block, and a plurality of sub-blocks are obtained;
[0023] Get the mean grayscale value of all pixels in each sub-block in the suspected defect area, record it as the grayscale mean of the sub-block, make a difference between the grayscale means of each adjacent sub-block in the suspected defect area, and then take the average of all differences to get the grayscale gradient degree inside the suspected defect area; The specific calculation method of the grayscale gradient degree inside a suspected defect area is:
[0024]
[0025] In the formula, Indicates The grayscale gradient inside the suspected defect area; Indicates The number of sub-blocks after the suspected defect area is divided; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Represents the absolute value symbol.
[0026] Preferably, the method of obtaining the shadow probability parameter of the suspected defect area according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, and screening out the shadow area according to the shadow probability parameter of the suspected defect area includes the following specific methods:
[0027] Define the Euclidean distance between the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system as the first distance of the suspected defect area;
[0028] For The specific calculation method of the shadow probability parameter of a suspected defect area is:
[0029]
[0030] In the formula, Indicates Shadow probability parameter of the suspected defect area; Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; A data set representing the first distances of all suspected defect areas in the road grayscale image; A data set representing the grayscale gradient inside all suspected defect areas in the road to be detected; Indicates that the roads to be detected are A data set consisting of the first distances of all suspected defect areas outside the suspected defect area; Indicates that the roads to be detected are A data set consisting of the grayscale gradients inside all suspected defect areas outside a suspected defect area; express and The Pearson correlation coefficient, express and Pearson correlation coefficient of Used to describe the The linear relationship between the gray gradient degree of the suspected defect area, the suspected defect area and the sun position; represents an exponential function with a natural constant as base; represents the linear normalization function;
[0031] For suspected defect area, if the The shadow probability parameter of the suspected defect area is greater than the preset parameter , then the The suspected defect area is marked as the shaded area.
[0032] Preferably, the method of obtaining the damage degree coefficient of all pixels in the shadow area according to the damage degree of the defect area in the shadow area to the uniformity of the grayscale gradient inside the shadow area includes the following specific methods:
[0033] For any shadow area, the line segments in the shadow area that are parallel to the vector direction corresponding to the first projection vector of the shadow area and formed by a number of pixels are recorded as parallel pixel lines, and the width of each parallel pixel line is 1 pixel;
[0034] Take any pixel point on any parallel pixel line in the current shadow area as the segmented pixel point on the parallel pixel line, divide the parallel pixel line into two segments, and define the pixel points with grayscale values higher than the segmented pixel point on the side close to the occluder and the pixel points with grayscale values lower than the segmented pixel point on the side far from the occluder as reverse order points;
[0035] For In the shadow area The specific calculation method of the damage degree coefficient is:
[0036]
[0037] In the formula, Indicates the rth shaded area The damage degree coefficient; Indicates the rth shaded area Gray value of express The number of reverse order points on the parallel pixel line where the pixel point is located; express The first pixel on the parallel pixel line where the pixel point is located Gray value of the reverse order points; express The vertical damage factor; express Parallel destruction factor; Used to describe the degree of destruction of uniformity of grayscale gradient inside the shadow area; represents the linear normalization function; Represents the absolute value symbol.
[0038] Preferably, the specific method for obtaining the vertical damage factor is:
[0039] For any shadow area, the direction perpendicular to the direction corresponding to the first projection vector of the shadow area is recorded as the projection vertical direction, and the line segment formed by a number of pixel points in the shadow area parallel to the projection vertical direction is recorded as a vertical column pixel line; the width of each vertical pixel line is 1 pixel point;
[0040] For In the shadow area The specific calculation method of the vertical damage factor is:
[0041]
[0042] In the formula, Indicates In the shaded area The vertical destruction factor of each pixel; Indicates The shadow probability parameter of the shadow area; Indicates In the shadow area Gray value of pixel; Indicates In the shadow area The grayscale mean of the vertical column pixel line where the pixel point is located.
[0043] Preferably, the method of obtaining an independent defect area in the suspected defect area, obtaining the defect area in the shadow area according to the damage degree coefficient of the pixel points in the shadow area, and finally performing quality inspection on the road surface includes the following specific methods:
[0044] Preset second threshold , the damage degree in the shadow area is greater than The pixel points are recorded as defective pixels; then the CCL algorithm is used to obtain the connected domain for all defective pixels in the shadow area, and the obtained connected domain is recorded as the defective area in the shadow area;
[0045] The road pavement construction quality is judged based on the size of defective areas and independent defective areas.
[0046] An embodiment of the present invention provides a road pavement construction quality detection system, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any one of the steps of the road pavement construction quality detection method when executing the computer program.
[0047] The beneficial effects of the technical solution of the present invention are as follows: the present invention first performs threshold segmentation on the road pavement image to obtain all suspected defect areas on the road to be detected; screens out the shadow area in the suspected defect area according to the internal grayscale gradient characteristics of the shadow area on the road pavement; obtains the damage degree coefficient of the pixel point through the degree of damage to the grayscale gradient uniform characteristics of any pixel point in the shadow area; further determines the defective pixel points in the shadow area according to the damage degree coefficient; performs defect connected domain detection on all defective pixel points in the shadow area through a connected domain detection algorithm to obtain the defective area in the shadow area; then obtains the independent defective area except the shadow area in the suspected defective area; judges the road pavement construction quality according to all the defective areas in the road to be detected obtained; improves the recognition accuracy of the defective area in the pavement image, and further improves the accuracy of the road pavement construction quality detection results. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0049] Figure 1 The present invention is a flow chart of the steps of a road pavement construction quality detection method. DETAILED DESCRIPTION
[0050] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the following is a detailed description of a road pavement construction quality detection method and system proposed by the present invention, its specific implementation method, structure, features and effects, in conjunction with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.
[0051] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.
[0052] The specific scheme of a road pavement construction quality detection method and system provided by the present invention is described in detail below with reference to the accompanying drawings.
[0053] See also Figure 1 , which shows a flow chart of a method for detecting road pavement construction quality provided by an embodiment of the present invention, the method comprising the following steps:
[0054] Step S001: Collect a road surface grayscale image of the road to be inspected, the longitude and latitude of the road surface grayscale image, and the sun position at the time of collecting the road surface grayscale image.
[0055] It should be noted that during the construction process, the road surface will have defects such as dents and cracks, which will have an adverse effect on the stability of the road surface and will also cause safety hazards to vehicles on the road. Therefore, it is necessary to test the road surface quality after the road construction is completed to ensure road traffic safety.
[0056] Specifically, in order to implement a road pavement construction quality detection method proposed in this embodiment, it is first necessary to collect a road pavement image and the three-dimensional coordinate position of the sun at the time of collecting the image. The specific process is as follows:
[0057] After the construction is completed, a camera is installed above the road section to collect road pavement images, and the collected road pavement images are transmitted to the construction quality inspection center for analysis. First, the collected road pavement images are grayed to obtain road pavement grayscale images, and then the longitude and latitude of the road pavement image position are obtained; at the same time, the SunCalc software is used to record the sun position at the time of collecting the road pavement image. In addition, the camera shooting time period set in this embodiment is 8:00-18:00 every day, and the shooting time interval T=4 is described in this way, where T is hours, T can be adjusted according to actual conditions, and this embodiment does not specifically limit it.
[0058] So far, the road surface grayscale image, the longitude and latitude of the road surface image position, and the three-dimensional coordinate position of the sun at the time of shooting are obtained through the above method.
[0059] Step S002: using threshold segmentation to obtain the suspected defect area in the grayscale image of the road surface; obtaining the collinearity factor of the grayscale gradient feature of the suspected defect area according to the gradient vector of the pixel points in the suspected defect area and the line projection of the center points of the sun and shadow areas; dividing the suspected defect area into a number of sub-blocks according to the grayscale gradient direction of the suspected defect area, and obtaining the grayscale gradient degree of the suspected defect area through the average grayscale difference of adjacent sub-blocks; obtaining the shadow probability parameter of the suspected defect area according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, and filtering out the shadow area through the shadow probability parameter of the suspected defect area; obtaining the damage degree coefficient of all pixels in the shadow area according to the degree of damage to the uniformity of the grayscale gradient inside the shadow area caused by the defect area in the shadow area.
[0060] It should be noted that under lighting conditions, obstructions on both sides of the road will form shadow areas on the road surface; these shadow areas have similar grayscale values to the road surface defect areas, so after threshold segmentation, the shadow areas and road surface defect areas may be mistakenly classified as the same category, so it is necessary to analyze the suspected defect areas obtained after segmentation, and determine the shadow areas in the suspected defect areas through the grayscale gradient characteristics inside the shadow areas; when there are defect areas in the shadow areas, the destruction degree coefficient of each pixel in the shadow area is obtained based on the feature that the pixels in the defect area will destroy the uniformity of the grayscale gradient inside the shadow area.
[0061] Step S1: Using threshold segmentation to obtain the suspected defect area in the road surface grayscale image.
[0062] It should be noted that the defective area is darker in color and has a lower grayscale value than the normal area. When the obstructions on both sides of the road form a shadow area on the road surface, the grayscale value in the area is also low and close to the defective area. Therefore, when using threshold segmentation to segment the road grayscale image, the defective area and the shadow area with similar grayscale values may be divided into the same area, and the probability of defects in this area is higher than that in other areas.
[0063] Specifically, the road surface grayscale image is segmented using adaptive threshold segmentation to obtain a segmentation threshold of the road surface grayscale image, and an area formed by pixels in the road surface grayscale image whose grayscale values are less than the segmentation threshold is recorded as a suspected defect area.
[0064] It should be further explained that adaptive threshold segmentation is a well-known technology in image processing, and thus it will not be described in detail in this embodiment.
[0065] So far, all the suspected defect areas in the road surface grayscale image are obtained through the above method.
[0066] Step S2: According to the gradient vector of the pixel points in the suspected defect area and the line projection of the center points of the sun and shadow areas, the collinearity factor of the grayscale gradient feature of the suspected defect area is obtained; the suspected defect area is divided into several sub-blocks according to the grayscale gradient direction of the suspected defect area, and the grayscale gradient degree of the suspected defect area is obtained through the average grayscale difference between adjacent sub-blocks; according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, the shadow probability parameter of the suspected defect area is obtained, and the shadow area is screened out through the shadow probability parameter of the suspected defect area.
[0067] It should be noted that the shadow area is affected by the light and has a smaller grayscale value, which causes the shadow area to be mistakenly segmented during threshold segmentation because its grayscale value is similar to the defect area. Therefore, in the suspected defect area obtained after threshold segmentation, the defect area has two forms: one is the defect area contained in the shadow area, and the other is an independent defect area that is not in the shadow area. Since the shadow area has a grayscale gradient feature, the shadow area in the suspected defect area is screened according to this feature; the shadow area is formed by the illumination of the light source, so the grayscale value of the pixel points inside the area presents a uniform gradient characteristic. When there is a defect in the shadow area, the uniformity of the grayscale gradient inside the shadow area will be destroyed. Therefore, the degree of destruction of the grayscale gradient uniformity of the pixel points in the shadow area is used to determine the degree of destruction of the pixel points in the shadow area.
[0068] It should be further explained that the intensity of the incident light received by the shadow area will change with the distance from the obstruction. The closer to the obstruction, the greater the degree of light blocking, the less light the road receives, and the lower the grayscale value; the farther away from the obstruction, the degree of light blocking gradually decreases, the road receives more light, and the grayscale value gradually increases; therefore, the shadow area has a grayscale gradient feature. At the same time, the projection of the grayscale gradient direction of the shadow area is collinear with the projection in the direction of the line connecting the sun and the center of the shadow area, so the collinearity factor of the grayscale gradient feature of the defect suspected area is constructed based on the said feature.
[0069] Specifically, construct a three-dimensional coordinate system ,in represents the origin of the three-dimensional coordinate system, The axis represents the horizontal axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system; the central pixel point of the road surface grayscale image is taken as the origin of the three-dimensional coordinate system, and is converted into a point of the three-dimensional coordinate system by projection according to the longitude and latitude of the suspected defect area in the geographic coordinate system; the coordinates of the sun position recorded by the SunCalc tool are used to construct a sun reference point in the three-dimensional coordinate system according to the relative direction and position of the sun to the current road surface shooting time and the longitude and latitude of the road surface.
[0070] As an embodiment, a specific method for constructing a solar reference point is as follows: using the SunCalc tool in combination with the longitude and latitude of the road surface image and the time when the road surface image was collected, calculate the azimuth and altitude of the sun relative to the ground, where the azimuth refers to the angle of the sun relative to the north, and the altitude refers to the angle of the sun relative to the horizon; using the azimuth and altitude, convert the solar position into coordinates in three-dimensional space, which can usually be represented by a spherical coordinate system or a rectangular coordinate system; converting the longitude and latitude coordinates of the road surface into a position in a three-dimensional coordinate system; combining the three-dimensional coordinate position of the sun with the three-dimensional coordinate position of the road surface to determine the position of the solar reference point in the three-dimensional coordinate system.
[0071] It should be noted that the SunCalc tool is an OSINT (Open source intelligence) tool for calculating the sun's position, sunrise and sunset times, and sun shadows, so it is not described in detail in this embodiment.
[0072] Define the line connecting the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system. The projection on the plane is the first projection of the suspected defect area. The first projection vector is constructed based on the first projection. The length of the first projection is used as the modulus length of the first projection vector. The direction from the coordinates on the plane to the coordinates of the center point of the suspected defect area is taken as the direction of the first projection vector, and the unit vector of the first projection vector is taken as the unit direction vector of the first projection of the suspected defect area.
[0073] It should be noted that when there are no defects in the shadow area, the gradient directions of the pixels in the area are basically consistent; when there is a defective area in the shadow area, the gradient direction of the pixels in the defective area may be inconsistent with the gradient direction of the pixels in the non-defective area, but generally the defective area only occupies a small part of the shadow area, so the direction of the gradient vector after the gradient vectors of each pixel in the shadow part are added together can roughly reflect the gradient direction of the entire shadow area.
[0074] The specific method for obtaining the unit direction vector of the grayscale gradient of the suspected defect area is: using the Sobel operator to obtain the gradient vector of each pixel point in any suspected defect area, accumulating the gradient vectors of all pixel points in any suspected defect area, and obtaining the gradient change degree of the suspected defect area, and recording the unit vector of the gradient change degree as the unit direction vector of the grayscale gradient of the suspected defect area.
[0075] The unit direction vector of the grayscale gradient of any suspected defect area and the unit direction vector of the first projection of any suspected defect area are obtained to construct the collinearity factor of the grayscale gradient feature of the suspected defect area; the calculation expression of the collinearity factor of the grayscale gradient feature of any suspected defect area is:
[0076]
[0077] In the formula, Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; The unit direction vector representing the grayscale gradient of the k-th suspected defect area; Indicates The unit direction vector of the first projection of the suspected defect area; Represents the cosine function.
[0078] It should be further explained that It is the cosine value of the angle between the unit direction vector of the grayscale gradient in the suspected defect area and the unit direction vector of the first projection. The larger the cosine value is, the smaller the angle between the two vectors is, indicating that the two vectors tend to be collinear to a greater extent in direction, and the greater the probability that the kth suspected defect area is a shadow area.
[0079] It should be noted that, based on the characteristic of uniform grayscale gradient inside the shadow area, the relationship between the grayscale gradient degree in the shadow area and the center of the shadow area and the position of the sun is analyzed. When the shadow area is far away from the sun, the light contrast increases due to the less illumination of the obstruction, making the grayscale gradient degree inside the shadow area more significant (the shadow is darker near the obstruction), that is, the grayscale change level inside the shadow area is more distinct; conversely, when the shadow area is close to the sun, the light is stronger, resulting in a lighter shadow color, the grayscale gradient degree inside the shadow area is not obvious, and the grayscale change level is relatively blurred. Therefore, there is a positive linear relationship between the grayscale gradient degree of the shadow area and the shadow area and the position of the sun, and the shadow probability parameter of the suspected defect area is constructed based on this feature.
[0080] It should be noted that in the first projection direction of the shadow area, the grayscale gradient of the shadow area is more significant; therefore, for each suspected defect area, its area is divided into blocks in the projection direction, and then the grayscale gradient inside the suspected defect area is obtained.
[0081] Specifically, build a Sliding window of size, is the preset side length of the sliding window, and the sliding step size of the sliding window is set to ,in The value of can be adjusted according to the actual situation. This example does not make a hard requirement. In the following description, the suspected defect area is traversed through the sliding window along the direction of the first projection vector, and the area contained in the sliding window at each position in the traversal process is recorded as a sub-block, and several sub-blocks are obtained. Therefore, the grayscale value average of all pixels in each sub-block in the suspected defect area is obtained, which is recorded as the grayscale average of the sub-block. The grayscale averages of adjacent sub-blocks in the suspected defect area are subtracted, and then all differences are averaged to obtain the grayscale gradient degree inside the suspected defect area. Then, The calculation expression of the grayscale gradient degree inside a suspected defect area is:
[0082]
[0083] In the formula, Indicates The grayscale gradient inside the suspected defect area; Indicates The number of sub-blocks after the suspected defect area is divided; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Represents the absolute value symbol.
[0084] Define the Euclidean distance between the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system as the first distance of the suspected defect area. In this embodiment, the first distance of the suspected defect area is used to characterize the relative distance between the shadow area and the sun in space. Obtain the first The first distance and the The grayscale gradient of the suspected defect area is The calculation expression of the shadow probability parameter of a suspected defect area is as follows:
[0085]
[0086] In the formula, Indicates Shadow probability parameter of the suspected defect area; Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; A data set representing the first distances of all suspected defect areas in the road grayscale image; A data set representing the grayscale gradient inside all suspected defect areas in the road to be detected; Indicates that the roads to be detected are A data set consisting of the first distances of all suspected defect areas outside the suspected defect area; Indicates that the roads to be detected are A data set consisting of the grayscale gradients inside all suspected defect areas outside a suspected defect area; express and The Pearson correlation coefficient, express and Pearson correlation coefficient of Used to describe the The linear relationship between the gray gradient degree of the suspected defect area, the suspected defect area and the sun position; represents an exponential function with a natural constant as base; represents the linear normalization function.
[0087] It should be further explained that the grayscale gradient degree inside the shadow area is in a positive linear relationship with the first distance, that is, as the first distance increases or decreases, the grayscale gradient degree inside the shadow area increases or decreases accordingly. and The Pearson coefficient and and The greater the difference between the Pearson coefficients, the greater the positive correlation between the first distance of the current suspected area and the grayscale gradient, and the greater the probability that the suspected defect area is a shadow area. For the The collinearity factor of the grayscale gradient characteristics of the suspected defect area is used as the confidence value of the shadow probability parameter of the suspected defect area. The larger it is, the more trustworthy the shadow probability parameter is, and vice versa.
[0088] Finally, the shadow probability parameters of all suspected defect areas in the road to be detected are obtained. When the shadow probability parameter of the suspected defect area is greater than the preset first threshold When , the probability that the suspected defect area is a shadow area is greater, so the area is judged to be a shadow area.
[0089] It should be further explained that, in this embodiment, a threshold is given , all suspected defect areas in the road to be inspected are screened for shadow areas; in addition, the first threshold is preset based on experience , can be adjusted according to actual conditions, and this embodiment does not make any specific limitation.
[0090] So far, all shadow areas in the suspected defect area are obtained through the above method.
[0091] Step S3: Obtain damage degree coefficients of all pixels in the shadow area according to the degree to which the defect area in the shadow area damages the uniformity of grayscale gradient inside the shadow area.
[0092] It should be noted that when the light passes through the obstruction, it will gradually attenuate, so the shadow area formed has a certain grayscale gradient uniformity, that is, the grayscale value of the pixel points in the shadow area gradually and evenly increases from the side close to the obstruction to the side far from the obstruction. If there is no defect in the shadow area, the grayscale value of each pixel point in the shadow area along the direction perpendicular to the light (that is, perpendicular to the direction of the line connecting the sun's rays and the shadow area) should be approximately equal, that is, the grayscale gradient uniformity in the vertical direction of the light is satisfied; in the parallel direction of the projection of the line connecting the shadow area and the sun's rays on the road surface, the grayscale value of the pixel points in the shadow area from near to far from the obstruction in the parallel direction presents a uniform increase feature, that is, the grayscale gradient uniformity in the parallel direction of the projection is satisfied. If there is a defect in the shadow area, the pixel points in the defective area will destroy the grayscale gradient uniformity inside the shadow area, so the destruction degree coefficient of all pixel points in the shadow area is obtained based on this feature.
[0093] Specifically, for any shadow area, the direction perpendicular to the direction corresponding to the first projection vector of the shadow area is recorded as the projection vertical direction, and the line segment formed by a number of pixel points in the shadow area that is parallel to the projection vertical direction is recorded as a vertical column pixel line; the line segment formed by a number of pixel points in the shadow area that is parallel to the vector direction corresponding to the first projection vector of the shadow area is recorded as a parallel pixel line. The width of each vertical pixel line and parallel pixel line is preset to 1 pixel.
[0094] It should be noted that if there are no defects inside the shadow area, the grayscale values of each pixel on any vertical column pixel line in the area are approximately equal. When there are defects inside the shadow area, there is a large difference between the grayscale value of the pixel at the defect and the grayscale mean value of the vertical column pixel line where the pixel is located. Therefore, the difference between the grayscale value of any pixel and the grayscale mean value of the vertical column pixel line where the pixel is located is used to characterize the degree of damage to the uniformity of grayscale gradient in the vertical direction of illumination in the shadow area by the pixel.
[0095] The calculation expression of the vertical damage factor of any pixel in the shadow area is:
[0096]
[0097] In the formula, Indicates In the shaded area The vertical destruction factor of each pixel; Indicates The shadow probability parameter of the shadow area; Indicates In the shadow area Gray value of pixel; Indicates In the shadow area The grayscale mean of the vertical column pixel line where the pixel point is located.
[0098] It should be noted that Represents the shadow probability parameter of the r-th shadow area. This parameter can be used as a confidence parameter for the vertical damage factor of the pixel in the shadow area. The larger the shadow probability parameter of the shadow area where the current pixel is located, the higher the vertical damage degree of the pixel. If the vertical damage factor of the pixel in the r-th shadow area is larger, it means that the defect degree of the pixel is greater.
[0099] If there is no defect in the shadow area, the grayscale value of the pixels on any parallel pixel line in the area increases uniformly from near to far from the occluder. When there is a defect in the shadow area, for any pixel on any parallel pixel line in the shadow area, the more pixels with grayscale values greater than the pixel on the parallel pixel line close to the occluder, the greater the probability that the pixel is a defective pixel; the more pixels with grayscale values less than the pixel on the side far from the occluder, the greater the probability that the pixel is a defective pixel.
[0100] Specifically, any pixel point on any parallel pixel line in the current shadow area is taken as a segmented pixel point on the parallel pixel line, and the parallel pixel line is divided into two segments. The pixel points on the side close to the occluder whose grayscale value is higher than the segmented pixel point grayscale value and the pixel points on the side far from the occluder whose grayscale value is lower than the segmented pixel point grayscale value are defined as reverse points; therefore, the parallel destruction factor of the pixel can be characterized according to the number of reverse points on the parallel pixel line where the pixel to be analyzed is located in the shadow area and its grayscale characteristics. Finally, the destruction degree coefficient of each pixel point in the shadow area is obtained in combination with the vertical destruction factor of the pixel point in the shadow area. Then the calculation expression of the destruction degree coefficient of any pixel point in the shadow area is:
[0101]
[0102] In the formula, Indicates the rth shaded area The damage degree coefficient; Indicates the rth shaded area Gray value of express The number of reverse order points on the parallel pixel line where the pixel point is located; express The first pixel on the parallel pixel line where the pixel point is located Gray value of the reverse order points; express The vertical damage factor; express Parallel destruction factor; represents the linear normalization function; Represents the absolute value symbol.
[0103] It should be further explained that the sum of the grayscale value differences between any pixel point in the shadow area and all the inverse points on its parallel pixel line is larger, the less the pixel point satisfies the grayscale gradient uniformity characteristics in the parallel direction, and the greater the degree of damage in the parallel direction; at the same time, the larger the damage degree coefficient of the pixel point is, the greater the degree of damage to the grayscale gradient uniformity inside the current shadow area is, and the higher the probability that the pixel point is a defective pixel point.
[0104] So far, the damage degree coefficients of all pixels in the shadow area are obtained through the above method.
[0105] Step S003: obtaining an independent defect area in the suspected defect area, obtaining the defect area in the shadow area according to the damage degree coefficient of the pixel points in the shadow area, and finally performing quality inspection on the road surface.
[0106] It should be noted that the greater the damage degree coefficient of the pixel in the shadow area, the higher the probability that the pixel is a defective pixel; the second threshold pixel damage degree coefficient is set for judgment to obtain the defective area in the shadow area. Determine the defective area in all shadow areas, then filter out the shadow area from the suspected defect area, and the remaining area is the independent defective area.
[0107] Specifically, a second threshold is preset, and pixels in the shadow area whose degree of damage is greater than the second threshold are recorded as defective pixels; then the CCL (Connected Component Labeling) algorithm is used to obtain the connected domain for all defective pixels in the shadow area, and the obtained connected domain is recorded as the defective area in the shadow area, and the area other than the shadow area in the suspected defect area is recorded as an independent defective area.
[0108] The road pavement construction quality is judged based on the size of defective areas and independent defective areas.
[0109] Preset the second threshold based on experience , It can be adjusted according to actual conditions, and this embodiment does not make any specific limitation. The CCL algorithm is an existing image processing method, so this embodiment will not elaborate on it.
[0110] It should be noted that after obtaining all the defective areas in the road section to be inspected, the road pavement construction quality can be inspected according to the morphological characteristics of the defective areas. Since inspecting the road pavement quality according to the morphological characteristics of the defective areas is a well-known technology, it is only briefly described in this embodiment.
[0111] When the defect area is a crack, it may be caused by the shrinkage of the concrete material or the effect of temperature stress; when the defect area is a broken plate, it may be caused by the internal tensile stress of the pavement exceeding the tensile strength of the concrete; or the roadbed may be sunken due to overall or local uneven settlement. Therefore, corresponding measures need to be taken according to the cause of the defect area, such as replacing materials, changing the filling sequence, and maintaining the drainage system.
[0112] So far, all defective areas of the road surface have been obtained through the above method and their quality has been inspected.
[0113] Through the above steps, a road pavement construction quality detection method is completed.
[0114] Another embodiment of the present invention provides a road pavement construction quality detection system, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements a road pavement construction quality detection method in steps S001 to S003 when executing the computer program.
[0115] This embodiment first performs threshold segmentation on the road pavement image to obtain all suspected defect areas on the road to be detected; screens out the shadow area in the suspected defect area according to the internal grayscale gradient characteristics of the shadow area on the road pavement; obtains the damage degree coefficient of any pixel in the shadow area through the degree of damage to the grayscale gradient uniform characteristics of the area; further determines the defective pixels in the shadow area according to the damage degree coefficient; performs defect connected domain detection on all defective pixels in the shadow area through a connected domain detection algorithm to obtain the defective area in the shadow area; then obtains independent defective areas in the suspected defect area except the shadow area; determines the road pavement construction quality according to all the defective areas in the road to be detected, and further improves the accuracy of road pavement construction quality detection.
[0116] It should be noted that the The model is only used to represent negative correlation and constrain the output of the model to be in In the specific implementation, it can be replaced by other models with the same purpose. The model is described as an example without any specific limitation. is the input to the model.
[0117] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A road pavement construction quality detection method, characterized in that: The method comprises the following steps: Collecting the road surface grayscale image of the road to be inspected, the longitude and latitude of the road surface grayscale image, and the sun position at the time of collecting the road surface grayscale image; The suspected defect area in the road grayscale image is obtained by using threshold segmentation; the collinearity factor of the grayscale gradient feature of the suspected defect area is obtained according to the gradient vector of the pixel points in the suspected defect area and the line projection of the center points of the sun and shadow areas; the suspected defect area is divided into several sub-blocks according to the grayscale gradient direction of the suspected defect area, and the grayscale gradient degree of the suspected defect area is obtained through the average grayscale difference of adjacent sub-blocks; the shadow probability parameter of the suspected defect area is obtained according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, and the shadow area is screened out according to the shadow probability parameter of the suspected defect area; the damage degree coefficient of all pixel points in the shadow area is obtained according to the degree of damage of the defect area in the shadow area to the uniformity of the grayscale gradient inside the shadow area; Obtain an independent defect area in the suspected defect area, obtain the defect area in the shadow area according to the damage degree coefficient of the pixel points in the shadow area, and finally perform quality inspection on the road surface; The collinearity factor of the grayscale gradient feature of the suspected defect area is obtained according to the gradient vector of the pixel point in the suspected defect area and the line projection of the center point of the sun and shadow area, including the specific method of: The Sobel operator is used to obtain the gradient vector of each pixel point in any suspected defect area, and the gradient vectors of all pixel points in any suspected defect area are accumulated to obtain the gradient change degree of the suspected defect area, and the unit vector of the gradient change degree is recorded as the unit direction vector of the grayscale gradient of the suspected defect area; Constructing a 3D coordinate system , the central pixel point of the road grayscale image is taken as the origin of the three-dimensional coordinate system, where represents the origin of the three-dimensional coordinate system, The axis represents the horizontal axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system. The axis represents the vertical axis of the three-dimensional coordinate system; a sun reference point is constructed in the three-dimensional coordinate system according to the sun position; Define the line connecting the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system. The projection on the plane is the first projection of the suspected defect area. The first projection vector is constructed based on the first projection. The length of the first projection is used as the modulus length of the first projection vector. The direction from the coordinates on the plane to the coordinates of the center point of the suspected defect area is taken as the direction of the first projection vector, and the unit vector of the first projection vector is taken as the unit direction vector of the first projection of the suspected defect area; For The specific calculation method of the collinearity factor of the grayscale gradient characteristics of a suspected defect area is: In the formula, Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; The unit direction vector representing the grayscale gradient of the k-th suspected defect area; Indicates The unit direction vector of the first projection of the suspected defect area; Represents the cosine function.
2. A road pavement construction quality detection method according to claim 1, characterized in that: The specific method of obtaining the suspected defect area in the road surface grayscale image by using threshold segmentation includes: Adaptive threshold segmentation is used to segment the pavement grayscale image to obtain the segmentation threshold of the pavement grayscale image. The area formed by the pixels in the pavement grayscale image whose grayscale value is less than the segmentation threshold is recorded as the suspected defect area.
3. A road pavement construction quality detection method according to claim 1, characterized in that: The specific method of constructing a solar reference point in a three-dimensional coordinate system according to the solar position is: The SunCalc tool is used to calculate the azimuth and altitude of the sun relative to the ground by combining the longitude and latitude of the road grayscale image and the time when the road grayscale image was collected. The azimuth refers to the angle of the sun relative to the north, and the altitude refers to the angle of the sun relative to the horizon. The azimuth and altitude are used to convert the sun's position into coordinates in a three-dimensional coordinate system. The longitude and latitude of the suspected defect area are converted into a position in a three-dimensional coordinate system. The three-dimensional coordinate position of the sun is combined with the three-dimensional coordinate position of the road surface to determine the position of the sun reference point in the three-dimensional coordinate system.
4. A road pavement construction quality detection method according to claim 1, characterized in that: The method of dividing the suspected defect area into a plurality of sub-blocks according to the grayscale gradient direction of the suspected defect area and obtaining the grayscale gradient degree of the suspected defect area by the average grayscale difference of adjacent sub-blocks includes: Build a The sliding window is the preset side length of the sliding window, and the sliding step size of the sliding window is set to , along the direction of the first projection vector, the suspected defect area is traversed through the sliding window, and the area contained in the sliding window at each position in the traversal process is recorded as a sub-block, and a plurality of sub-blocks are obtained; Get the mean grayscale value of all pixels in each sub-block in the suspected defect area, record it as the grayscale mean of the sub-block, make a difference between the grayscale means of each adjacent sub-block in the suspected defect area, and then take the average of all differences to get the grayscale gradient degree inside the suspected defect area; The specific calculation method of the grayscale gradient degree inside a suspected defect area is: In the formula, Indicates The grayscale gradient inside the suspected defect area; Indicates The number of sub-blocks after the suspected defect area is divided; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Indicates Among the suspected defect areas The grayscale mean of each sub-block; Represents the absolute value symbol.
5. A road pavement construction quality detection method according to claim 1, characterized in that: The method of obtaining the shadow probability parameter of the suspected defect area according to the grayscale gradient degree of the suspected defect area and the linear relationship between the suspected defect area and the sun position, and screening out the shadow area according to the shadow probability parameter of the suspected defect area includes the following specific methods: Define the Euclidean distance between the sun reference point and the center point of any suspected defect area in the three-dimensional coordinate system as the first distance of the suspected defect area; For The specific calculation method of the shadow probability parameter of a suspected defect area is: In the formula, Indicates Shadow probability parameter of the suspected defect area; Indicates Collinearity factor of grayscale gradient characteristics of suspected defect areas; A data set representing the first distances of all suspected defect areas in the road grayscale image; A data set representing the grayscale gradient inside all suspected defect areas in the road to be detected; Indicates that the roads to be detected are A data set consisting of the first distances of all suspected defect areas outside the suspected defect area; Indicates that the roads to be detected are A data set consisting of the grayscale gradients inside all suspected defect areas outside a suspected defect area; express and The Pearson correlation coefficient, express and Pearson correlation coefficient of Used to describe the The linear relationship between the gray gradient degree of the suspected defect area, the suspected defect area and the sun position; represents an exponential function with a natural constant as base; represents the linear normalization function; For suspected defect area, if the The shadow probability parameter of the suspected defect area is greater than the preset parameter , then the The suspected defect area is marked as the shaded area.
6. A road pavement construction quality detection method according to claim 1, characterized in that: The method of obtaining the damage degree coefficient of all pixels in the shadow area according to the damage degree of the defect area in the shadow area to the uniformity of the grayscale gradient inside the shadow area includes the following specific methods: For any shadow area, the line segments in the shadow area that are parallel to the vector direction corresponding to the first projection vector of the shadow area and formed by a number of pixels are recorded as parallel pixel lines, and the width of each parallel pixel line is 1 pixel; Take any pixel point on any parallel pixel line in the current shadow area as the segmented pixel point on the parallel pixel line, divide the parallel pixel line into two segments, and define the pixel points with grayscale values higher than the segmented pixel point on the side close to the occluder and the pixel points with grayscale values lower than the segmented pixel point on the side far from the occluder as reverse order points; For In the shadow area The specific calculation method of the damage degree coefficient is: In the formula, Indicates the rth shaded area The damage degree coefficient; Indicates the rth shaded area Gray value of express The number of reverse order points on the parallel pixel line where the pixel point is located; express The first pixel on the parallel pixel line where the pixel point is located Gray value of the reverse order points; express The vertical damage factor; express Parallel destruction factor; Used to describe the degree of destruction of uniformity of grayscale gradient inside the shadow area; represents the linear normalization function; Represents the absolute value symbol.
7. A road pavement construction quality detection method according to claim 6, characterized in that: The specific method for obtaining the vertical damage factor is: For any shadow area, the direction perpendicular to the direction corresponding to the first projection vector of the shadow area is recorded as the projection vertical direction, and the line segment formed by a number of pixel points in the shadow area parallel to the projection vertical direction is recorded as a vertical column pixel line; the width of each vertical pixel line is 1 pixel point; For In the shadow area The specific calculation method of the vertical damage factor is: In the formula, Indicates In the shaded area The vertical destruction factor of each pixel; Indicates The shadow probability parameter of the shadow area; Indicates In the shadow area Gray value of pixel; Indicates In the shadow area The grayscale mean of the vertical column pixel line where the pixel point is located.
8. A road pavement construction quality detection method according to claim 1, characterized in that: The method of obtaining an independent defect area in the suspected defect area, obtaining a defect area in the shadow area according to the damage degree coefficient of the pixel points in the shadow area, and finally performing quality inspection on the road surface includes the following specific methods: Preset second threshold , the damage degree in the shadow area is greater than The pixel points are recorded as defective pixels; then the CCL algorithm is used to obtain the connected domain for all defective pixels in the shadow area, and the obtained connected domain is recorded as the defective area in the shadow area; The road pavement construction quality is judged based on the size of defective areas and independent defective areas.
9. A road pavement construction quality detection system, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the computer program is executed by a processor, the steps of a road pavement construction quality detection method as described in any one of claims 1-8 are implemented.
Citation Information
Patent Citations
Asphalt road quality detection method based on computer vision
CN117173661A
Road pavement construction quality detection method and system
CN117911408A
A stepwise refinement detection method for pavement cracks
US20180137612A1
