A building crack detection method, system, electronic device and storage medium
By combining infrared thermal imagers and laser scanners to generate temperature gradient distribution maps and 3D point cloud data, the information on crack edges is enhanced and fused, solving the problems of misjudgment and incomplete assessment in existing technologies, and achieving accurate detection of building cracks.
Patent Information
- Application Number
- CN202511354434.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-22
- Publication Date
- 2025-12-05
- Estimated Expiration
- 2045-09-22
AI Technical Summary
Existing building crack detection technologies are susceptible to misjudgment due to surface coverings, have difficulty identifying minute cracks, and do not provide a comprehensive assessment of crack depth, resulting in a high false detection rate and incomplete evaluation.
Temperature field distribution data is collected by an infrared thermal imager, and three-dimensional point cloud data is obtained by a laser scanner to generate a temperature gradient distribution map. Multi-scale feature pyramid network is used to enhance the edge information of the crack area, and the crack location, width and depth are output by fusion with a three-dimensional voxel mesh through an attention mechanism.
It enables accurate identification of building cracks, reduces false detection rate, and improves the comprehensiveness and accuracy of detection, and can identify minute cracks and accurately assess their depth.
Smart Images

Figure CN120846213B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of detecting building cracks, and more particularly to a method, system, electronic device, and storage medium for detecting building cracks. Background Technology
[0002] In the field of building structural safety monitoring, large buildings such as bridges, high-rise buildings, and historical buildings are prone to developing cracks of varying degrees under long-term loads, environmental erosion, and material aging. If these cracks are not detected and assessed in time, they may gradually expand, leading to a decrease in structural strength and even causing safety accidents such as collapse. Therefore, the industry urgently needs a highly efficient detection technology that can accurately identify the location of cracks, quantify crack width and depth, and is applicable to complex surface environments, in order to achieve dynamic monitoring and risk warning of the health status of building structures.
[0003] Currently, among the existing solutions for building crack detection, a representative one is the single-sensor detection scheme based on 3D laser scanning. This scheme uses a 3D laser scanner to perform a full-area scan of the building surface to acquire high-density 3D point cloud data; then, point cloud denoising and feature clustering algorithms are used to segment suspected crack areas, and finally, parameters such as the length and width of the cracks are calculated using the point cloud coordinates to form the detection result.
[0004] However, this existing solution has significant drawbacks. It relies solely on 3D point cloud data, making it sensitive to surface coverings (such as dust and paint layers) and prone to misidentifying uneven, non-cracked areas as cracks, resulting in a high false detection rate. It cannot capture the temperature anomalies caused by differences in air convection and heat conduction in cracked areas, making it difficult to identify shallow or indistinct surface cracks, especially those extending internally but not fully exposed on the surface, which are significantly missed. Furthermore, the dimensional parameters calculated solely from point cloud coordinates cannot accurately reflect the depth extension of cracks, leading to an incomplete assessment of the severity of crack damage. Summary of the Invention
[0005] The purpose of this application is to provide a method, system, electronic device, and storage medium for detecting building cracks, so as to solve the problem of poor detection effect of building cracks in the prior art.
[0006] To address the aforementioned technical problems, in a first aspect, this application provides a method for detecting building cracks, comprising:
[0007] Temperature field distribution data of the target building surface is collected by an infrared thermal imager, and three-dimensional point cloud data of the target building surface is collected simultaneously by a laser scanner.
[0008] Based on the temperature field distribution data, a temperature gradient distribution map of the target building surface is generated, and potential crack areas are located based on the phase difference analysis of the temperature gradient distribution map.
[0009] A multi-scale feature pyramid network is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map to enhance the edge information of the temperature anomaly region within the potential crack region;
[0010] The three-dimensional point cloud data corresponding to the potential crack region is voxelized to obtain a three-dimensional voxel mesh of the potential crack region.
[0011] The edge information of the enhanced temperature anomaly region is fused with the three-dimensional voxel mesh of the potential crack region through an attention mechanism, and the building crack detection result containing the location, width and depth of the crack is output.
[0012] Optionally, generating a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and locating potential crack areas based on phase difference analysis of the temperature gradient distribution map, includes:
[0013] The temperature values at each pixel location are extracted from the temperature field distribution data to form a temperature value sequence that changes over time.
[0014] Based on the first sub-region defined by the surface of the target building, the temperature value sequence is divided to obtain the temperature value sub-sequence corresponding to the first sub-region.
[0015] A periodic modulation signal is applied to each of the temperature numerical subsequences to form a periodically changing signal waveform;
[0016] Based on the periodic variation of the signal waveform, the temperature difference between adjacent pixel positions at the same time point is calculated. Gradient labels are assigned to the corresponding pixel positions based on the magnitude of the temperature difference. All gradient labels are arranged according to the actual positions of the pixel positions on the surface of the target building to form a temperature gradient distribution map.
[0017] In the temperature gradient distribution map, the boundary line of the adjacent second sub-region is selected as the reference line. The phase difference value of the signal waveform corresponding to the adjacent pixel positions on both sides of the reference line is calculated. When the phase difference value exceeds the average phase fluctuation range of the adjacent pixel positions, the adjacent pixel positions are marked. All marked pixel positions are connected to form a potential crack region.
[0018] Optionally, in the temperature gradient distribution map, the boundary line of adjacent second sub-regions is selected as a reference line, and the phase difference value of the signal waveform corresponding to the adjacent pixel positions on both sides of the reference line is calculated; when the phase difference value exceeds the average phase fluctuation range of the adjacent pixel positions, the adjacent pixel positions are marked, and all marked pixel positions are connected to form a potential crack region, including:
[0019] The temperature gradient distribution map is divided into multiple second sub-regions of the same size according to a preset size rule. The boundary line between adjacent second sub-regions is used as a reference line. At the same time, the coordinate range and extension direction of each reference line are recorded.
[0020] Based on the direction perpendicular to the extension direction on both sides of the reference line, the closest pixel positions on both sides are selected as adjacent pixel pairs across the sub-region, and the coordinates and corresponding signal waveform phases of the adjacent pixel pairs across the sub-region are recorded. The phase difference of the signal waveform corresponding to the two pixel positions in the adjacent pixel pairs across the sub-region is calculated as the first phase difference value.
[0021] Select adjacent pixel positions in the space within each second sub-region as adjacent pixel pairs within the sub-region, and calculate the phase difference of the signal waveform of all adjacent pixel pairs within the same second sub-region as the average phase fluctuation range of adjacent pixels within the sub-region.
[0022] The first phase difference value is compared with the average phase fluctuation range corresponding to the two pixel positions in the cross-sub-region adjacent pixel pair. When the first phase difference value exceeds any of the average phase fluctuation ranges, the two pixel positions in the cross-sub-region adjacent pixel pair are marked as marked pixel positions.
[0023] Based on the coordinate distribution of each of the marked pixel positions, consecutive marked pixel positions are connected sequentially to form a potential crack region.
[0024] Optionally, the step of acquiring temperature field distribution data of the target building surface using an infrared thermal imager and simultaneously acquiring three-dimensional point cloud data of the target building surface using a laser scanner includes:
[0025] The surface of the target building is divided into multiple first sub-regions, and the infrared thermal imager and the laser scanner are controlled to start collecting data simultaneously by triggering signals.
[0026] During the simultaneous acquisition process, the infrared thermal imager is controlled to continuously image the surface of the target building at a preset frame rate. When each frame is imaged, the detection sensitivity of the infrared thermal imager is adjusted based on the brightness change rate of the previous frame. At the same time, each sub-region is sequentially photographed in the spatial dimension. After multiple photographs of each sub-region, they are merged into the corresponding sub-region temperature image.
[0027] The laser scanner is controlled to project a scanning beam with spatial coding information onto the surface of the target building. The scanning beam moves sequentially along the horizontal and vertical directions of the target building surface, and the reflection signals after the scanning beam contacts each position on the target building surface and the corresponding spatial coding information are recorded. The reflection signals include return time and angle.
[0028] A high-precision clock synchronization module sends trigger pulse signals to the infrared thermal imager and the laser scanner in real time. When the infrared thermal imager captures and generates the temperature image of the sub-region, it embeds the time stamp corresponding to the pulse signal. When the laser scanner records each group of the reflection signals, it synchronously embeds the same time stamp corresponding to the pulse signal, so that the temperature image of the sub-region acquired by the pulse signal within the same trigger period is time-correlated with the reflection signal.
[0029] All the temperature images of the sub-regions carrying time stamps are stitched together according to the sub-region positions to form a sub-region temperature stitched image. The temperature value corresponding to each pixel position in the sub-region temperature stitched image is extracted to form temperature field distribution data covering the surface of the target building.
[0030] Based on the return time, the angle, and the spatial encoding information, combined with the time stamp and the location range of the corresponding sub-region temperature image, the position coordinates of the reflection point corresponding to each reflection signal in three-dimensional space are determined. All the position coordinates are arranged in the acquisition order to form three-dimensional point cloud data of the target building surface.
[0031] Optionally, the step of using a multi-scale feature pyramid network to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map to enhance the edge information of the temperature anomaly region within the potential crack region includes:
[0032] Extract the original potential crack image fragment corresponding to the potential crack region from the temperature gradient distribution map, record the pixel coordinate range and gradient identifier of each pixel position of the original potential crack image fragment, and input the original potential crack image fragment into a multi-scale feature pyramid network for super-resolution reconstruction.
[0033] During the super-resolution reconstruction process, the multi-scale feature pyramid network extracts a first-scale feature layer and a second-scale feature layer from the original potential crack image fragment according to a preset scale hierarchy. The first-scale feature layer retains the changes in the gradient identifier, and the second-scale feature layer retains the overall distribution of the gradient identifier. The positional correspondence between the feature layers of different scales is established based on the pixel coordinate range, with the first scale being smaller than the second scale.
[0034] Based on the positional correspondence, the first-scale feature layer and the second-scale feature layer are magnified step by step according to the magnification rules of super-resolution reconstruction, so that the size of the magnified first-scale feature layer matches the size of the magnified second-scale feature layer. The changes retained by the magnified first-scale feature layer are superimposed on the corresponding positions in the magnified second-scale feature layer to form a fused feature layer.
[0035] In the fusion feature layer, the average change magnitude of the gradient identifier of each pixel position around the neighboring pixel positions is calculated, the change magnitude of its own gradient identifier is compared with the average change magnitude, and the pixel value difference of the pixel position exceeding the average change magnitude is enhanced.
[0036] Based on the pixel coordinate range, all the fused feature layers are merged into a super-resolution reconstructed potential crack image. The contour of the region enhanced by pixel value difference in the super-resolution reconstructed potential crack image is extracted as the edge information of the enhanced temperature anomaly region.
[0037] Optionally, the step of voxelizing the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region includes:
[0038] Record the three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data;
[0039] Based on the three-dimensional spatial coordinates, determine the maximum and minimum coordinate ranges of the potential crack region in the three-dimensional space, and calculate the lengths of the potential crack region along the three coordinate axes in the space formed by the maximum and minimum coordinate ranges.
[0040] Based on the maximum coordinate range, the minimum coordinate range, and the preset side length of the cube unit, the three-dimensional space corresponding to the potential crack region is divided into multiple continuously arranged cube units, wherein the boundary of each cube unit is defined by coordinate values.
[0041] The three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data are compared with the coordinate range of each cube unit. When the three-dimensional spatial coordinate value of the reflection point falls within the coordinate range of any cube unit, it is determined that the reflection point belongs to the corresponding cube unit, and the number of reflection points contained in each cube unit is recorded.
[0042] All the cubic units are combined according to the arrangement order of the smaller cubic units in three-dimensional space to form a three-dimensional voxel mesh covering the potential crack region.
[0043] Optionally, the step of fusing the enhanced edge information of the temperature anomaly region with the three-dimensional voxel mesh of the potential crack region through an attention mechanism to output building crack detection results including the location, width, and depth of the cracks includes:
[0044] Based on the pixel position coordinates of the enhanced temperature anomaly region edge information and the spatial coordinates of the cubic units of the three-dimensional voxel mesh, a correspondence between the pixel position in the enhanced temperature anomaly region edge information and the small cubic units of the three-dimensional voxel mesh in spatial position is established, forming a corresponding spatial association unit.
[0045] Through an attention mechanism, the correlation degree value between the pixel value difference of the pixel position in each spatial correlation unit and the number of reflection points of the corresponding cubic unit is calculated. The spatial correlation unit with the correlation degree value exceeding the preset correlation degree threshold is given a first feature retention weight, and the spatial correlation unit with the correlation degree value not exceeding the preset correlation degree threshold is given a second feature retention weight. The first feature retention weight is greater than the second feature retention weight.
[0046] According to the corresponding feature retention weight, the enhanced temperature anomaly region edge information is fused with the three-dimensional voxel mesh to form a three-dimensional feature set. Continuous spatial correlation units with significant pixel value differences and an abnormal number of reflection points are extracted from the three-dimensional feature set, and the spatial coordinates of the continuous spatial correlation units are used as the location of the crack.
[0047] Calculate the pixel span of the continuous spatial correlation unit in the enhanced temperature anomaly region edge information along the direction perpendicular to its own edge, convert the pixel span into the actual physical size as the width of the crack, count the number of cubic units in the three-dimensional voxel mesh corresponding to the continuous spatial correlation unit in the direction perpendicular to the target building surface, and multiply the number of distributions by the side length of the cubic unit as the depth of the crack.
[0048] The location, width, and depth of the cracks are integrated to form the building crack detection results.
[0049] Secondly, this application provides a system for detecting building cracks, comprising:
[0050] The acquisition module is used to acquire temperature field distribution data of the target building surface through an infrared thermal imager and simultaneously acquire three-dimensional point cloud data of the target building surface through a laser scanner.
[0051] The positioning module is used to generate a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and to locate potential crack areas based on the phase difference analysis of the temperature gradient distribution map.
[0052] The reconstruction module is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map using a multi-scale feature pyramid network, so as to enhance the edge information of the temperature anomaly region in the potential crack region.
[0053] The processing module is used to perform voxelization processing on the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region.
[0054] The fusion module is used to fuse the enhanced edge information of the temperature anomaly region with the three-dimensional voxel mesh of the potential crack region through an attention mechanism, and output the building crack detection results including the location, width and depth of the crack.
[0055] Thirdly, this application provides an electronic device, comprising:
[0056] Memory, used to store computer programs;
[0057] A processor is configured to execute the computer program to implement the steps of a method for detecting building cracks as described in the first aspect above.
[0058] Fourthly, this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, can implement the steps of a building crack detection method as described in the first aspect above.
[0059] This application provides a method for detecting building cracks, which involves acquiring temperature field distribution data of the target building surface using an infrared thermal imager and simultaneously acquiring three-dimensional point cloud data of the target building surface using a laser scanner; generating a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and locating potential crack regions based on phase difference analysis of the temperature gradient distribution map; using a multi-scale feature pyramid network to perform super-resolution reconstruction of the potential crack regions in the temperature gradient distribution map to enhance the edge information of temperature anomaly regions within the potential crack regions; performing voxelization processing on the three-dimensional point cloud data corresponding to the potential crack regions to obtain a three-dimensional voxel mesh of the potential crack regions; and fusing the enhanced edge information of the temperature anomaly regions with the three-dimensional voxel mesh of the potential crack regions using an attention mechanism to output building crack detection results including the location, width, and depth of the cracks.
[0060] The technical solution of this application has the following beneficial effects:
[0061] This application simultaneously acquires temperature field distribution data and 3D point cloud data using an infrared thermal imager and a laser scanner, providing a multi-source data foundation for subsequent fusion analysis and enabling the synergistic utilization of temperature features and 3D structural features. Based on the temperature field distribution data, a temperature gradient distribution map is generated, and potential crack regions are located through phase difference analysis. Suspected crack regions are initially identified using temperature anomaly characteristics, narrowing the detection range. A multi-scale feature pyramid network is used for super-resolution reconstruction of potential crack regions, enhancing edge information in temperature anomaly areas and improving the clarity and recognizability of crack edge features. The 3D point cloud data of potential crack regions is voxelized to obtain a 3D voxel mesh, transforming the discrete point cloud into a structured mesh, facilitating subsequent calculation of 3D crack parameters. An attention mechanism is used to fuse the enhanced edge information with the 3D voxel mesh, achieving precise correlation between temperature features and 3D structural features, outputting crack detection results including location, width, and depth, improving the comprehensiveness and accuracy of the detection.
[0062] Furthermore, this application extracts the temperature value sequence of each pixel location based on the temperature field distribution data, divides the target building surface into temperature value sub-sequences according to the first sub-region, applies a periodic modulation signal to each sub-sequence to form a signal waveform, calculates the temperature value difference between adjacent pixel locations based on the signal waveform and assigns gradient labels, and arranges them to form a temperature gradient distribution map; selects the boundary line of the adjacent second sub-region as a reference line in the map, calculates the phase difference of the signal waveform between adjacent pixel locations on both sides of the reference line, marks the corresponding pixel location when the phase difference exceeds the average phase fluctuation range, and connects all marked locations to form a potential crack area.
[0063] This application achieves precise location of potential crack regions by dividing the temperature numerical sequence into sub-regions and periodically modulating it, generating a temperature gradient distribution map by combining the temperature difference, and then marking the abnormal position based on the phase difference analysis of the pixels on both sides of the reference line. This improves the targeting and accuracy of potential crack region location and provides a reliable regional basis for subsequent refined detection.
[0064] These or other aspects of this application will become more apparent in the following description of the embodiments. Attached Figure Description
[0065] To more clearly illustrate the technical solutions of the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0066] Figure 1 A schematic flowchart illustrating a method for detecting building cracks provided in an embodiment of this application;
[0067] Figure 2 A scene diagram illustrating a method for detecting building cracks provided in an embodiment of this application;
[0068] Figure 3 This is a schematic diagram of the structure of a building crack detection system provided in an embodiment of this application;
[0069] Figure 4 This is a schematic diagram of the structure of a computing device provided in an embodiment of this application. Detailed Implementation
[0070] Existing building crack detection solutions based on 3D laser scanning have significant limitations due to their reliance on data from a single sensor: they are prone to misjudging non-crack areas due to the influence of building surface coverings, have difficulty identifying minute cracks with indistinct surface morphology, and their assessment of crack depth is not comprehensive enough, making it difficult to meet the requirements of structural safety monitoring for detection accuracy and completeness.
[0071] To address this issue, this application proposes a building crack detection scheme that integrates infrared and laser data. By simultaneously acquiring temperature field distribution data and 3D point cloud data of the target building surface, it utilizes the phase difference in the temperature gradient distribution map to locate potential crack areas, enhances temperature anomaly edge information, and fuses it with a 3D voxel mesh. The final output includes the crack location, width, and depth. This scheme compensates for the deficiencies of single-data sources through multi-source data collaboration—temperature features reduce misjudgments caused by surface coverings, and 3D structural information improves the accuracy of depth assessment. The fusion of these two sources enables precise identification of minute cracks, comprehensively solving the problems of missed detections, false detections, and incomplete assessments in existing schemes.
[0072] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments. Obviously, the described embodiments are merely some embodiments of the present application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0073] The core of this application is to provide a method for detecting building cracks, and a flowchart of one specific implementation is shown below. Figure 1 As shown, the method includes:
[0074] S101. Collect temperature field distribution data of the target building surface using an infrared thermal imager, and simultaneously collect three-dimensional point cloud data of the target building surface using a laser scanner.
[0075] Optionally, step S101 involves acquiring temperature field distribution data of the target building surface using an infrared thermal imager and simultaneously acquiring three-dimensional point cloud data of the target building surface using a laser scanner, including:
[0076] Step 1011: Divide the surface of the target building into multiple first sub-regions, and control the infrared thermal imager and the laser scanner to start collecting data simultaneously through a trigger signal.
[0077] Step 1012: During the simultaneous acquisition process, the infrared thermal imager is controlled to continuously image the surface of the target building at a preset frame rate. During each frame of imaging, the detection sensitivity of the infrared thermal imager is adjusted based on the brightness change rate of the previous frame. At the same time, each sub-region is sequentially photographed in the spatial dimension. After multiple photographs of each sub-region, they are merged into the corresponding sub-region temperature image.
[0078] Step 1013: Control the laser scanner to project a scanning beam with spatial coding information onto the target building surface. The scanning beam moves sequentially along the horizontal and vertical directions of the target building surface, and records the reflection signals and corresponding spatial coding information after the scanning beam contacts each position on the target building surface. The reflection signals include return time and angle. The sequential movement in the horizontal and vertical directions means that, taking a sub-region of the target building surface (e.g., sub-region 2 of building A, 8×8m) as an example, first, control the scanning beam to move horizontally (parallel to the ground) from the left boundary of the sub-region to the right at a preset speed (e.g., 0.5m / s) until it reaches the right boundary, completing one horizontal scan. Then, the beam moves downwards by a small step (e.g., 0.1m, to ensure no gap between adjacent scan lines) in the vertical direction (perpendicular to the ground). Next, the beam moves in the opposite direction horizontally from the right boundary to the left, completing the second scan. Repeat the cycle of "horizontal scan → small vertical step movement → reverse horizontal scan" until the beam covers the entire vertical range (8m height) of the sub-region. Through this "serpentine" movement path, the scanning beam can evenly cover every position in the sub-region, ensuring that no reflected signal is missed.
[0079] Step 1014: A trigger pulse signal is sent in real time to the infrared thermal imager and the laser scanner via a high-precision clock synchronization module. When the infrared thermal imager captures and generates the temperature image of the sub-region, a time stamp corresponding to the pulse signal is embedded. When the laser scanner records each group of reflected signals, the same time stamp corresponding to the pulse signal is embedded synchronously, so that the temperature image of the sub-region acquired by the pulse signal within the same trigger period is time-correlated with the reflected signal. The embedding for the infrared thermal imager means that when the infrared thermal imager captures and generates the temperature image of the sub-region, a "time stamp" field is added to the metadata of the image, and the value of this field is consistent with the time of the currently received pulse signal. The embedding for the laser scanner means that when the laser scanner records each group of reflected signals, a "time stamp" parameter is added to the data structure of that group of signals, and its value is exactly the same as the time of the pulse signal received at the same moment.
[0080] Step 1015: Stitch together all the sub-region temperature images carrying time stamps according to the sub-region positions to form a sub-region temperature stitched image. Extract the temperature value corresponding to each pixel position in the sub-region temperature stitched image to form temperature field distribution data covering the surface of the target building.
[0081] Step 1016: Based on the return time, the angle, and the spatial encoding information, and combined with the time stamp and the position range of the corresponding sub-region temperature image, determine the position coordinates of the reflection point corresponding to each reflection signal in three-dimensional space, and arrange all the position coordinates in the acquisition order to form three-dimensional point cloud data of the target building surface.
[0082] In the above scheme, the trigger signal refers to the synchronization control command used to start the acquisition action of the infrared thermal imager and the laser scanner; the preset frame rate refers to the number of frames captured per second by the infrared thermal imager, controlling the imaging interval; the brightness change rate refers to the brightness change amplitude of adjacent frame pixels, used to adjust the device sensitivity; spatial coding information refers to the unique identifier of the scanning beam, used to match the reflection signal with the position; the high-precision clock synchronization module refers to the module used to generate high-precision time pulses; the trigger pulse signal is a synchronization pulse with a fixed interval, used to mark the acquisition time; the time stamp refers to the time information embedded in the data, realizing the time correlation of data from different devices; the temperature field distribution data refers to the coordinates of all pixels on the building surface and their corresponding temperature values; and the three-dimensional point cloud data is the collection of the three-dimensional coordinates of all reflection points.
[0083] In this application example, firstly, step 1011 measures the dimensions of the south exterior wall of building A as 32m wide × 8m high. The south exterior wall is then divided into four sub-regions according to the 8m × 8m rule. The boundary coordinates of each sub-region are recorded. Next, a trigger signal is generated and simultaneously sent to infrared thermal imager B and laser scanner C. Both devices start acquiring data simultaneously upon receiving the signal, ensuring that the acquisition time for the same sub-region is consistent. For example, acquisition of sub-region 1 is initiated by the same trigger signal, avoiding misalignment of acquisition times between B and C.
[0084] Next, in step 1012, the preset frame rate of infrared thermal imager B is set to 25 frames / second (i.e., 1 frame is captured every 40ms, 1÷25=0.04s), so that it continuously images the four sub-regions of building A at this frequency. After each frame is captured, the brightness change rate between the current frame and the previous frame is calculated. The formula can be brightness change rate = (average brightness of the current frame - average brightness of the previous frame) / average brightness of the previous frame. If the change rate is >10% (e.g., the average brightness of the third frame of sub-region 2 is 21, and the average brightness of the second frame is 19, the change rate = (21-19) / 19≈10.5%), then the detection sensitivity of B is increased; if it is <5%, then the sensitivity is decreased. Simultaneously, images are captured in the order of sub-regions 1→2→3→4, with each sub-region captured 6 times. The temperature values of corresponding pixels in the 6 frames are then averaged arithmetically (e.g., if a pixel's temperature is 22℃, 23℃, 22℃, 24℃, 23℃, 22℃ in 6 frames, the average is approximately 136 ÷ 6 ≈ 22.67℃), and this average is combined to form the temperature image for that sub-region. The generated sub-region temperature images will be used for stitching in 1015.
[0085] Next, in step 1013, the laser scanner C projects a scanning beam carrying a spatial code onto building A. Sub-regions 1-4 correspond to 100MHz, 200MHz, 300MHz, and 400MHz codes, respectively (used to distinguish the sub-regions to which the reflected signals belong). The beam is driven to move horizontally (parallel to the ground) at a speed of 0.5m / s, covering the width of the sub-region (8m) in 16 seconds (8÷0.5=16). After completing one line of scanning, it moves 0.1m vertically (i.e., perpendicular to the ground) and then scans horizontally in the reverse direction, forming a grid-like path. At the same time, the reflected signals after the beam contacts each point on the building surface are recorded, including the return time (e.g., 1.2μs), the emission angle (e.g., 30°, the angle with the horizontal direction), and the corresponding spatial code (e.g., 200MHz, corresponding to sub-region 2). The generated reflected signals will be used in step 1016 to calculate the three-dimensional coordinates.
[0086] Then, in step 1014, the high-precision clock synchronization module D generates trigger pulse signals at fixed intervals of 0.5ms (i.e., 500μs) and sends them in real time to the infrared thermal imager B and the laser scanner C. When B captures and generates a sub-region temperature image, it embeds the time stamp corresponding to the current pulse into the image data (e.g., the time stamp of the 4th pulse T2 = 0.5ms × 4 = 2ms = 0.002s). When C records each set of reflection signals, it synchronously embeds the same time stamp (e.g., T2). For example, the temperature image of sub-region 2 captured by B at time T2 and the reflection signal of sub-region 2 recorded by C at time T2 both carry T2, realizing the time correlation between the two. The time stamp will be used in steps 1015 and 1016 to match the position range of the temperature image and the reflection signal.
[0087] Subsequently, in step 1015, all time-stamped sub-region temperature images are collected. Based on the sub-region boundary coordinates recorded in step 1011 (e.g., sub-region 1 on the left, sub-region 2 on the right), the images are stitched together to form a complete image (32m × 8m) covering the south exterior wall of building A. The coordinates of each pixel in the stitched image are extracted (1024 pixels horizontally correspond to 32m, each pixel represents 32 ÷ 1024 = 0.03125m, e.g., pixel (100, 200) corresponds to actual X = 100 × 0.03125 = 3.125m, Y = 200 × 0.03125 = 6.25m) and the corresponding temperature value (e.g., 25℃). These are then arranged in coordinate order to form temperature field distribution data. This data will be used to generate a temperature gradient distribution map later.
[0088] Finally, the three-dimensional coordinates are calculated based on the reflected signal parameters recorded by the laser scanner C in step 1016. The formula used to calculate the distance using the return time is: d = c × t / 2, where d is the distance. Let t be the speed of light and t be the return time, for example... ,but Based on the emission angle θ=30°, the horizontal distance X=d×cosθ≈180×0.866≈155.88m and the vertical distance Y=d×sinθ=180×0.5=90m are calculated. According to the location range (8-16m wide) of sub-region 2 associated with time stamp T2, the Z coordinate (height) is determined to be 1.2m. Next, the three-dimensional coordinates (X,Y,Z) of all reflection points are arranged in the acquisition order to form the three-dimensional point cloud data of the south exterior wall of building A.
[0089] In practical applications, the exterior wall of building A (32m × 8m) is inspected. The wall is divided into four 8m × 8m sub-regions (numbered 1-4, area calculation: 32 × 8 = 256m², 256 ÷ 4 = 64m² = 8m × 8m). Infrared thermal imager B and laser scanner C are synchronously activated via a trigger signal. B takes pictures at a preset frame rate of 25 frames per second (generating 25 images per second). The brightness change rate between the first and second frames is calculated: if the average brightness of the first frame is 18 (grayscale value) and the second frame is 20, then the change rate = (20-18) / 18 ≈ 11.1% (exceeding the 10% threshold), thus improving sensitivity. Each sub-region is photographed six times. The temperature of a certain pixel in the six photographs is 22℃, 23℃, 22℃, 24℃, 23℃, and 22℃, averaging 22.67℃, which are then combined into a sub-region temperature image. C projects a spatially encoded beam (sub-regions 1-4 correspond to 10...). Scanning 8m horizontally (0-400MHz) takes 16 seconds (8÷0.5=16) at a speed of 0.5m / s, and the same applies to the vertical direction. Record the return time of a reflection point as 1.2μs, the emission angle as 30°, and the encoding as 200MHz (corresponding to sub-region 2). D sends pulses at 0.5ms intervals (the 4th pulse time marker T2=0.5×4=2ms=0.002s). The temperature image of sub-region 2 captured by B and the reflection signal recorded by C are both embedded in T2. The four sub-region temperature images are stitched together in order from 1 to 4 (32m horizontally corresponds to 1024 pixels, each pixel is 32÷1024=0.03125m). Extract the coordinates of 1024×768 pixels (e.g., (100,200) corresponds to actual positions 3.125m, 6.25m) and temperature values (20-35℃) to form temperature field distribution data. Calculate the three-dimensional coordinates based on the reflection signal from C. X = d × cos30° ≈ 180 × 0.866 ≈ 155.88m, Y = d × sin30° = 180 × 0.5 = 90m, height Z = 1.2m. All coordinates are arranged in the order of acquisition to form three-dimensional point cloud data.
[0090] The S101 overall solution described above achieves regionalized management of data acquisition through sub-region division, and trigger signals ensure synchronous startup of B and C; dynamically adjusts sensitivity to improve temperature image quality, and averages multiple shots to reduce errors; coded scanning achieves precise matching of reflected signals with sub-regions, and grid paths cover the entire area; time stamps associate temperature data with point cloud data to eliminate time deviations; image stitching forms a complete temperature field, and coordinate calculation generates a structured point cloud; the final generated temperature field distribution data and 3D point cloud data provide synchronous and complete basic data for subsequent temperature gradient analysis and voxelization processing, ensuring the accuracy of crack detection.
[0091] S102. Based on the temperature field distribution data, generate a temperature gradient distribution map of the target building surface, and locate potential crack areas based on the phase difference analysis of the temperature gradient distribution map.
[0092] Optionally, step S102, generating a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and locating potential crack areas based on phase difference analysis of the temperature gradient distribution map, includes:
[0093] Step 1021: Extract the temperature values of each pixel location from the temperature field distribution data to form a temperature value sequence that changes over time.
[0094] Step 1022: Based on the first sub-region of the target building surface, divide the temperature value sequence to obtain the temperature value sub-sequence corresponding to the first sub-region.
[0095] Step 1023: Apply a periodic modulation signal to each of the temperature numerical subsequences so that the temperature numerical subsequences form a periodically changing signal waveform.
[0096] Step 1024: Calculate the temperature difference between adjacent pixel positions at the same time point according to the periodic change pattern of the signal waveform. Assign gradient labels to the corresponding pixel positions based on the magnitude of the temperature difference. Arrange all the gradient labels according to the actual positions of the pixel positions on the surface of the target building to form a temperature gradient distribution map.
[0097] Step 1025: In the temperature gradient distribution map, select the boundary line of the adjacent second sub-region as the reference line, calculate the phase difference value of the signal waveform corresponding to the adjacent pixel positions on both sides of the reference line, and when the phase difference value exceeds the average phase fluctuation range of the adjacent pixel positions, mark the adjacent pixel positions, and connect all the marked pixel positions to form a potential crack region.
[0098] Step 1025 may specifically include the following process: dividing the temperature gradient distribution map into multiple second sub-regions of equal size according to a preset size rule; using the boundary line between adjacent second sub-regions as a reference line; and recording the coordinate range and extension direction of each reference line; selecting the closest pixel positions on both sides of the reference line based on the direction perpendicular to the extension direction as adjacent pixel pairs across sub-regions; recording the coordinates and corresponding signal waveform phase of the adjacent pixel pairs across sub-regions; calculating the phase difference of the signal waveform corresponding to the two pixel positions in the adjacent pixel pairs across sub-regions as the first phase difference value; selecting adjacent pixel positions in the internal space of each second sub-region as adjacent pixel pairs within the sub-region; and statistically analyzing the phase difference of the signal waveform of all adjacent pixel pairs within the same second sub-region. The first phase difference is used as the average phase fluctuation range of adjacent pixels within the sub-region. The first phase difference is compared with the average phase fluctuation range corresponding to the two pixel positions in the cross-sub-region adjacent pixel pair. When the first phase difference exceeds any of the average phase fluctuation ranges, the two pixel positions in the cross-sub-region adjacent pixel pair are marked as marked pixel positions. Based on the coordinate distribution of each marked pixel position, the consecutive marked pixel positions are connected sequentially to form a potential crack region. Here, "consecutive" specifically refers to the adjacency of the marked pixel positions in spatial distribution. That is, the coordinates of multiple marked pixels are sequentially adjacent in the actual position on the building surface without obvious interruption. Specifically, when the X coordinate or Y coordinate of the marked pixel increases / decreases in sequence and the distance between adjacent pixels does not exceed the actual size of a single pixel, it is determined to be "consecutive".
[0099] In the above scheme, the temperature value sequence can refer to the sequence of temperature values of a single pixel position at different time points extracted from temperature field distribution data, arranged in chronological order; the periodic modulation signal can refer to a signal that changes according to a fixed period, used to make the temperature value subsequence exhibit periodic fluctuations; the signal waveform can refer to the periodic change curve formed by the modulation of the temperature value subsequence; the gradient label can refer to the label assigned to the pixel according to the magnitude of the temperature value difference; the temperature gradient distribution map can refer to an image arranged according to the actual position of the pixels, using gradient labels to present the temperature change differences; the reference line refers to the boundary line between adjacent second sub-regions, serving as the baseline for phase difference analysis; the phase of the signal waveform can refer to the position of the signal waveform in the period; the marked pixel position can refer to the pixel in the cross-sub-region adjacent pixel pair where the first phase difference exceeds the average phase fluctuation range; the potential crack region can refer to the region formed by connecting all consecutive marked pixel positions.
[0100] In this application example, firstly, in step 1021, the temperature value of each pixel at consecutive time points is extracted from the generated temperature field distribution data. For example, the temperature field data of the south exterior wall of building A contains 10 acquisition time points (T1=0.1s to T10=1.0s, with an interval of 0.1s). The temperature values of pixels (100,200) at these time points are extracted and arranged in chronological order to form a temperature value sequence [22.0℃,22.5℃,...,23.7℃]. This sequence will be used in step 1022 to classify the data according to the first sub-region.
[0101] Next, in step 1022, based on the division of the first sub-region (e.g., four 8m×8m regions of building A), the region to which the pixel belongs is determined by its actual position. For example, the actual X coordinate of pixel (100,200) is 3.125m (100×0.03125), which is within the range of 0-8m, and belongs to the first sub-region 1. The temperature value sequences of all pixels in this region are grouped together to form the temperature value sub-sequence of the first sub-region 1. This sub-sequence will be used for the modulation processing in step 1023.
[0102] Then, the modulation signal is defined as follows through step 1023. Where A = 0.5℃, T = 10s, and t is time (e.g., T3 = 0.3s). Next, the modulated signal is superimposed on each temperature value in the temperature numerical subsequence (e.g., 23.0℃ + 0.094℃ = 23.094℃) to form a periodic signal waveform from the temperature data. For example, the subsequence of the first sub-region 1, after modulation, exhibits a 10s periodic fluctuation; this waveform will be used for the temperature difference calculation in step 1024 and the phase analysis in step 1025.
[0103] Then, in step 1024, the same time point (e.g., T5 = 0.5s) is selected, and the temperature difference between adjacent pixels is calculated. For example, the difference between pixels (100, 200) and (101, 200) is 1.4℃, and gradient labels are assigned according to the range of the difference (1.4℃ corresponds to "medium gradient"). Finally, all labels are arranged according to the actual pixel position (e.g., 3.125m, 2.08m) to form a temperature gradient distribution map, which will be used for locating potential crack areas in step 1025.
[0104] Finally, the second sub-region is divided into 2m×2m areas in step 1025, resulting in 64 pixels × 192 pixels. Reference lines for adjacent regions are determined (e.g., X=8m, extending perpendicularly). Adjacent pixel pairs across sub-regions are selected (e.g., (256,300) and (257,300)). (256,300) belongs to the region to the left of the reference line, and (257,300) belongs to the region to the right of the reference line. The signal waveform phases corresponding to these two pixels are extracted to be 30° and 65° respectively, and the first phase difference is calculated to be 35°. The phase difference values of adjacent pixel pairs in the regions to the left and right of the reference line are statistically analyzed. For example, the phase difference range in the region to the left of the reference line is 5°-15°, forming the first average phase fluctuation range; the phase difference range in the region to the right of the reference line is 6°-14°, forming the second average phase fluctuation range. The first phase difference value of 35° is compared with the two average phase fluctuation ranges respectively. Since 35° exceeds both the 5°-15° range of sub-region M and the 6°-14° range of sub-region N, the two pixel positions (256,300) and (257,300) are marked. Connecting the consecutive marked pixels forms a potential crack region, which will be used for subsequent super-resolution reconstruction.
[0105] In practical applications, taking the temperature field distribution data (1024 pixels × 768 pixels, each pixel corresponds to an actual size of 0.03125m × 0.03125m, calculation: 32m ÷ 1024 pixels = 0.03125m / pixel, 8m ÷ 768 pixels ≈ 0.0104m / pixel) of the south exterior wall (32m wide × 8m high) of building A as an example: extracting pixel (100, 200) (corresponding to the actual position: X = 100 × 0.03125 = 3.125m, Y = 200 × 0.0104 ≈ 2.08m) at 10 time points (T The temperature value sequence from T1=0.1s to T10=1.0s (with an interval of 0.1s) is: [22.0℃, 22.5℃, 23.0℃, 22.8℃, 23.2℃, 23.5℃, 23.3℃, 23.8℃, 24.0℃, 23.7℃]. Based on the boundary of the first sub-region 1 (0-8m wide, 0-8m high), pixels (100, 200) are determined to belong to this region. Their temperature value sequence is then grouped with the sequences of other 255×255 pixels within the region into the temperature value sub-sequence of the first sub-region 1, and a modulation signal is applied to this sub-sequence. Where A=0.5℃, T=10s, for example, when T3=0.3s, s(t)=0.5×sin(2π×0.3 / 10)≈0.094℃, the original temperature of 23.0℃ is modulated to 23.094℃, forming a periodic signal waveform. Selecting T5=0.5s, calculate the temperature difference between the 23.2℃ corresponding to pixel (100, 200) and the 21.8℃ corresponding to the horizontally adjacent pixel (101, 200): 23.2-21.8=1.4℃. According to the standard (<0.5℃ is "low", 0.5-2.0℃ is "medium", >2.0℃ is "high"), assign a "medium gradient" label. Arrange all labels according to the actual pixel positions to form a temperature gradient distribution map. Divide the temperature gradient distribution map into a second sub-region of 2m×2m (each region corresponds to 64 pixels × 192 pixels, calculated as follows: 2 m ÷ 0.03125m / pixel = 64 pixels, 2m ÷ 0.0104m / pixel ≈ 192 pixels), the boundary line of adjacent regions (e.g., at X=8m) is used as the reference line (extending in the vertical direction, Y=0-8m); take the horizontally adjacent pixels (256,300) (X=8.0m) and (257,300) (X=8.03125m) on both sides of the reference line as adjacent pixel pairs across sub-regions, with signal waveform phases of 30° and 65° respectively, and the first phase difference = 65°-30°=35°; count the phase difference values (5°, 8°, 12°, 15°) of adjacent pixel pairs in the second sub-region, with an average phase fluctuation range of 5°-15°; if 35° exceeds the range, mark these two pixels; connect the marked pixels continuously distributed along the reference line to form a potential crack region for subsequent super-resolution reconstruction.
[0106] The above-described S102 overall scheme achieves regionalized temporal management of temperature data by extracting temperature numerical sequences and dividing them into first sub-regions; applying modulation signals to make temperature changes periodic, facilitating subsequent phase analysis; calculating temperature differences and assigning gradient labels to intuitively present temperature change differences and form a temperature gradient distribution map; and accurately marking abnormal pixel positions based on the reference line and phase difference analysis of the second sub-region, connecting them to form potential crack regions, providing targeted areas for subsequent crack detection, reducing invalid detection ranges, and improving detection efficiency.
[0107] S103. A multi-scale feature pyramid network is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map to enhance the edge information of the temperature anomaly region within the potential crack region.
[0108] Optionally, step S103 involves using a multi-scale feature pyramid network to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map, thereby enhancing the edge information of the temperature anomaly region within the potential crack region, including:
[0109] Step 1031: Extract the original potential crack image fragment corresponding to the potential crack region from the temperature gradient distribution map, record the pixel coordinate range of the original potential crack image fragment and the gradient identifier of the pixel position in each fragment, and input the original potential crack image fragment into a multi-scale feature pyramid network for super-resolution reconstruction.
[0110] Step 1032: During the super-resolution reconstruction process, the multi-scale feature pyramid network extracts a first-scale feature layer and a second-scale feature layer from the original potential crack image fragment according to a preset scale level. The first-scale feature layer retains the changes in the gradient identifier, and the second-scale feature layer retains the overall distribution of the gradient identifier. The positional correspondence between the feature layers of different scale levels is established based on the pixel coordinate range, with the first scale being smaller than the second scale.
[0111] For example, for the first-scale feature layer (smaller scale, such as 1×1 pixel granularity), "preserving the changes in gradient labels" is achieved through shallow feature extraction of the network—using small-sized convolutional kernels (such as 3×3) to perform local convolution operations on the original image fragments, focusing on capturing the gradient label differences between individual pixels and their neighboring pixels. For example, in the potential crack region of building A, the gradient label of pixel (280, 320) is "high," and the neighboring pixel (281, 320) is "medium." The first-scale feature layer records this "high → medium" change (such as a difference of 0.3) and preserves the original position information of each pixel, ensuring that local details are not lost. For the second-scale feature layer (larger scale, such as 2×2 pixel granularity), "preserving the overall distribution of gradient labels" is achieved through deep feature extraction of the network—using large-sized convolutional kernels (such as 7×7) or pooling operations (such as 2×2 max pooling) to perform region aggregation on the image, ignoring the small fluctuations of individual pixels, and focusing on statistically analyzing the continuous distribution trend of gradient labels within a certain range. For example, in the X=280-320 pixel range of building A, although individual pixels may be "medium", the overall gradient is mainly "high" and continuously distributed. The second-scale feature layer will retain this overall distribution feature and record it as "X=280-320 has a continuous high gradient band".
[0112] Step 1033: Based on the positional correspondence, the first scale-level feature layer and the second scale-level feature layer are magnified step by step according to the magnification rules of super-resolution reconstruction, so that the size of the magnified first scale-level feature layer matches the size of the magnified second scale-level feature layer, and the changes retained by the magnified first scale-level feature layer are superimposed on the corresponding positions in the magnified second scale-level feature layer to form a fused feature layer.
[0113] Step 1034: In the fusion feature layer, calculate the average change magnitude of the gradient identifier of each pixel position around the neighboring pixel positions, compare the change magnitude of its own gradient identifier with the average change magnitude, and enhance the pixel value difference of pixel positions that exceed the average change magnitude.
[0114] The term "adjacent" specifically refers to the pixel positions that are directly adjacent to the target pixel in space. Specifically, it refers to the nearest pixels in eight directions surrounding the target pixel, including the four positive directions (up, down, left, and right) and the four diagonal directions (upper left, upper right, lower left, and lower right). For example, for pixel (100, 100), its "adjacent" pixels are (99, 99), (99, 100), (99, 101), (100, 99), (100, 101), (101, 99), (101, 100), and (101, 101). These pixels are all a single pixel away from the target pixel (e.g., a horizontal or vertical spacing of one pixel), ensuring that the most direct gradient change environment around the target pixel is reflected. "Enhancement" refers to a processing method that, when the gradient change amplitude of the target pixel exceeds the average change amplitude of its surrounding adjacent pixels, increases the gradient difference between the pixel and its surrounding pixels, making the edge contour of the pixel more prominent. For example, if the original gradient label of the target pixel is "high", the surrounding pixels are mostly "medium" or "low", and the change range (0.5) is greater than the average value (0.2875), then its gradient label is upgraded to "extremely high", while keeping the labels of the surrounding pixels unchanged.
[0115] Step 1035: Based on the pixel coordinate range, merge all the fused feature layers into a super-resolution reconstructed potential crack image, and extract the region contour enhanced by pixel value difference in the super-resolution reconstructed potential crack image as the edge information of the enhanced temperature anomaly region.
[0116] In the above scheme, the multi-scale feature pyramid network is a processing network for image reconstruction, which can extract and fuse features of different scales from the image; the original potential crack image segment refers to the image part containing the potential crack region extracted from the temperature gradient distribution map, including the pixel coordinate range of the region and the gradient label of each pixel; the gradient label is the low, medium and high gradient information assigned to the pixel; the position correspondence refers to the mapping relationship of pixel positions in different scale feature layers, ensuring that features at the same actual position can be accurately matched; the magnification rule of super-resolution reconstruction refers to the proportional rule for magnifying the size of the feature layer; the fused feature layer is the feature layer formed by superimposing the magnified first and second scale feature layers; pixel value difference enhancement refers to increasing the gradient label difference between the pixel itself and the surrounding pixels, making the edges more obvious.
[0117] In this application example, firstly, in step 1031, image segments are extracted from the generated temperature gradient distribution map according to the coordinate range of the potential crack region (e.g., X: 250-350, Y: 300-400 for building A). The horizontal pixel count is 350-250+1=101 (including the first and last pixels), and the vertical count is similar. The actual size is 101 pixels × 0.03125m / pixel ≈ 3.156m, consistent with the original region size. The gradient label of each pixel in the segment is recorded (e.g., (280, 320) is "height"), and the segment is input into the multi-scale feature pyramid network. This segment serves as the input data for the network, providing raw material for feature extraction in step 1032.
[0118] Next, features are extracted in the multi-scale feature pyramid network according to a preset scale level in step 1032. The first scale level (1×1 pixel granularity) extracts the gradient change of a single pixel (e.g., the gradient difference of 0.3 between pixels (280,320) and (281,320). The second scale level (2×2 pixel granularity) extracts the overall gradient distribution of the region (e.g., the "high" gradient band of X:280-320). Based on the pixel coordinate range of the original fragment, a position correspondence is established, where the first scale pixel (x,y) corresponds to the second scale pixel (round(x / 2),round(y / 2)) (because the second scale granularity is 2×2, it needs to be divided by 2 and rounded). For example, the first scale (280,320) corresponds to the second scale (140,160). These feature layers and correspondences will be used for scale matching and fusion in step 1033.
[0119] Next, the feature layers are processed according to the magnification rules (magnification by 2x) of super-resolution reconstruction in step 1033. The first-scale feature layer (101×101 pixels) is magnified to a size of 101×2=202 pixels, and the second-scale feature layer (51×51 pixels) needs to be magnified to 202 pixels (51×4=204, since 204 is closest to 202). Zero padding is used to make both 204×204 pixels to match the size. Based on the positional correspondence in step 1032, the changes in the first-scale feature layer (such as the gradient fluctuation of (20,20)) are superimposed onto the corresponding positions in the second-scale feature layer (such as (20,20)) to form a fused feature layer. This fused feature layer will be used for pixel difference enhancement in step 1034.
[0120] Then, in step 1034, in the fusion feature layer, for each pixel (e.g., (100,100)), eight neighboring pixels (top, bottom, left, right, and four diagonals) are selected, and the gradient change amplitude is defined as follows: 0.2 for "low" to "medium", 0.4 for "medium" to "high", and 0.1 for fluctuation within the same identifier. For example, the change amplitude of adjacent pixels is 0.2, 0.3, 0.2, 0.4, 0.3, 0.2, 0.3, 0.4, according to the formula... ,in, The average value is calculated based on the change magnitude between the pixel and its i-th neighboring pixel. If the change in the target pixel itself (e.g., 0.5) is greater than If the gradient label is enhanced (e.g., from "high" to "extremely high"), the enhanced fusion feature layer will be used for image merging in step 1035.
[0121] Finally, based on the pixel coordinate range (X:250-350, Y:300-400) of the original potential crack image fragment in step 1035, the fused feature layer processed in step 1034 is aligned and merged to form a 204×204 pixel super-resolution image (actual size per pixel = 3.156m ÷ 204 ≈ 0.0156m, resolution improvement). The continuous contours of the "extremely high" gradient region (such as lines along X:500-600, Y:600-700) are extracted from this image as the edge information of the enhanced temperature anomaly region. This information will be directly used for the fusion processing with the three-dimensional voxel mesh of the potential crack region in step S105.
[0122] In practical applications, taking the potential crack area on the south exterior wall of building A as an example, each pixel in the temperature gradient distribution map corresponds to an actual size of 0.03125m × 0.03125m. The original image segment corresponding to the potential crack area is extracted, with pixel coordinates ranging from X: 250-350 (horizontal pixel count = 350-250+1 = 101 pixels) to Y: 300-400 (vertical pixel count = 400-300+1 = 101 pixels). The actual size is approximately 101 × 0.03125m ≈ 3.156m (horizontal). 1×0.03125m≈3.156m (vertical); each pixel carries a gradient label of "low", "medium" or "high", and the segment is fed into a multi-scale feature pyramid network; the multi-scale feature pyramid network extracts the first-scale feature layer and the second-scale feature layer, wherein the size of the first-scale feature layer is 101×101 pixels, preserving the gradient difference between pixels (280,320) and (281,320): the difference between "high" and "medium" is 0.3), and the size of the second-scale feature layer is 51×51 pixels, preserving... Leave a continuous gradient distribution of X: 280-320; establish positional correspondence based on coordinate range: the pixel coordinates of the first scale (x, y) correspond to the pixel coordinates of the second scale (round(x / 2), round(y / 2)), such as the first scale (280, 320) corresponding to the second scale (140, 160); process according to the magnification rule (such as magnification by 2 times): the size of the first scale feature layer (101×101 pixels) after magnification = 101×2 = 202 pixels (202×202), the size of the second scale feature layer (51× The pixel (51 pixels) is enlarged to a size of 51 × 4 = 204 pixels (204 × 204). Zero-padding at the edges ensures both are 204 × 204 pixels. Based on positional correspondence, the changes at the first scale (20, 20) are superimposed on the changes at the second scale (20, 20) to form a fused feature layer. For pixel (100, 100) in the fused feature layer (gradient change amplitude 0.5), eight neighboring pixels with change amplitudes of 0.2, 0.3, 0.2, 0.4, 0.3, 0.2, 0.3, and 0.4 are selected, and their average values are calculated using the formula. Since 0.5 > 0.2875, the gradient label of the pixel is enhanced from "high" to "extremely high". Based on the original coordinate range (X:250-350, Y:300-400), the fused feature layers are merged into a super-resolution image of 204×204 pixels (actual size 204×0.015625m≈3.1875m, corresponding to the original region). The continuous contours of the "extremely high" gradient region (such as X:500-600, Y:600-700) are extracted as the edge information of the enhanced temperature anomaly region for the fusion processing in step S105.
[0123] The above-mentioned S103 overall scheme achieves targeted processing of the target area by extracting original potential crack image fragments and inputting them into the network, avoiding interference from irrelevant areas; it extracts feature layers of different scales and establishes positional correspondences, taking into account both the subtle details of gradient changes and the overall distribution, providing comprehensive features for fusion; it amplifies and fuses feature layers according to rules to achieve feature complementarity and improve image resolution; it calculates and enhances pixel value differences to make the edges of temperature anomaly areas clearer; the resulting enhanced edge information provides a high-quality two-dimensional feature foundation for subsequent fusion with the three-dimensional voxel mesh, improving the accuracy of crack parameter detection.
[0124] S104. Perform voxelization on the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region.
[0125] Optionally, step S104 involves voxelizing the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region, including:
[0126] Step 1041: Record the three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data.
[0127] Step 1042: Based on the three-dimensional spatial coordinates, determine the maximum and minimum coordinate ranges of the potential crack region in the three-dimensional space, and calculate the lengths of the potential crack region along the three coordinate axes in the space formed by the maximum and minimum coordinate ranges.
[0128] Step 1043: Based on the maximum coordinate range, the minimum coordinate range, and the preset side length of the cube unit, the three-dimensional space corresponding to the potential crack region is divided into multiple continuously arranged cube units, wherein the boundary of each cube unit is defined by coordinate values.
[0129] Step 1044: Compare the three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data with the coordinate range of each cube unit. When the three-dimensional spatial coordinate value of the reflection point falls within the coordinate range of any cube unit, determine that the reflection point belongs to the corresponding cube unit, and record the number of reflection points contained in each cube unit.
[0130] Step 1045: Combine all the cubic units according to the arrangement order of the small cubic units in three-dimensional space to form a three-dimensional voxel mesh covering the potential crack region.
[0131] In the above scheme, the preset cube unit side length refers to the side length of the basic unit in the voxelization process, which is used to divide the three-dimensional space; the cube unit refers to a cube with a side length of s in the three-dimensional space, whose boundary is defined by the coordinate interval; the number of reflection points refers to the number of three-dimensional point cloud reflection points contained in each cube unit; the three-dimensional voxel mesh refers to the mesh structure formed by combining all cube units in the three-dimensional spatial arrangement order, which is used to present the three-dimensional morphology of potential crack areas.
[0132] In this application example, firstly, in step 1041, reflection points within the potential crack area located in step 1025 are filtered out from the 3D point cloud data generated in step S101 by coordinate range matching. The 3D coordinates (X, Y, Z) of each point are recorded, where X represents the horizontal position of the building, Y represents the vertical position, and Z represents the vertical depth from the wall. For example, there are 200 reflection points within the potential crack area of building A, which are recorded sequentially as P1 (X=15.2, Y=6.3, Z=0.2) to P200 (X=15.9, Y=6.9, Z=0.3). These coordinate data will serve as the basis for calculating the coordinate range in step 1042.
[0133] Next, in step 1042, the maximum and minimum values of each axis are extracted from the coordinates of the 200 points recorded in step 1041: , Similarly, Secondly, calculate the axis length according to the formula. These length data will be used in step 1043 to calculate the number of cube units.
[0134] Then, in step 1043, the side length of the cube unit is set to s = 0.05m. The size of the side length can be preset according to the detection accuracy requirements, and the number of units for each axis is calculated according to the preset formula. To round up to the nearest integer, ensuring coverage of the entire area, The total number of units is 20 × 20 × 4 = 1600. Next, define the coordinate interval for each unit: the interval for the i-th, j-th, and k-th units is... , , , where i=0~19, j=0~19, k=0~3, these units will be used in step 1044 to determine the belonging of the reflection point.
[0135] Then, in step 1044, the cell index of each reflection point (e.g., P1) from step 1041 is calculated according to the formula. ( (for rounding down) Taking P1 as an example: If a cell belongs to cell (4,6,2), a counter is established for each cell. The counter is incremented by 1 for each reflection point it belongs to. For example, cell (4,6,2) will eventually have a count of 5. These data will be used for grid labeling in step 1045 to reflect the point cloud density within the cell.
[0136] Finally, in step 1045, the 1600 elements divided in step 1043 are arranged in three-dimensional space according to their indices (i, j, k): i from 0 to 19 (X-axis direction), j from 0 to 19 (Y-axis direction), and k from 0 to 3 (Z-axis direction), ensuring seamless connection between adjacent elements (e.g., elements (i, j, k) and (i+1, j, k) share the boundary X = Xmin + (i+1) × s). Next, the elements are combined to form a three-dimensional voxel mesh, with each element labeled with the number of reflection points (e.g., element (4, 6, 2) labeled "5"). This mesh will be directly used in step S105, fused with the enhanced temperature anomaly region edge information, and the crack depth is determined by the Z-axis distribution of a high number of elements.
[0137] In practical applications, taking the three-dimensional point cloud data of the potential crack area on the south exterior wall of building A (the area located in step 1025) as an example: In step 1041, the three-dimensional spatial coordinates of the reflection points within the area are recorded, such as P1 (X=15.2m, Y=6.3m, Z=0.2m), P2 (X=15.5m, Y=6.4m, Z=0.2m), P3 (X=15.3m, Y=6.2m, Z=0.2m), etc. There are a total of 200 reflection points, where X represents the wall... The horizontal axis is Y, the vertical axis is Z, and the vertical depth is Z. From the coordinates of 200 reflection points, extract the maximum coordinates: Xmax = 16.0m (X value of P100), Ymax = 7.0m (Y value of P150), Zmax = 0.3m (Z value of P80); extract the minimum coordinates: Xmin = 15.0m (X value of P50), Ymin = 6.0m (Y value of P30), Zmin = 0.1m (Z value of P20); calculate the axis length. , , Given a cube element with a side length of s = 0.05m, calculate the number of elements along each axis. To round up and ensure coverage of the entire area, The total number of units is 20 × 20 × 4 = 1600 units. For example, the boundary of the first unit is... The second unit is And so on, the cell index is denoted as (i, j, k), where i = 0~19, j = 0~19, and k = 0~3. Determine the cell to which P1 belongs: , That is, unit (4,6,2), where, To round down; count the number of points in the unit, including P1 and P3, to 5, and record the number of points. This data is used to represent the mesh density of 1045; arrange the 1600 units divided in step 1043 in the order of (i, j, k) (i from 0 to 19, j from 0 to 19, k from 0 to 3), and adjacent units share the boundary (e.g., units (4,6,2) and (5,6,2) share the surface X=15.25m). Combine them to form a three-dimensional voxel mesh, and label the number of reflection points in each unit (e.g., (4,6,2) is labeled "5"). This mesh is used to fuse with the temperature anomaly edge information in S105, and to locate the dense area in the direction of crack depth by using a high number of units.
[0138] The above-mentioned S104 overall scheme provides raw data for voxelization processing by recording the three-dimensional coordinates of reflection points; it determines the coordinate range and calculates the length to clarify the three-dimensional spatial scale of the potential crack region; it divides the discrete point cloud into structured units according to the preset side length, which is convenient for quantitative analysis; it counts the number of reflection points in each unit to reflect the point cloud density in the region; and the combined three-dimensional voxel mesh clearly presents the three-dimensional morphology of the potential crack region, providing structured three-dimensional data support for subsequent fusion with temperature anomaly edge information and improving the calculation accuracy of parameters such as crack depth.
[0139] S105. The edge information of the enhanced temperature anomaly region is fused with the three-dimensional voxel mesh of the potential crack region through an attention mechanism, and the building crack detection result containing the location, width and depth of the crack is output.
[0140] Optionally, in step S105, the enhanced edge information of the temperature anomaly region is fused with the three-dimensional voxel mesh of the potential crack region using an attention mechanism, outputting building crack detection results including the location, width, and depth of the cracks, including:
[0141] Step 1051: Based on the pixel position coordinates of the enhanced temperature anomaly region edge information and the spatial coordinates of the cubic units of the three-dimensional voxel mesh, establish the correspondence between the pixel positions in the enhanced temperature anomaly region edge information and the small cubic units of the three-dimensional voxel mesh in spatial position, and form corresponding spatial association units.
[0142] Step 1052: Using an attention mechanism, calculate the correlation degree between the pixel value difference of the pixel position in each spatial correlation unit and the number of reflection points of the corresponding cubic unit. Assign a first feature retention weight to spatial correlation units whose correlation degree value exceeds a preset correlation degree threshold, and assign a second feature retention weight to spatial correlation units whose correlation degree value does not exceed the preset correlation degree threshold. The first feature retention weight is greater than the second feature retention weight. A reference threshold is set based on the correlation degree calculation result between the pixel value difference in the enhanced edge information and the number of reflection points of the corresponding small cubic unit (this threshold is predetermined based on historical detection data of potential crack areas or typical crack features). When the correlation degree calculation result of a certain area is greater than or equal to the reference threshold, it is determined to be "high correlation degree"; when the calculation result is less than the reference threshold, it is determined to be "low correlation degree".
[0143] Step 1053: Based on the corresponding feature retention weights, fuse the enhanced temperature anomaly region edge information with the three-dimensional voxel mesh to form a three-dimensional feature set. Extract continuous spatial correlation units with significant pixel value differences and abnormal number of reflection points from the three-dimensional feature set. Use the spatial coordinates of the continuous spatial correlation units as the location of the crack. When the pixel value difference is greater than a preset difference threshold, it is determined to be a significant pixel value difference. When the number of reflection points is greater than the average number of reflection points in the region, it is determined to be an abnormal number of reflection points.
[0144] Step 1054: Calculate the pixel span of the continuous spatial association unit in the enhanced temperature anomaly region edge information along the direction perpendicular to its own edge, convert the pixel span into the actual physical size as the width of the crack, count the number of cubic units in the three-dimensional voxel mesh corresponding to the continuous spatial association unit in the direction perpendicular to the target building surface, and multiply the number of distributions by the side length of the cubic unit as the depth of the crack.
[0145] Step 1055: Integrate the location, width, and depth of the cracks to form the building crack detection results.
[0146] In the above scheme, the attention mechanism is a processing method used to highlight important features. By calculating the correlation between features and assigning weights, key information is given more attention during fusion. Spatial correlation unit can refer to the combination of pixel position in the enhanced temperature anomaly area edge information and corresponding cubic unit in the three-dimensional voxel mesh, reflecting the correspondence between two-dimensional pixels and three-dimensional space. The correlation degree value is a value that measures the correlation between pixel value difference and the number of reflection points. The higher the value, the closer the correlation between the two. The first feature retention weight and the second feature retention weight are weight values used for fusion, corresponding to units with high and low correlation degrees, respectively. The higher the weight, the greater the influence of the feature during fusion. The three-dimensional feature set is a comprehensive feature dataset formed after fusing two-dimensional edge information and three-dimensional voxel mesh. Continuous spatial correlation unit refers to correlation units that are continuously distributed in space, corresponding to the actual extension range of the crack. The position of the crack can refer to the spatial coordinates of the continuous unit, the width is the actual physical size of the crack along the vertical edge direction, and the depth is the extension distance of the crack perpendicular to the building surface.
[0147] In this application example, step 1051 first obtains the enhanced temperature anomaly region edge information (including pixel coordinates) from step 1035. And the pixel value difference d, and the three-dimensional voxel mesh of step 1045 (including cell index (i,j,k), coordinate range and number of reflection points n), next, convert the pixel coordinates into actual coordinates: , For example, if the pixel size of building A is 0.015625m / pixel, (500, 600) is converted to (7.8125m, 9.375m). Finally, the cube cells containing these actual coordinates are matched to form spatially related cells, which will be used for the degree of association calculation in step 1052.
[0148] Next, in step 1052, the degree of association for each spatially associated unit is calculated using an attention mechanism, with the formula as follows: ,in The degree of association of the i-th spatial unit. The pixel value difference (range 0-1) is the pixel position difference in the i-th spatial association unit. Let be the number of reflection points of the cube element corresponding to the i-th spatially associated element. To enhance the edge information of the temperature anomaly region, the maximum pixel value difference of all pixels and Let be the maximum number of reflection points of all cubic elements in the three-dimensional voxel mesh of the potential crack region, where and For a uniform value across the region, for example, in a certain unit d=0.6, n=5, , Then r = 0.3; secondly, a preset correlation threshold (e.g., 0.5) is set, and units with r ≥ 0.5 are assigned a first feature retention weight (0.8), while those with r < 0.5 are assigned a second weight (0.2). These weights will be used for feature fusion in step 1053.
[0149] Then, in step 1053, based on the feature retention weights from step 1052, the enhanced edge information (pixel value difference d) and the 3D voxel mesh (number of reflection points n) are weighted and fused, using the following formula: This forms a three-dimensional feature set. Next, units with significant pixel value differences and abnormal numbers of reflection points are extracted from this set. The standard for "significant pixel value differences" is d > 0.5, and the standard for "abnormal number of reflection points" is n > 1.5 times the average number of reflection points in the region. For example, if the average number of reflection points in the region is 2, 1.5 times the average is 3, therefore the abnormal standard is n > 3. Units with n = 5 meet this abnormal standard. Then, the selected units are checked to see if they are spatially connected units: Units are determined to be adjacent in three-dimensional space (i.e., whether they share faces, edges, or vertices). For example, units (156,187,2) and (157,187,2) share a face in the X direction and are considered continuous. Finally, continuous units are combined, and their spatial coordinate range (e.g., X = 7.8-7.9m, Y = 9.35-9.4m, Z = 0.2-0.25m) is used as the location of the crack. This location data will be directly used in step 1054 to calculate the width and depth of the crack.
[0150] Next, the crack width is calculated in step 1054: In the enhanced edge information, the pixel span perpendicular to the crack edge direction (e.g., 8 pixels from the left to the right edge) is measured, and the pixel span is converted into the actual width. The conversion formula is: Actual width = Pixel span × Pixel size. Next, the number of related units in the continuous spatial direction along the Z-axis (perpendicular to the building surface) is counted (e.g., 3 units). The crack depth is calculated based on the number of units, using the formula: Depth = Number of units × Cube unit side length. The width and depth data will be used to integrate the results of step 1055.
[0151] Finally, the crack locations (three-dimensional coordinate range) from step 1053 and the width and depth values from step 1054 are collected. For example, "The crack location on the south exterior wall of Building A is X=7.8-7.9m, Y=9.35-9.4m, Z=0.2-0.35m, width 0.125m, and depth 0.15m." Next, this information is integrated into a structured building crack detection result, which can be directly used for building structure safety assessment and maintenance planning.
[0152] In practical applications, taking the potential crack area on the south exterior wall of building A as an example (the enhanced edge information pixel size is 0.015625m / pixel, and the three-dimensional voxel unit side length is 0.05m), =1, =10), pixels of edge information Based on the actual coordinates: X = 500 × 0.015625 = 7.8125m, Y = 600 × 0.015625 = 9.375m, matching the cells containing these coordinates in the 3D voxel mesh (i = 156, j = 187, k = 2) (X ∈ [7.8, 7.85), Y ∈ [9.35, 9.4), Z ∈ [0.2, 0.25)), forming a spatially associated cell. The pixel value difference of this cell is d = 0.6 (the difference between "extremely high" and the surrounding "medium"). The number of reflection points is n = 5. The association degree value is calculated according to the formula r = (0.6 × 5) / (1 × 10) = 0.3. The preset threshold is 0.5. Since 0.3 < 0.5, the second feature retention weight is assigned 0.2. After fusing features according to the weight, continuous space is extracted. The associated units (e.g., from (156,187,2) to (160,187,2), a total of 5 units), with their coordinate range (X=7.8-7.9m, Y=9.35-9.4m, Z=0.2-0.25m) as the crack location; the pixel span in the vertical edge direction is 8 pixels, and the actual width is calculated as: 8×0.015625=0.125m; the number of units distributed in the Z-axis direction is 3 (k=2,3,4), and the depth is calculated as: 3×0.05=0.15m. Integrating the width and depth, the crack detection result is obtained: location (X=7.8-7.9m, Y=9.35-9.4m, Z=0.2-0.35m), width 0.125m, and depth 0.15m. This result is used for the structural safety assessment of building A.
[0153] The S105 overall scheme described above establishes a spatial relationship between two-dimensional edge information and three-dimensional voxel mesh through an attention mechanism, achieving accurate matching of cross-dimensional features; it assigns weights based on the degree of relationship, highlighting key features of the crack area and reducing interference from irrelevant information; the fused three-dimensional feature set completely preserves the two-dimensional contour and three-dimensional depth information of the crack, ensuring the comprehensive extraction of position, width, and depth parameters; the final output detection results take into account both planar and three-dimensional features, accurately reflecting the actual morphology of the crack and providing a reliable basis for building structural safety assessment.
[0154] The following is a complete example for steps S101 to S105, such as Figure 2The process begins by using building A (a concrete exterior wall, 32m wide × 8m high) as the target for crack detection. Infrared thermal imager B (resolution 1024×768, frame rate 25 frames / second) and laser scanner C (scanning accuracy 0.05m) are used for crack detection. The procedure is as follows: The exterior wall of building A is divided into four sub-regions (numbered 1-4, calculation: 32÷8=4, 8÷8=1) at 8m × 8m intervals. B and C are simultaneously activated by a trigger signal. B takes six images of each sub-region, adjusting the sensitivity according to the brightness change rate of the previous frame (e.g., increasing sensitivity when the brightness change rate of the second frame is 12% compared to the first frame). The images are then merged to obtain the temperature images of the sub-regions. C projects images with a range of 100-400m. A Hz-encoded beam (corresponding to sub-regions 1-4) is scanned along the horizontal (0.5 m / s) and vertical directions, recording the return time (e.g., 1.2 μs), angle (30°), and encoding of the reflection point. The high-precision clock module D sends pulses at 0.5 ms intervals. The data collected by B and C are embedded with the same time marker (e.g., T2=0.002 s). The temperature images of the sub-regions are stitched together to obtain 32 m × 8 m temperature field distribution data (0.03125 m × 0.0104 m per pixel). The three-dimensional coordinates of the laser reflection point are calculated (distance = 3 × 10 × 1.2 × 10 ÷ 2 = 180 m, X = 180 × cos30° ≈ 155.88 m), forming three-dimensional point cloud data.
[0155] Next, the temperature sequence [22.0, 22.5, ..., 23.7℃] (T1-T10, 0.1s interval) of pixel (100, 200) (actually 3.125m, 2.08m) is extracted from the temperature field data. It is then classified into temperature subsequences according to the first sub-region 1, and a modulation signal is applied. Where A = 0.5℃ is the amplitude, and T = 10s is the period, such as when T3 = 0.3s. The modulated temperature is 23.094℃. The temperature difference between adjacent pixels (100,200) and (101,200) at time T5 is calculated to be 1.4℃. These pixels are labeled as "medium gradient" and arranged to form a temperature gradient distribution map. The second sub-region (64×192 pixels) is divided into 2m×2m sections. The boundary line is taken as the reference line. The phase difference between pixels (256,300) and (257,300) on both sides is calculated to be 35°. The average phase fluctuation range within the sub-region is 5°-15°. 35° is outside the range. These pixels are marked and connected to form a potential crack region (X=8-9m, Y=6-7m).
[0156] Then, the original image segment of the potential crack region (X=250-350, Y=300-400 pixels, 101×101 pixels, calculation: 350-250+1=101) is extracted and fed into a multi-scale feature pyramid network. The first-scale feature layer (preserving the gradient difference of 0.3 between pixels (280,320) and (281,320)) and the second-scale feature layer (preserving the "high" gradient distribution of X=280-320) are extracted. The positional correspondence is established (the first scale (x,y) corresponds to the second scale (x / 2,y / 2)). The feature layer is expanded to 202×202 pixels according to the 2x magnification rule (calculation: 101×2=202). The feature layers are superimposed to form a fusion feature layer. The average gradient change amplitude of the 8 pixels around pixel (100,100) is calculated. ,in The pixel average value is n=8, which is the number of adjacent pixels. The pixel amplitude is 0.5>0.2875, which is enhanced to "extremely high" gradient. The feature layers are merged and fused to obtain a super-resolution image of 204×204 pixels (0.0156m per pixel). The contour of the "extremely high" gradient region is extracted as enhanced edge information.
[0157] Next, point cloud data of potential crack areas were filtered, and the coordinates of reflection points were recorded as P1(15.2, 6.3, 0.2m). The coordinate range Xmax=16.0m, Xmin=15.0m was determined, and the axis length was calculated. Similarly The cube is pre-defined with a side length of 0.05m, and the number of units is set accordingly. There are a total of 1600 units (20×20×4). For example, the boundary X of unit (4,6,2) is in [15.2,15.25). The reflection points are assigned according to the index. For example, P1 belongs to (4,6,2). This unit contains 5 points. The units are arranged by index to form a three-dimensional voxel mesh.
[0158] Finally, the edge pixel (500, 600) (actual coordinates calculated: 500 × 0.015625 = 7.8125m, 600 × 0.015625 = 9.375m) is matched with the voxel unit (156, 187, 2) to form a spatially related unit, and the degree of association is calculated. Where r is the correlation degree value, d=0.6 is the pixel value difference, and n=5 is the number of reflection points. =1, =10 is the maximum value in the region), preset threshold 0.5, assign second weight 0.2, fuse features to obtain a three-dimensional feature set, extract continuous units with d greater than 0.5 and n greater than 3 (such as (156-160,187,2)), calculate width: vertical edge pixel span 8×0.015625=0.125m; depth: number of Z-axis units 3×0.05=0.15m, integrate the results: the location of the crack in the exterior wall of building A is X=7.8-7.9m, Y=9.35-9.4m, Z=0.2-0.35m, width 0.125m, depth 0.15m, used for structural safety assessment.
[0159] Figure 3 This is a structural schematic diagram of a specific embodiment of a building crack system provided in this application, with reference to... Figure 3 The system may include:
[0160] The acquisition module 31 is used to acquire temperature field distribution data of the target building surface through an infrared thermal imager and simultaneously acquire three-dimensional point cloud data of the target building surface through a laser scanner.
[0161] The positioning module 32 is used to generate a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and to locate potential crack areas based on the phase difference analysis of the temperature gradient distribution map.
[0162] The reconstruction module 33 is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map using a multi-scale feature pyramid network, so as to enhance the edge information of the temperature anomaly region in the potential crack region.
[0163] Processing module 34 is used to perform voxelization processing on the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region.
[0164] The fusion module 35 is used to fuse the enhanced edge information of the temperature anomaly region with the three-dimensional voxel mesh of the potential crack region through an attention mechanism, and output the building crack detection results including the location, width and depth of the crack.
[0165] This application provides a building crack system for implementing the aforementioned building crack method. Therefore, the specific implementation of the building crack system can be found in the embodiment section of the building crack method above. The specific implementation can be referred to the description of the corresponding embodiments, which will not be repeated here.
[0166] like Figure 4As shown, this application also provides an electronic device, including: a memory 41 for storing a computer program; and a processor 42 for executing the computer program to implement the steps of any of the above-described building crack method.
[0167] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of any of the above-described methods for addressing building cracks.
[0168] In one exemplary embodiment, the aforementioned computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory, random access memory, portable hard drives, magnetic disks, or optical disks.
[0169] Embodiments of the present invention also provide a computer program product, which includes a computer program that, when executed by a processor, implements the steps in any of the above-described embodiments of the building cracking method.
[0170] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0171] The foregoing has provided a detailed description of a method, system, electronic device, and storage medium for addressing building cracks. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are merely for the purpose of helping to understand the method and its core ideas. It should be noted that those skilled in the art can make various improvements and modifications to this application without departing from its principles, and these improvements and modifications also fall within the protection scope of this application.
Claims
1. A method of detecting a building crack, characterized by, The method comprises the following steps: Collecting the temperature field distribution data of the target building surface by an infrared thermal imager, and synchronously collecting the three-dimensional point cloud data of the target building surface by a laser scanner; Based on the temperature field distribution data, a temperature gradient distribution map of the target building surface is generated, and a potential crack area is located based on the phase difference analysis of the temperature gradient distribution map; A multi-scale feature pyramid network is used to perform super-resolution reconstruction on the potential crack area in the temperature gradient distribution map to enhance the edge information of the temperature abnormal area in the potential crack area; The three-dimensional point cloud data corresponding to the potential crack area is voxelized to obtain a three-dimensional voxel grid of the potential crack area; The enhanced edge information of the temperature abnormal area and the three-dimensional voxel grid of the potential crack area are fused through an attention mechanism to output a building crack detection result containing the position, width and depth of the crack; Based on the temperature field distribution data, a temperature gradient distribution map of the target building surface is generated, and a potential crack area is located based on the phase difference analysis of the temperature gradient distribution map, comprising: Extracting the temperature values of each pixel position from the temperature field distribution data to form a temperature value sequence that changes over time; Based on the first sub-region divided on the target building surface, the temperature value sequence is divided to obtain a temperature value sub-sequence corresponding to the first sub-region; A periodic modulation signal is applied to each temperature value sub-sequence to make the temperature value sub-sequence form a periodically changing signal waveform; According to the periodical change rule of the signal waveform, the temperature value difference of adjacent pixel positions at the same time point is calculated, the gradient identifier is assigned to the corresponding pixel position based on the temperature value difference, and all gradient identifiers are arranged according to the actual position of the pixel position on the target building surface to form a temperature gradient distribution map; In the temperature gradient distribution map, the boundary line of adjacent second sub-regions is selected as the reference line, the phase difference value of the signal waveforms corresponding to the adjacent pixel positions on both sides of the reference line is calculated, and when the phase difference value exceeds the average phase fluctuation range of the adjacent pixel positions, the adjacent pixel positions are marked, and all marked pixel positions are connected to form a potential crack area; In the temperature gradient distribution map, the boundary line of adjacent second sub-regions is selected as the reference line, the phase difference value of the signal waveforms corresponding to the adjacent pixel positions on both sides of the reference line is calculated; when the phase difference value exceeds the average phase fluctuation range of the adjacent pixel positions, the adjacent pixel positions are marked, and all marked pixel positions are connected to form a potential crack area, comprising: The temperature gradient distribution map is divided into a plurality of second sub-regions with the same size according to a predetermined size rule, the boundary line of adjacent second sub-regions is selected as the reference line, and the coordinate range and extension direction of each reference line are recorded simultaneously; Based on the direction perpendicular to the extension direction on both sides of the reference line, the closest pixel positions on both sides are selected as adjacent pixel pairs across the sub-region, and the coordinates and corresponding signal waveform phases of the adjacent pixel pairs across the sub-region are recorded. The phase difference of the signal waveform corresponding to the two pixel positions in the adjacent pixel pairs across the sub-region is calculated as the first phase difference value. Select adjacent pixel positions in the space within each second sub-region as adjacent pixel pairs within the sub-region, and calculate the phase difference of the signal waveform of all adjacent pixel pairs within the same second sub-region as the average phase fluctuation range of adjacent pixels within the sub-region. The first phase difference value is compared with the average phase fluctuation range corresponding to the two pixel positions in the cross-sub-region adjacent pixel pair. When the first phase difference value exceeds any of the average phase fluctuation ranges, the two pixel positions in the cross-sub-region adjacent pixel pair are marked as marked pixel positions. Based on the coordinate distribution of each of the marked pixel positions, consecutive marked pixel positions are connected sequentially to form a potential crack region.
2. The method of claim 1, wherein Temperature field distribution data of the target building surface is acquired using an infrared thermal imager, and three-dimensional point cloud data of the target building surface is simultaneously acquired using a laser scanner, including: The surface of the target building is divided into multiple first sub-regions, and the infrared thermal imager and the laser scanner are controlled to start collecting data simultaneously by triggering signals. During the simultaneous acquisition process, the infrared thermal imager is controlled to continuously image the surface of the target building at a preset frame rate. When each frame is imaged, the detection sensitivity of the infrared thermal imager is adjusted based on the brightness change rate of the previous frame. At the same time, each sub-region is sequentially photographed in the spatial dimension. After multiple photographs of each sub-region, they are merged into the corresponding sub-region temperature image. The laser scanner is controlled to project a scanning beam with spatial coding information onto the surface of the target building. The scanning beam moves sequentially along the horizontal and vertical directions of the target building surface, and the reflection signals after the scanning beam contacts each position on the target building surface and the corresponding spatial coding information are recorded. The reflection signals include return time and angle. A high-precision clock synchronization module sends trigger pulse signals to the infrared thermal imager and the laser scanner in real time. When the infrared thermal imager captures and generates the temperature image of the sub-region, it embeds the time stamp corresponding to the pulse signal. When the laser scanner records each group of the reflection signals, it synchronously embeds the same time stamp corresponding to the pulse signal, so that the temperature image of the sub-region acquired by the pulse signal within the same trigger period is time-correlated with the reflection signal. All the temperature images of the sub-regions carrying time stamps are stitched together according to the sub-region positions to form a sub-region temperature stitched image. The temperature value corresponding to each pixel position in the sub-region temperature stitched image is extracted to form temperature field distribution data covering the surface of the target building. Based on the return time, the angle, and the spatial encoding information, combined with the time stamp and the location range of the corresponding sub-region temperature image, the position coordinates of the reflection point corresponding to each reflection signal in three-dimensional space are determined. All the position coordinates are arranged in the acquisition order to form three-dimensional point cloud data of the target building surface.
3. The method of claim 1, wherein the step of detecting the crack in the building is characterized by, A multi-scale feature pyramid network is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map to enhance the edge information of the temperature anomaly region within the potential crack region, including: Extract the original potential crack image fragment corresponding to the potential crack region from the temperature gradient distribution map, record the pixel coordinate range and gradient identifier of each pixel position of the original potential crack image fragment, and input the original potential crack image fragment into a multi-scale feature pyramid network for super-resolution reconstruction. During the super-resolution reconstruction process, the multi-scale feature pyramid network extracts a first-scale feature layer and a second-scale feature layer from the original potential crack image fragment according to a preset scale hierarchy. The first-scale feature layer retains the changes in the gradient identifier, and the second-scale feature layer retains the overall distribution of the gradient identifier. The positional correspondence between the feature layers of different scales is established based on the pixel coordinate range, with the first scale being smaller than the second scale. Based on the positional correspondence, the first-scale feature layer and the second-scale feature layer are magnified step by step according to the magnification rules of super-resolution reconstruction, so that the size of the magnified first-scale feature layer matches the size of the magnified second-scale feature layer. The changes retained by the magnified first-scale feature layer are superimposed on the corresponding positions in the magnified second-scale feature layer to form a fused feature layer. In the fusion feature layer, the average change magnitude of the gradient identifier of each pixel position around the neighboring pixel positions is calculated, the change magnitude of its own gradient identifier is compared with the average change magnitude, and the pixel value difference of the pixel position exceeding the average change magnitude is enhanced. Based on the pixel coordinate range, all the fused feature layers are merged into a super-resolution reconstructed potential crack image. The contour of the region enhanced by pixel value difference in the super-resolution reconstructed potential crack image is extracted as the edge information of the enhanced temperature anomaly region.
4. The method of claim 1, wherein the step of detecting the crack in the building is performed by using a crack detection device. The three-dimensional point cloud data corresponding to the potential crack region is voxelized to obtain a three-dimensional voxel mesh of the potential crack region, including: Record the three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data; Based on the three-dimensional spatial coordinates, determine the maximum and minimum coordinate ranges of the potential crack region in the three-dimensional space, and calculate the lengths of the potential crack region along the three coordinate axes in the space formed by the maximum and minimum coordinate ranges. Based on the maximum coordinate range, the minimum coordinate range, and the preset side length of the cube unit, the three-dimensional space corresponding to the potential crack region is divided into multiple continuously arranged cube units, wherein the boundary of each cube unit is defined by coordinate values. The three-dimensional spatial coordinates of each reflection point in the three-dimensional point cloud data are compared with the coordinate range of each cube unit. When the three-dimensional spatial coordinate value of the reflection point falls within the coordinate range of any cube unit, it is determined that the reflection point belongs to the corresponding cube unit, and the number of reflection points contained in each cube unit is recorded. All the cubic units are combined according to the arrangement order of the smaller cubic units in three-dimensional space to form a three-dimensional voxel mesh covering the potential crack region.
5. The method of claim 1, wherein the step of detecting the crack in the building is characterized by, An attention mechanism is used to fuse the enhanced edge information of the temperature anomaly region with the three-dimensional voxel mesh of the potential crack region, outputting building crack detection results including the location, width, and depth of the cracks, including: Based on the pixel position coordinates of the enhanced temperature anomaly region edge information and the spatial coordinates of the cubic units of the three-dimensional voxel mesh, a correspondence between the pixel position in the enhanced temperature anomaly region edge information and the small cubic units of the three-dimensional voxel mesh in spatial position is established, forming a corresponding spatial association unit. Through an attention mechanism, the correlation degree value between the pixel value difference of the pixel position in each spatial correlation unit and the number of reflection points of the corresponding cubic unit is calculated. The spatial correlation unit with the correlation degree value exceeding the preset correlation degree threshold is given a first feature retention weight, and the spatial correlation unit with the correlation degree value not exceeding the preset correlation degree threshold is given a second feature retention weight. The first feature retention weight is greater than the second feature retention weight. According to the corresponding feature retention weight, the enhanced temperature anomaly region edge information is fused with the three-dimensional voxel mesh to form a three-dimensional feature set. Continuous spatial correlation units with significant pixel value differences and an abnormal number of reflection points are extracted from the three-dimensional feature set, and the spatial coordinates of the continuous spatial correlation units are used as the location of the crack. Calculate the pixel span of the continuous spatial correlation unit in the enhanced temperature anomaly region edge information along the direction perpendicular to its own edge, convert the pixel span into the actual physical size as the width of the crack, count the number of cubic units in the three-dimensional voxel mesh corresponding to the continuous spatial correlation unit in the direction perpendicular to the target building surface, and multiply the number of distributions by the side length of the cubic unit as the depth of the crack. The location, width, and depth of the cracks are integrated to form the building crack detection results.
6. A building crack detection system characterized by, A method for detecting building cracks as described in claim 1, comprising: The acquisition module is used to acquire temperature field distribution data of the target building surface through an infrared thermal imager and simultaneously acquire three-dimensional point cloud data of the target building surface through a laser scanner. The positioning module is used to generate a temperature gradient distribution map of the target building surface based on the temperature field distribution data, and to locate potential crack areas based on the phase difference analysis of the temperature gradient distribution map. The reconstruction module is used to perform super-resolution reconstruction of the potential crack region in the temperature gradient distribution map using a multi-scale feature pyramid network, so as to enhance the edge information of the temperature anomaly region in the potential crack region. The processing module is used to perform voxelization processing on the three-dimensional point cloud data corresponding to the potential crack region to obtain a three-dimensional voxel mesh of the potential crack region. The fusion module is used to fuse the enhanced edge information of the temperature anomaly region with the three-dimensional voxel mesh of the potential crack region through an attention mechanism, and output the building crack detection results including the location, width and depth of the crack.
7. An electronic device, comprising: include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the steps of a method for detecting building cracks as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, enables a method for detecting building cracks as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Method for remotely detecting crack of building
CN114119614A
Building outer wall leakage detection method and system
CN120427492A