An image recognition-based building material quality detection system

By optimizing path planning and image processing, and combining illumination parameter correction and texture feature extraction, the problem of inaccurate identification in complex environments of existing building material quality inspection systems has been solved, achieving efficient and accurate building material quality inspection.

CN120808027BActive Publication Date: 2026-04-17ZHEJIANG ZHEPU CONSTRUCTION CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG ZHEPU CONSTRUCTION CO LTD
Filing Date
2025-07-10
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Existing building material quality testing systems struggle to efficiently and accurately identify minute defects and structural cracks when faced with complex environments, varying lighting conditions, irregular material surfaces, and complex textures. They also suffer from misjudgments and omissions.

Method used

An image recognition-based building material quality inspection system is adopted. Through a path planning module, an image acquisition module, a grayscale analysis module, an illumination parameter correction module, and a quality visual recognition module, combined with coordinate positioning, inspection area division, and path planning, the system optimizes illumination conditions and image processing to identify minute defects and structural cracks in building materials.

Benefits of technology

It improves the automation, accuracy, and stability of building material quality testing, can adapt to different lighting conditions, accurately identify complex textures and structural cracks, reduce misjudgments and omissions, and provide reliable quality testing support.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120808027B_ABST
    Figure CN120808027B_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of building material quality detection, and more particularly to a building material quality detection system based on image recognition. The system includes a mobile path planning module, an image acquisition module, a grayscale analysis module, an illumination parameter correction module, and a quality visual recognition module. By collecting images on the surface of the building material to be detected and combining image preprocessing, grayscale contrast, illumination correction, and texture feature extraction, the present application achieves efficient identification and accurate positioning of surface defects of building materials. The system can distinguish between fine cracks, surface flaws, and structural defects, and provide corresponding quality analysis results during the detection process. By optimizing path planning, image processing, and defect recognition, this technology improves the automation level of quality detection and enhances the stability and accuracy of the detection system, thereby providing reliable technical support for quality monitoring of building materials.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of building material quality testing technology, and in particular to a building material quality testing system based on image recognition. Background Technology

[0002] With the development of the construction industry, the quality control of building materials has become increasingly important. Traditional methods for testing building materials mainly rely on manual inspection and physical testing, which are labor-intensive, inefficient, and susceptible to human factors, leading to unstable and inaccurate test results. With the development of machine vision technology, image recognition-based inspection systems are gradually being applied in the quality inspection of various products, especially in the field of building materials where high precision is required.

[0003] Currently, the quality inspection of building materials still faces many challenges, especially the detection of surface defects. Common building materials such as stone, bricks, and wood often have defects on their surfaces, such as cracks, bubbles, holes, and discoloration. These defects directly affect the stability and aesthetics of the building structure. Traditional testing methods are often unable to effectively and quickly detect small and hidden defects, and different types of building materials often require different testing equipment and methods, increasing the complexity and cost of testing.

[0004] Existing machine vision systems primarily rely on high-quality cameras and precise lighting design, but most systems cannot adequately handle external interference in complex environments, such as changes in lighting, surface irregularities, and textural complexity. Therefore, overcoming these challenges to achieve efficient and accurate quality inspection of building materials has become one of the current research difficulties.

[0005] Chinese Patent Publication No. CN112098428A discloses an intelligent defect recognition system based on machine vision in the manufacturing of sheet building materials. The invention involves a sheet building material conveying mechanism, a standard industrial camera, a light source, a sensor trigger, and a processing unit. Specifically, it traverses each pixel on the product image, calculates the grayscale difference between the product image and the corresponding background image, compares this grayscale difference with a preset threshold, and marks the pixel as a defect when it exceeds the threshold, thus obtaining a binary image of the defect mark.

[0006] However, the fixed light source setting of this intelligent visual recognition system for sheet-like building material defects makes it unable to adapt to different materials and surface characteristics, which may lead to uneven lighting and misidentification; the fixed grayscale difference threshold affects the detection accuracy of small defects; the Blob algorithm is not accurate enough when processing complex defects; the intelligent classifier has limited ability to recognize complex textures and small defects; the scoring mechanism is too simple and fails to accurately reflect the actual impact of defects on the overall quality; these defects limit the accuracy and adaptability of the system. Summary of the Invention

[0007] To address this, the present invention provides a building material quality inspection system based on image recognition, which overcomes the problems in the prior art where the identification of structural cracks in dark areas is inaccurate, and misjudgments and omissions are prone to occur due to external interference and complex texture features.

[0008] To achieve the above objectives, the present invention provides a building material quality inspection system based on image recognition, comprising:

[0009] The movement path planning module is used to delineate each sector detection area based on the vertex of the top surface of the building material to be inspected and the radius of the sector detection area division, and to obtain each circular detection area based on the radius of the circular detection area division within the remaining area and the center point of the circle, so as to determine the movement path of the visual inspection device.

[0010] An image acquisition module, which is connected to the initial movement path formulation module, is used to sequentially acquire images of each detection area based on the movement path of the visual detection device.

[0011] A grayscale analysis module, which is connected to the image acquisition module, is used to preprocess the images of each detection area and obtain the comparison results of the grayscale contrast of each detection area image with the standard grayscale contrast threshold.

[0012] The illumination parameter correction module, which is connected to the grayscale analysis module, is used to perform brightness mean judgment and illumination state analysis on the detection area image when the first grayscale contrast comparison result is obtained, and to perform corresponding adjustment operations based on the category to which the brightness mean comparison result and the grayscale edge value comparison result belong.

[0013] A quality visual recognition module, which is connected to the grayscale analysis module, is used to perform texture feature extraction and complexity classification when the grayscale analysis module outputs the second grayscale contrast comparison result, and to determine whether it is a true structural crack based on the comparison result between the number of texture branches and the standard texture branch number threshold.

[0014] Furthermore, the movement path formulation module includes a coordinate positioning unit, a detection area division unit, and a movement path planning unit, wherein,

[0015] The coordinate positioning unit is used to obtain each vertex of the top surface of the building material to be detected, and to align the center point of the rotation axis with the vertex in sequence to obtain the center point of the sector corresponding to the vertex, so as to divide each sector detection area and the corresponding detection area division order mark.

[0016] The detection area division unit is used to obtain the remaining area outside the fan-shaped detection area on the top surface of the building material to be tested, and to obtain each circular detection area and the corresponding detection area division order mark based on the circular detection area division method within the remaining area.

[0017] The method for dividing the remaining area into circular detection zones is determined by the category to which the number of overlapping sector detection zones belongs.

[0018] The movement path planning unit is used to determine the movement path of the visual inspection device based on the detection area division order mark and the detection area center point.

[0019] Furthermore, the detection area division unit includes a remaining area acquisition subunit and a circular detection area division mark subunit, wherein,

[0020] The remaining area acquisition subunit is used to acquire the first and last endpoints of each sector detection area intersecting with the edge of the marble top surface in a clockwise division manner, and to determine the category of the number of overlapping sectors based on the positional relationship and distance between the first and last endpoints of different sector areas on the same top surface edge.

[0021] The circular detection area division marker subunit is used to divide the remaining area with the corresponding circular detection area division radius based on the category of the number of overlapping sector detection areas, so as to obtain each circular detection area and the corresponding division order marker.

[0022] Furthermore, the grayscale analysis module includes an image preprocessing unit and a grayscale comparison unit, wherein,

[0023] The image preprocessing unit is used to perform preprocessing operations on the detection area image and obtain the grayscale contrast of the detection area image to determine whether it is greater than the standard grayscale contrast threshold.

[0024] The grayscale comparison unit is used to compare the grayscale contrast of the detection area image with the standard grayscale contrast threshold to obtain the grayscale contrast comparison result.

[0025] Furthermore, the illumination parameter correction module includes a brightness average comparison unit and a light source intensity adjustment unit, wherein,

[0026] The brightness mean comparison unit is used to calculate the brightness mean of the detection area image when the first grayscale contrast comparison result is obtained, and compare it with the standard brightness mean threshold to obtain the brightness mean comparison result.

[0027] The light source intensity adjustment unit is used to perform corresponding adjustment operations on the comparison results of different grayscale edge values ​​under the first brightness mean comparison result.

[0028] Furthermore, the light source intensity adjustment unit includes a grayscale edge value comparison subunit and an adjustment operation subunit, wherein,

[0029] The grayscale edge value comparison unit is used to compare the grayscale edge values ​​of the detection area image with the standard grayscale edge range to obtain the grayscale edge value comparison result.

[0030] The adjustment operation unit is used to perform adjustment operation steps for the corresponding light source based on the category to which the grayscale edge value comparison result belongs.

[0031] Furthermore, the quality visual recognition module includes a texture feature extraction unit and a structural defect recognition unit, wherein,

[0032] The texture feature extraction unit is used to extract the main texture path and texture branch points in the detection area image and the number of texture branches at that point when the second grayscale contrast comparison result is obtained, and to obtain the texture branch number comparison result between the number of texture branches and the standard texture branch number threshold.

[0033] The structural defect identification unit is used to identify and judge structural cracks in the detection area image when obtaining the first texture branch number comparison result.

[0034] Furthermore, the texture feature extraction unit includes a dark texture extraction subunit, a skeletonization processing subunit, and a texture branch number comparison subunit, wherein,

[0035] The dark texture extraction subunit is used to extract dark texture regions in the detection area image and generate a dark texture map and a corresponding texture contour map.

[0036] The skeletonization subunit is used to perform skeletonization processing on the dark texture map and the corresponding texture outline map to extract the main texture path, texture branch points and the number of texture branches at that point.

[0037] The comparison subunit is used to compare the number of texture branches corresponding to each texture branch point with the standard texture branch threshold to obtain the texture branch number comparison result.

[0038] Furthermore, the structural defect identification unit includes a structural crack identification subunit and a texture branch quantity determination unit, wherein,

[0039] The structural crack identification subunit is used to determine whether a texture abrupt change region is a structural crack;

[0040] Among them, texture mutation regions are identified based on the texture direction mutation rate, and whether they are structural cracks are determined by combining the matching degree between the texture mutation regions and the main texture path.

[0041] The texture branch quantity determination unit is used to exclude pseudo-structural cracks in structural cracks.

[0042] Furthermore, the structural crack identification subunit determines whether a texture abrupt change region is a structural crack by including:

[0043] Calculate the texture orientation mutation rate, and divide the texture abrupt region and continuous texture region based on the comparison result of the texture orientation mutation rate and the standard texture orientation mutation rate threshold.

[0044] Calculate the matching degree between the texture abrupt change region and the main texture path, and obtain the structural crack identification result when the first matching degree result is obtained.

[0045] Compared with existing technologies, the advantages of this invention are that, through grayscale analysis and illumination parameter correction, the system can automatically adapt to different illumination conditions, ensuring the stability of image quality; the texture feature extraction and structural defect recognition modules can efficiently identify subtle defects in images, especially in the detection of complex textures and structural cracks; by optimizing path planning, image processing, and defect recognition processes, this system improves the automation, accuracy, and stability of detection, and can provide more reliable technical support for the quality inspection of building materials.

[0046] Furthermore, the coordinate positioning unit accurately acquires each vertex of the top surface of the building material to be inspected and its corresponding sector center point, ensuring the accurate division of each sector inspection area and providing accurate basic data for subsequent path planning. The inspection area division unit flexibly delineates circular inspection areas based on the overlap between the remaining area and the sector inspection areas, thereby optimizing the coverage of the inspection area and the accuracy of path planning. The movement path planning unit rationally determines the movement trajectory of the visual inspection device based on the inspection area division order markers and center point coordinates; combined with the movement characteristics of the visual inspection device, the path is smoothed, further improving the stability and acquisition efficiency of the path, avoiding abrupt changes or irregular movements in the path, and improving the stability and accuracy of the overall inspection process.

[0047] Furthermore, the remaining area acquisition sub-unit accurately identifies the beginning and end points where the fan-shaped detection area intersects with the edge of the marble top surface, and judges the overlap based on positional relationship and distance, ensuring the rationality of the division of the fan-shaped detection area; under different overlap categories, the circular detection area division marker sub-unit can flexibly adjust the layout strategy of the circular detection area, and optimize the coverage of the remaining area by adjusting the number and position of the circles; this module effectively ensures the comprehensiveness and continuity of the detection area, and ensures that all areas are covered without blind spots through appropriate adjustments and offsets. The strategy of not adjusting the radius but only adjusting the layout position simplifies the detection process and reduces the computational complexity. Attached Figure Description

[0048] Figure 1 This is a schematic diagram of the structure of the image recognition-based building material quality inspection system according to an embodiment of the present invention;

[0049] Figure 2 This is a schematic diagram of the connection of the detection area division unit in an embodiment of the present invention;

[0050] Figure 3 This is a connection diagram of the quality visual recognition module according to an embodiment of the present invention;

[0051] Figure 4 This is a logic diagram for determining whether a texture abrupt change region is a structural crack in the structural crack identification subunit of an embodiment of the present invention. Detailed Implementation

[0052] To make the objectives and advantages of the present invention clearer, the present invention will be further described below with reference to embodiments; it should be understood that the specific embodiments described herein are only for explaining the present invention and are not intended to limit the present invention.

[0053] Preferred embodiments of the present invention will now be described with reference to the accompanying drawings. Those skilled in the art should understand that these embodiments are merely illustrative of the technical principles of the present invention and are not intended to limit the scope of protection of the present invention.

[0054] It should be noted that in the description of this invention, the terms "upper", "lower", "left", "right", "inner", "outer", etc., which indicate directions or positional relationships, are based on the directions or positional relationships shown in the accompanying drawings. This is only for the convenience of description and is not intended to indicate or imply that the device or element must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, it should not be construed as a limitation of this invention.

[0055] Furthermore, it should be noted that, in the description of this invention, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.

[0056] Please see Figure 1 The diagram shown is a structural schematic of a building material quality inspection system based on image recognition according to an embodiment of the present invention. The present invention provides a building material quality inspection system based on image recognition, characterized in that it includes:

[0057] The movement path planning module is used to obtain several fan-shaped detection areas based on the top vertex of the building material to be detected and the radius of the fan-shaped detection area, and to obtain several circular detection areas based on the radius of the circular detection area within the remaining area and the center point of the circle, so as to determine the movement path of the visual inspection device.

[0058] An image acquisition module, which is connected to the initial movement path formulation module, is used to sequentially acquire images of each detection area based on the movement path of the visual detection device;

[0059] A grayscale analysis module, which is connected to the image acquisition module, is used to preprocess the images of each detection area and to obtain the comparison results of the grayscale contrast of any detection area image with the standard grayscale contrast threshold.

[0060] The illumination parameter correction module, which is connected to the grayscale analysis module, is used to perform brightness mean judgment and illumination state analysis on the detection area image when the first grayscale contrast comparison result is obtained, and to perform corresponding adjustment operations based on the category to which the brightness mean comparison result and the grayscale edge value comparison result belong.

[0061] A quality visual recognition module, which is connected to the grayscale analysis module, is used to perform texture feature extraction and complexity classification when the grayscale analysis module outputs the second grayscale contrast comparison result, and to determine whether it is a true structural crack based on the comparison result between the number of texture branches and the standard texture branch number threshold.

[0062] In this embodiment, the image acquisition module is connected to the initial movement path formulation module and is used to acquire the image of the first detection area in the sector detection area, and after completing the visual recognition of the image quality of the area, to acquire the subsequent detection area images in sequence according to the division order mark.

[0063] The building material to be tested is a marble slab;

[0064] The visual inspection device structure includes a controllable rotating shaft platform, an image acquisition module fixedly mounted on the platform, an industrial camera and an image sensor integrated inside the image acquisition module, and several LED beads evenly arranged around its periphery.

[0065] In this embodiment, the actual length of the lamp bead spacing is set according to the design requirements and acquisition accuracy of the visual inspection device;

[0066] Typically, the spacing of the LED beads is adjusted according to the size of the marble slab, the complexity of the surface texture, and the image acquisition requirements to ensure uniform lighting and no shadows in each acquisition area.

[0067] The actual spacing between the LED beads is 5 to 10 millimeters to ensure uniform illumination covering each detection area and to avoid over-illumination or shadows.

[0068] When the LED beads are arranged linearly, the actual diameter of the entire ring is the working range of the front-end camera of the vision inspection device, which is usually set to 50 to 100 mm.

[0069] When the detection is started, the rotating shaft drives the vision detection device to rotate, so that the image acquisition module can be aligned with the center direction of each vertex to acquire images, forming several preset fan-shaped areas; when it reaches a specified angle position, the camera immediately starts to acquire images, and the LED beads light up synchronously to provide a uniform light source for the image, ensuring the consistency of image brightness and grayscale distribution; after the image acquisition is completed, the rotating shaft continues to rotate and move along the preset path;

[0070] After all the data in the sector detection area has been collected, the rotating shaft continues to rotate according to the preset supplementation strategy to collect the remaining uncovered circular area.

[0071] Through grayscale analysis and illumination parameter correction, the system can automatically adapt to different lighting conditions, ensuring the stability of image quality. The texture feature extraction and structural defect recognition modules can efficiently identify subtle defects in images, especially in the detection of complex textures and structural cracks. By optimizing path planning, image processing, and defect recognition processes, the system improves the automation, accuracy, and stability of detection, providing more reliable technical support for the quality inspection of building materials.

[0072] Specifically, the movement path formulation module includes a coordinate positioning unit, a detection area division unit, and a movement path planning unit, wherein,

[0073] The coordinate positioning unit is used to obtain each vertex of the top surface of the building material to be detected, and to align the center point of the rotation axis with the vertex in sequence to obtain the center point of the sector corresponding to the vertex, so as to divide each sector detection area and the corresponding detection area division order mark.

[0074] The detection area division unit is used to obtain the remaining area outside all the fan-shaped detection areas on the top surface of the building material to be tested, and to obtain each circular detection area and the corresponding detection area division order mark based on the circular detection area division method within the remaining area.

[0075] The method for dividing the remaining area into circular detection zones is determined by the category to which the number of overlapping sector detection zones belongs.

[0076] The movement path planning unit is used to determine the movement path of the visual inspection device based on the detection area division order mark and the detection area center point.

[0077] In this embodiment, the rotating shaft is the core rotating part of the visual inspection device, located at the center of the device. The main function of this rotating shaft is to support the rotational movement of the image acquisition module.

[0078] The center point of a sector refers to the vertex of each sector when the rotation range of the rotating axis is divided into multiple sector detection areas;

[0079] The detection zone division order is based on the chronological order of data collection in each detection zone; the detection zone division order mark refers to the numbering mark assigned to each detection zone during the detection process;

[0080] Obtain the division order markers of each detection zone, and connect the center points of the corresponding detection zones in order from first to last according to the order markers to obtain the movement path of the visual inspection device;

[0081] Meanwhile, the motion path planning unit smooths the path based on the motion characteristics of the moving mechanism of the vision detection device;

[0082] Identify right-angle turning points in the path and replace right angles with a turning angle of 90° with arcs with a radius of 1 cm; the start and end points of the arcs are smoothly connected to the front and back parts of the path, respectively; if there are multiple consecutive right-angle turning points in the path, rounded corners are replaced one by one to ensure a smooth transition at each turning point.

[0083] The coordinate positioning unit accurately acquires each vertex of the top surface of the building material to be inspected and its corresponding sector center point, ensuring the precise division of each sector inspection area and providing accurate basic data for subsequent path planning. The inspection area division unit flexibly delineates circular inspection areas based on the overlap between the remaining area and the sector inspection areas, thereby optimizing the coverage of the inspection area and the accuracy of path planning. The movement path planning unit rationally determines the movement trajectory of the visual inspection device based on the inspection area division order markers and center point coordinates; combined with the movement characteristics of the visual inspection device, the path is smoothed, further improving the stability and acquisition efficiency of the path, avoiding abrupt changes or irregular movements in the path, and improving the stability and accuracy of the overall inspection process.

[0084] See Figure 2 As shown, it is a schematic diagram of the connection of the detection area division unit in an embodiment of the present invention;

[0085] Specifically, the detection area division unit includes a remaining area acquisition subunit and a circular detection area division mark subunit, wherein,

[0086] The remaining area acquisition subunit is used to acquire the first and last endpoints of each sector detection area intersecting with the edge of the marble top surface in a clockwise division manner, and to determine the category of the number of overlapping sectors based on the positional relationship and distance between the first and last endpoints of different sector areas on the same top surface edge.

[0087] The circular detection area division marker subunit is used to divide the remaining area with the corresponding circular detection area division radius based on the category of the number of overlapping sector detection areas, so as to obtain each circular detection area and the corresponding division order marker.

[0088] In this embodiment, the circular detection area and the sector-shaped detection area have the same detection radius, denoted as R;

[0089] The diameter of the circular detection area is denoted as D, which satisfies D=2R;

[0090] The number of overlapping areas in the sector detection region can be categorized into three types: no overlap, two overlaps, and four overlaps.

[0091] The radius is not adjusted during deployment; full coverage of the remaining area is achieved solely through the deployment location and quantity.

[0092] When it is a non-overlapping category, this category refers to the fact that there is no overlapping area between the four sector detection areas, and the remaining area is a completely closed middle area;

[0093] Determine the boundary contour of the remaining region and its maximum continuous width. and maximum continuous height ;

[0094] Starting from the top left corner of the remaining area, circular detection areas are laid out sequentially at intervals D along the horizontal direction, with the vertical coordinate of the center remaining fixed. After completing one row, the circular detection areas are laid out by moving down D vertically.

[0095] Layout the grid as described above until the remaining area is completely covered; for edge areas that are close to the boundary but not completely covered, adjust the offset position of the center according to the actual remaining width and height so that the circular detection area at the boundary covers the remaining part;

[0096] The layout uses a regular grid, with the layout directions being the positive horizontal direction (positive X-axis) and the negative vertical direction (negative Y-axis).

[0097] When there are two overlapping categories, this category refers to the existence of two overlapping fan-shaped detection areas; based on the maximum width of the remaining area. The comparison results with diameter D are divided into two cases, including: Less than or equal to D and Greater than D, where,

[0098] like If the diameter is greater than D, multiple circular detection areas are arranged along the width of the remaining area with a step size close to the diameter D. Some overlap between the circles is allowed, and the overlap ratio is controlled within 20%-30% to ensure continuous coverage and reduce blind spots.

[0099] Multiple rows are arranged with a spacing D between the centers in the vertical direction, and appropriate overlap is also allowed.

[0100] The center of the circular detection area can be offset and adjusted according to the shape of the remaining area.

[0101] like When the value is less than or equal to D, and the remaining area can be completely covered by a single circular detection area, a circular detection area that can fully cover the remaining area is deployed.

[0102] If the remaining area is not wide enough but has an irregular shape, an auxiliary circular detection area can be added appropriately, allowing some overlap between the circular detection areas;

[0103] When the category is four-overlap, a circular detection area should be placed at the geometric center of the remaining region.

[0104] If the circular detection area cannot completely cover the remaining area, then 2-3 more circular or semi-circular detection areas are set up around it at intervals of D / 2, and the center positions are adjusted to ensure that the remaining area is completely covered.

[0105] The remaining area acquisition sub-unit accurately identifies the beginning and end points where the fan-shaped detection area intersects with the edge of the marble top surface, and judges the overlap based on the positional relationship and distance, ensuring the rationality of the division of the fan-shaped detection area. Under different overlap categories, the circular detection area division marker sub-unit can flexibly adjust the layout strategy of the circular detection area. By adjusting the number and position of the circles, the coverage of the remaining area is optimized. This module effectively ensures the comprehensiveness and continuity of the detection area. Through appropriate adjustments and offsets, it ensures that all areas are covered without blind spots. By adopting a strategy of not adjusting the radius but only adjusting the layout position, the detection process is simplified and the computational complexity is reduced.

[0106] Specifically, the grayscale analysis module includes an image preprocessing unit and a grayscale comparison unit, wherein,

[0107] The image preprocessing unit is used to perform preprocessing operations on the detection area image and obtain the grayscale contrast of the detection area image to determine whether it is greater than the standard grayscale contrast threshold.

[0108] The grayscale comparison unit is used to compare the grayscale contrast of the detection area image with the standard grayscale contrast threshold to obtain the grayscale contrast comparison result.

[0109] In this embodiment, the image preprocessing subunit performs preprocessing operations such as filtering and noise reduction and contrast enhancement on the acquired detection area image to improve the grayscale feature performance of the image.

[0110] After preprocessing, the color image is converted into a single-channel grayscale image, and the mean grayscale value and standard deviation of all pixels in the grayscale image are calculated.

[0111] The formula for calculating the grayscale mean is as follows:

[0112] ,

[0113] Where N is the total number of pixels in the image. Let be the grayscale value of the i-th pixel;

[0114] The formula for calculating the standard deviation of grayscale is:

[0115] ,

[0116] Gray-level contrast is calculated based on the gray-level mean and standard deviation.

[0117] ,

[0118] in, To prevent small constants with denominators of zero, take ;

[0119] The grayscale comparison subunit compares the grayscale contrast of the detection area image with a standard grayscale contrast threshold.

[0120] If the grayscale contrast is greater than the standard grayscale contrast threshold, the first grayscale contrast comparison result is obtained, and the image quality is abnormal, so as to determine whether to perform the light source adjustment operation.

[0121] If the grayscale contrast is less than or equal to the standard grayscale contrast threshold, the image quality is normal, and a second grayscale contrast comparison result is obtained, which is then used to perform quality visual recognition.

[0122] In this embodiment, the standard grayscale contrast threshold is selected as 0.3 based on historical production data.

[0123] The image preprocessing subunit filters and reduces noise and enhances contrast, improving the grayscale feature performance of the image. The grayscale comparison subunit quickly identifies the image quality by comparing the grayscale contrast with a standard threshold, and triggers the corresponding illumination parameter correction based on the identification result to ensure that the image quality meets the detection standard, thereby improving the reliability and accuracy of subsequent visual recognition.

[0124] Specifically, the illumination parameter correction module includes a brightness average comparison unit and a light source intensity adjustment unit, wherein,

[0125] The brightness mean comparison unit is used to calculate the brightness mean of the detection area image when the first grayscale contrast comparison result is obtained, and compare it with the standard brightness mean threshold to obtain the brightness mean comparison result.

[0126] The light source intensity adjustment unit is used to perform corresponding adjustment operations on the comparison results of different grayscale edge values ​​under the first brightness mean comparison result.

[0127] In this embodiment, the brightness mean comparison unit is used to calculate the brightness mean based on the brightness channel data of the acquired detection area image when the first grayscale contrast comparison result is obtained. ;

[0128] The process involves converting a color image from RGB color space to YUV color space, extracting the luminance channel Y, and calculating the average luminance using the following formula.

[0129] ,

[0130] Where Y(i,j) represents the brightness value of the pixel in the i-th row and j-th column of the brightness channel, and M and N are the number of rows and columns of the image, respectively;

[0131] A standard brightness mean threshold of 0.6 is set, and the brightness mean of the detection area image is compared with the standard brightness mean threshold.

[0132] If the average brightness value is greater than the standard average brightness threshold, the first average brightness value comparison result is obtained. If the image brightness is too high, the corresponding light source adjustment operation is performed based on the grayscale edge value comparison result.

[0133] If the average brightness is less than or equal to the standard average brightness threshold, the image brightness is too low. A second average brightness comparison result is obtained, and a light source adjustment operation is performed to adjust the brightness of the LED beads to 150% of the initial LED bead brightness.

[0134] The average brightness of the detection area image is accurately calculated by the average brightness comparison unit, and the comparison is performed based on a standard threshold to determine the illumination status of the image in real time and execute corresponding adjustment measures. This mechanism effectively avoids image quality problems caused by insufficient or excessive light, and improves the stability of the lighting environment and the consistency of image acquisition.

[0135] Specifically, the light source intensity adjustment unit includes a grayscale edge value comparison subunit and an adjustment operation subunit, wherein,

[0136] The grayscale edge value comparison unit is used to compare the grayscale edge values ​​of the detection area image with the standard grayscale edge range to obtain the grayscale edge value comparison result.

[0137] The adjustment operation unit is used to perform adjustment operation steps for the corresponding light source based on the category to which the grayscale edge value comparison result belongs.

[0138] In this embodiment, the grayscale edge value is calculated using the Sobel operator to calculate the gradient magnitude of each pixel in the detection area image, and then the average value is taken to represent the edge sharpness of the entire image. The calculation formula is as follows:

[0139] ,

[0140] in, Let be the gradient of the i-th pixel in the X direction;

[0141] Let be the gradient of the i-th pixel in the Y direction;

[0142] N is the total number of pixels;

[0143] The grayscale edge values ​​of the detection area image are compared with the standard grayscale edge range.

[0144] If the grayscale edge value is greater than or equal to the maximum value of the standard grayscale edge range, the first grayscale edge value comparison result is obtained. The image edge intensity is high and the texture complexity is large, that is, the image is clear, and no adjustment is made to the light source.

[0145] If the grayscale edge value is within the standard grayscale edge range, and the second grayscale edge value comparison result is obtained, the illumination distribution is uneven, and the light source adjustment operation is performed to adjust the brightness of the LED to 80% of the initial LED brightness.

[0146] If the grayscale edge value is less than or equal to the minimum value of the standard grayscale edge range, the third grayscale edge value comparison result is obtained. The image edge is not clear and the texture details are missing. Therefore, the light source adjustment operation of reducing the light source height H is performed.

[0147] By analyzing the image edge sharpness and texture complexity, the intensity and height of the light source are dynamically adjusted to ensure optimal image quality. For images with sharp edges, the light source remains unchanged; for images with uneven illumination or blurred edges, the brightness or height of the light source is automatically adjusted to improve the lighting effect.

[0148] See Figure 3 The diagram shown is a connection schematic of the quality visual recognition module according to an embodiment of the present invention.

[0149] Specifically, the quality visual recognition module includes a texture feature extraction unit and a structural defect recognition unit, wherein,

[0150] The texture feature extraction unit is used to extract the main texture path and texture branch points in the detection area image and the number of texture branches at that point when the second grayscale contrast comparison result is obtained, and to obtain the texture branch number comparison result between the number of texture branches and the standard texture branch number threshold.

[0151] The structural defect identification unit is used to identify and judge structural cracks in the detection area image when obtaining the first texture branch number comparison result.

[0152] Specifically, the texture feature extraction unit includes a dark texture extraction subunit, a skeletonization processing subunit, and a texture branch number comparison subunit, wherein,

[0153] The dark texture extraction subunit is used to extract dark texture regions in the detection area image and generate a dark texture map and a corresponding texture contour map.

[0154] The skeletonization subunit is used to perform skeletonization processing on the dark texture map and the corresponding texture outline map to extract the main texture path, texture branch points and the number of texture branches at that point.

[0155] The comparison subunit is used to compare the number of texture branches corresponding to each texture branch point with the standard texture branch threshold to obtain the texture branch number comparison result.

[0156] In this embodiment, the dark texture extraction subunit is used to extract dark texture regions in the detection area image and generate a dark texture map and a corresponding texture contour map. The specific steps are as follows:

[0157] Calculate the global adaptive threshold based on the Otsu threshold segmentation method. And extract all grayscale values ​​below The pixel areas form a dark texture map;

[0158] After Gaussian filtering to reduce noise in the dark texture image, the edge contour is extracted using the Canny edge detection algorithm. The low threshold is set to 50 and the high threshold is set to 150 to obtain the texture contour image.

[0159] The skeletonization subunit is used to extract the main texture path and texture branch points of the dark texture structure. The specific steps are as follows:

[0160] Binarization thinning is performed on the texture contour map, and the Zhang-Suen algorithm is used to generate the skeleton map.

[0161] Extract the longest connected path from the skeleton graph as the main texture path;

[0162] Identify connection nodes outside the main texture path as texture branch points, and count the number of texture branches at each branch point;

[0163] The texture branch number comparison subunit is used to compare the texture branch number of each branch point obtained from the above statistics with the set standard texture branch number threshold to obtain the texture branch number comparison result.

[0164] Set the standard texture branch count threshold to 15, and compare the number of texture branches at each branch point with the set standard texture branch count threshold.

[0165] If the number of texture branches is greater than the standard threshold for the number of texture branches, the first texture branch number comparison result is obtained. If the subsequent identification result is a structural crack, the crack is determined to be a true structural crack.

[0166] If the number of texture branches is less than or equal to the standard texture branch number threshold, a second texture branch number comparison result is obtained. If the subsequent identification result is a structural crack, the crack is determined to be a pseudo-structural crack.

[0167] By accurately extracting and skeletonizing the dark textured areas in the image, the main texture path and texture branch points were successfully extracted, providing clear structural information about the image texture. By accurately comparing the number of texture branches, structural cracks and pseudo cracks were effectively distinguished, improving the accuracy of crack identification.

[0168] Specifically, the structural defect identification unit includes a structural crack identification subunit and a texture branch quantity determination unit, wherein,

[0169] The structural crack identification subunit is used to determine whether a texture abrupt change region is a structural crack;

[0170] Among them, texture mutation regions are identified based on the texture direction mutation rate, and whether they are structural cracks are determined by combining the matching degree between the texture mutation regions and the main texture path.

[0171] The texture branch quantity determination unit is used to exclude pseudo-structural cracks in structural cracks.

[0172] In this embodiment, the structural crack identification subunit is used to determine whether a texture abrupt change region is a structural crack, and it calculates the texture direction abrupt change rate based on the change in texture direction gradient.

[0173] The standard texture direction mutation rate threshold is set to 0.5. The mutation rate is compared with the standard texture direction mutation rate threshold to identify texture mutation regions and continuous texture regions.

[0174] Calculate the matching degree between texture abrupt change regions and the main texture path;

[0175] If the matching degree meets the first matching degree, the region is marked as a structural crack, and the number of texture branches within it is obtained. If the number of texture branches is greater than the standard texture branch number threshold, a true structural crack is obtained.

[0176] A crack is considered a pseudo-structural crack when the number of texture branches is less than or equal to the standard threshold for the number of texture branches.

[0177] By accurately calculating the abrupt change rate of texture direction and the matching degree between the texture abrupt change region and the main texture path, the existence of structural cracks was successfully determined. Combined with the judgment of the number of texture branches, it is possible to effectively distinguish between true structural cracks and false cracks and avoid misjudgment.

[0178] See Figure 4 As shown, it is a logic determination diagram of the structural crack identification subunit in an embodiment of the present invention for determining whether a texture abrupt change region is a structural crack.

[0179] Specifically, the structural crack identification subunit determines whether a texture abrupt change region is a structural crack by including:

[0180] Calculate the texture orientation mutation rate, and divide the texture abrupt region and continuous texture region based on the comparison result of the texture orientation mutation rate and the standard texture orientation mutation rate threshold.

[0181] Calculate the matching degree between the texture abrupt change region and the main texture path, and obtain the structural crack identification result when the first matching degree result is obtained.

[0182] In this embodiment, for the texture abrupt change region extracted from the image, its texture direction abrupt change rate is first calculated;

[0183] The abrupt change rate of texture orientation can be analyzed by examining the gradient changes in image texture. The specific calculation method is as follows:

[0184] ,

[0185] in, I(x, y) is the gray-level gradient of a point in the image, and the area of ​​the region is the total number of pixels in the texture abrupt change region;

[0186] The standard texture direction mutation rate threshold is set to 0.3. The calculated texture direction mutation rate is then compared with the preset standard texture direction mutation rate threshold.

[0187] If the texture direction mutation rate is greater than the standard texture direction mutation rate threshold, there is a strong texture direction mutation in this region. This region is a texture mutation region. Further calculation is performed on the matching degree between the texture mutation region and the main texture path.

[0188] If the texture direction abrupt change rate is less than or equal to the standard texture direction abrupt change rate threshold, there is no strong texture direction abrupt change in this region, this region is a continuous texture region, and there are no defects in this region;

[0189] For texture mutation regions selected by mutation rate, their matching degree with the extracted main texture path is further calculated;

[0190] The matching degree is calculated by calculating the Hausdorff distance.

[0191] ,

[0192] Where A is the set of contour points in the texture abrupt change region;

[0193] B is the set of outline points of the main texture path;

[0194] ||·|| represents the Euclidean distance;

[0195] A standard distance threshold of 8 pixels is set, and the calculated Hausdorff distance is compared with the standard distance threshold.

[0196] If the Hausdorff distance is greater than the standard distance threshold, the first matching degree result is obtained. The texture abrupt change region has a strong consistency with the main texture path, and there is a structural crack in this region.

[0197] If the Hausdorff distance is less than or equal to the standard distance threshold, the second matching degree result is obtained. The consistency between the texture abrupt region and the main texture path is weak, and there are unstructured cracks in this region.

[0198] By calculating the matching degree between the texture direction mutation rate and the main texture path, and combining the Hausdorff distance for matching degree analysis, the recognition performance of complex textures and small-scale cracks is particularly improved.

[0199] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.

[0200] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A building material quality inspection system based on image recognition, characterized in that, include, The movement path planning module is used to delineate each sector detection area based on the vertex of the top surface of the building material to be inspected and the radius of the sector detection area division, and to obtain each circular detection area based on the radius of the circular detection area division within the remaining area and the center point of the circle, so as to determine the movement path of the visual inspection device. An image acquisition module, which is connected to the movement path planning module, is used to sequentially acquire images of each detection area based on the movement path of the visual inspection device. A grayscale analysis module, which is connected to the image acquisition module, is used to preprocess the images of each detection area and obtain the comparison results of the grayscale contrast of each detection area image with the standard grayscale contrast threshold. The illumination parameter correction module is connected to the grayscale analysis module. When the first grayscale contrast comparison result is obtained, it performs brightness mean judgment and illumination state analysis on the detection area image, and performs corresponding adjustment operations based on the category to which the brightness mean comparison result and grayscale edge value comparison result belong. A quality visual recognition module, which is connected to the grayscale analysis module, is used to perform texture feature extraction and complexity classification when the grayscale analysis module outputs the second grayscale contrast comparison result, and to determine whether it is a true structural crack based on the comparison result between the number of texture branches and the standard texture branch number threshold. The quality visual recognition module includes a texture feature extraction unit and a structural defect recognition unit, wherein... The texture feature extraction unit is used to extract the main texture path and texture branch points in the detection area image and the number of texture branches at that point when the second grayscale contrast comparison result is obtained, and to obtain the texture branch number comparison result between the number of texture branches and the standard texture branch number threshold. The structural defect identification unit is used to identify and judge structural cracks in the detection area image when obtaining the first texture branch number comparison result; The structural defect identification unit includes a structural crack identification subunit and a texture branch quantity determination unit, wherein, The structural crack identification subunit is used to determine whether a texture abrupt change region is a structural crack; Among them, texture mutation regions are identified based on the texture direction mutation rate, and whether they are structural cracks are determined by combining the matching degree between the texture mutation regions and the main texture path. The texture branch quantity determination unit is used to exclude pseudo-structural cracks in structural cracks.

2. The image recognition-based building material quality inspection system according to claim 1, characterized in that, The movement path formulation module includes a coordinate positioning unit, a detection area division unit, and a movement path planning unit, wherein... The coordinate positioning unit is used to obtain each vertex of the top surface of the building material to be detected, and to align the center point of the rotation axis with the vertex in sequence to obtain the center point of the sector corresponding to the vertex, so as to divide each sector detection area and the corresponding detection area division order mark. The detection area division unit is used to obtain the remaining area outside the fan-shaped detection area on the top surface of the building material to be tested, and to obtain each circular detection area and the corresponding detection area division order mark based on the circular detection area division method within the remaining area. The method for dividing the remaining area into circular detection zones is determined by the category to which the number of overlapping sector detection zones belongs. The movement path planning unit is used to determine the movement path of the visual inspection device based on the detection area division order mark and the detection area center point.

3. The image recognition-based building material quality inspection system according to claim 2, characterized in that, The detection area division unit includes a remaining area acquisition subunit and a circular detection area division mark subunit, wherein, The remaining area acquisition subunit is used to acquire the first and last endpoints of each sector detection area intersecting with the edge of the marble top surface in a clockwise division manner, and to determine the category of the number of overlapping sectors based on the positional relationship and distance between the first and last endpoints of different sector areas on the same top surface edge. The circular detection area division marker subunit is used to divide the remaining area with the corresponding circular detection area division radius based on the category of the number of overlapping sector detection areas, so as to obtain each circular detection area and the corresponding division order marker.

4. The image recognition-based building material quality inspection system according to claim 1, characterized in that, The grayscale analysis module includes an image preprocessing unit and a grayscale comparison unit, wherein... The image preprocessing unit is used to perform preprocessing operations on the detection area image and obtain the grayscale contrast of the detection area image to determine whether it is greater than the standard grayscale contrast threshold. The grayscale comparison unit is used to compare the grayscale contrast of the detection area image with the standard grayscale contrast threshold to obtain the grayscale contrast comparison result.

5. The image recognition-based building material quality inspection system according to claim 1, characterized in that, The illumination parameter correction module includes a brightness average comparison unit and a light source intensity adjustment unit, wherein... The brightness mean comparison unit is used to calculate the brightness mean of the detection area image when the first grayscale contrast comparison result is obtained, and compare it with the standard brightness mean threshold to obtain the brightness mean comparison result. The light source intensity adjustment unit is used to perform corresponding adjustment operation steps based on the grayscale edge value according to the first brightness mean comparison result.

6. The image recognition-based building material quality inspection system according to claim 5, characterized in that, The light source intensity adjustment unit includes a grayscale edge value comparison subunit and an adjustment operation subunit, wherein... The grayscale edge value comparison unit is used to compare the grayscale edge values ​​of the detection area image with the standard grayscale edge range to obtain the grayscale edge value comparison result. The adjustment operation unit is used to perform adjustment operation steps for the corresponding light source based on the category to which the grayscale edge value comparison result belongs.

7. The image recognition-based building material quality inspection system according to claim 1, characterized in that, The texture feature extraction unit includes a dark texture extraction subunit, a skeletonization processing subunit, and a texture branch number comparison subunit, wherein... The dark texture extraction subunit is used to extract dark texture regions in the detection area image and generate a dark texture map and a corresponding texture contour map. The skeletonization subunit is used to perform skeletonization processing on the dark texture map and the corresponding texture outline map to extract the main texture path, texture branch points and the number of texture branches at that point. The comparison subunit is used to compare the number of texture branches corresponding to each texture branch point with the standard texture branch threshold to obtain the texture branch number comparison result.

8. The building material quality inspection system based on image recognition according to claim 1, characterized in that, The structural crack identification subunit determines whether a texture abrupt change region is a structural crack, including: Calculate the texture orientation mutation rate, and divide the texture abrupt region and continuous texture region based on the comparison result of the texture orientation mutation rate and the standard texture orientation mutation rate threshold. Calculate the matching degree between the texture abrupt change region and the main texture path, and obtain the structural crack identification result when the first matching degree result is obtained.

Citation Information

Patent Citations

  • Intelligent defect recognition system based on machine vision in sheet building material manufacturing

    CN112098428A

  • Liver ultrasonic image identification method based on sparse expression

    CN105956620A

  • Anchoring device for detecting strength of mortar surface layer

    CN118857948A