Historical building internal wall damage detection method and system based on image vision

By performing visual image processing on the interior walls of historical buildings, including illumination equalization, texture enhancement, and structural semantic partitioning, crack, peeling, and color degradation areas are identified and analyzed. A damage propagation feature map is constructed, which solves the problem of insufficient detection in existing technologies. This enables comprehensive identification of damage and reflection of its evolution trend, providing an accurate basis for the protection and restoration of historical buildings.

CN122023398APending Publication Date: 2026-05-12CSCEC INT URBAN CONSTR CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CSCEC INT URBAN CONSTR CO LTD
Filing Date
2026-04-10
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing technologies for detecting damage to the interior walls of historical buildings are not comprehensive enough and fail to reflect the evolution trend of damage, thus failing to provide effective reference for restoration decisions.

Method used

Using image vision methods, the original images of the interior walls of historical buildings are processed with illumination equalization and texture enhancement to identify structural boundaries and material textures, perform structural semantic partitioning, extract crack textures, peeling boundaries and color degradation areas, construct a set of damage morphology features, calculate the damage propagation potential value, and form a propagation feature map to identify the propagation path and calculate the propagation intensity.

Benefits of technology

It enables comprehensive and accurate identification of damage to the interior walls of historical buildings, reflects the evolution trend of the damage, and provides a reliable testing basis for protection and restoration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122023398A_ABST
    Figure CN122023398A_ABST
Patent Text Reader

Abstract

The invention provides a historical building internal wall damage detection method and system based on image vision, and belongs to the field of image vision. The method comprises the following steps: establishing an enhanced image according to an original image of an internal wall of a historical building; performing structure semantic partitioning processing according to the enhanced image to generate a structure semantic region graph; using the structure semantic region map to execute the damaged form extraction processing of the enhanced image in each wall structure region, and constructing a wall damaged form feature set; generating a damage form response field according to the structure semantic region map and the wall body damage form feature set, and forming a wall body damage propagation feature map by combining the structure semantic region map and the wall body damage form feature set; identifying a propagation path, calculating a damage propagation intensity index, and generating a wall damage detection result by using the damage propagation intensity index and the structural semantic region map. Comprehensive and accurate identification of historical building internal wall damage is realized through image visual analysis, and the evolution trend of the damage is effectively reflected.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image vision, and in particular to a method and system for detecting damage to the interior walls of historical buildings based on image vision. Background Technology

[0002] Over long-term use, the interior walls of historical buildings are prone to various forms of damage due to environmental erosion, structural aging, and external forces. Timely and accurate detection of wall damage is of great significance for the protection, restoration, and safety assessment of historical buildings.

[0003] Traditional wall damage detection mainly relies on on-site visual observation by professionals combined with experience-based judgment. This method is not only inefficient, but the accuracy and consistency of the detection results also depend heavily on the experience level of the inspectors, making it difficult to meet the needs of large-scale surveys of wall damage in historical buildings.

[0004] With the development of computer vision technology, image analysis-based methods for detecting wall damage have been gradually applied. These methods, through the acquisition and processing of wall images, can achieve automatic identification of damaged areas to a certain extent, improving detection efficiency. However, existing image vision detection methods still have shortcomings when practically applied to the interior walls of historical buildings. On the one hand, the materials and surface textures of the interior walls of historical buildings are complex, and existing methods are not comprehensive enough in identifying various types of damage, easily leading to missed detections. On the other hand, existing methods mainly focus on identifying the current state of damage, and the detection results are difficult to reflect the evolution trend of damage, failing to provide a reference for subsequent repair decisions regarding the direction of damage development. Summary of the Invention

[0005] This invention addresses the technical problems in existing technologies for detecting damage to the interior walls of historical buildings, where damage identification is not comprehensive enough and the detection results fail to reflect the evolution trend of damage. It provides a method and system for detecting damage to the interior walls of historical buildings based on image vision.

[0006] The technical solution of the present invention to solve the above-mentioned technical problems is as follows:

[0007] In a first aspect, the present invention provides a method for detecting damage to the interior walls of historical buildings based on image vision, comprising: after acquiring an original image of the interior walls of a historical building, performing illumination equalization and texture enhancement processing on the original image to establish an enhanced image; identifying the structural boundary lines and material texture distribution features of the walls in the enhanced image, and performing structural semantic partitioning processing to generate a structural semantic region map; using the structural semantic region map to perform damage morphology extraction processing on the enhanced image in each structural region of the wall, identifying crack textures, peeling boundaries, and color degradation areas on the wall surface, and based on the direction of the crack textures... A set of wall damage morphological features is constructed based on continuity, the morphological contour of the peeling boundary, and the gradient changes of the color degradation region. A damage morphological response field is generated based on the structural semantic region map and the set of wall damage morphological features. The damage propagation potential value is calculated by combining the adjacency relationships between structural semantic regions, the directional consistency of crack textures, the neighborhood expansion trend of the peeling boundary, and the gradient diffusion direction of the color degradation region, thus forming a wall damage propagation feature map. The propagation path is identified using the wall damage propagation feature map, and a damage propagation intensity index is calculated. Finally, the wall damage detection result is generated using the damage propagation intensity index and the structural semantic region map.

[0008] Secondly, this invention provides a system for detecting damage to the interior walls of historical buildings based on image vision, comprising: an image enhancement module, used to perform illumination equalization and texture enhancement processing on the original image of the interior walls of the historical building after acquiring the original image, to establish an enhanced image; a structural semantic partitioning module, used to identify the structural boundary lines and material texture distribution features of the walls in the enhanced image, and perform structural semantic partitioning processing to generate a structural semantic region map; and a damage morphology extraction module, used to perform damage morphology extraction processing on the enhanced image in each structural region of the wall using the structural semantic region map, to identify crack textures, peeling boundaries, and color degradation areas on the wall surface, and to extract damage morphology based on crack textures, peeling boundaries, and color degradation areas. The following modules are used to construct a set of wall damage morphology features: texture continuity, morphological contour of the peeling boundary, and gradient changes in the chromatic degradation region; a propagation feature construction module is used to generate a damage morphology response field based on the structural semantic region map and the set of wall damage morphology features, and to calculate the damage propagation potential value by combining the adjacency relationship between structural semantic regions, the directional consistency of crack texture, the neighborhood expansion trend of the peeling boundary, and the gradient diffusion direction of the chromatic degradation region, thus forming a wall damage propagation feature map; a damage detection output module is used to identify the propagation path using the wall damage propagation feature map, calculate the damage propagation intensity index, and generate the wall damage detection result using the damage propagation intensity index and the structural semantic region map.

[0009] The beneficial effects of this invention are:

[0010] After acquiring the original images of the interior walls of the historical building, illumination equalization and texture enhancement processing are performed on the original images to create enhanced images. This eliminates brightness differences caused by uneven illumination in the original images and enhances the texture details of the wall surface, providing a high-quality image foundation for subsequent damage feature identification. Then, the structural boundary lines and material texture distribution features of the walls are identified in the enhanced images, and structural semantic partitioning is performed to generate a structural semantic region map. This divides the walls into several regions with independent semantic meanings according to different structural attributes, enabling subsequent damage detection to be performed separately for the characteristics of different structural regions. Next, using the structural semantic region map, damage morphology extraction processing is performed on the enhanced images in each wall structural region to identify crack textures, peeling boundaries, and color degradation areas on the wall surface. Based on the continuity of crack texture direction, the morphological contour of peeling boundaries, and the gradient changes of color degradation areas, the wall damage morphology features are constructed. This process involves collecting data to comprehensively acquire the morphological characteristics of different types of damage within each structural region, providing complete feature support for comprehensive damage analysis. Then, based on the structural semantic region map and the set of wall damage morphological characteristics, a damage morphological response field is generated. This field is combined with the adjacency relationships between structural semantic regions, the directional consistency of crack textures, the neighborhood expansion trend of peeling boundaries, and the gradient diffusion direction of color degradation areas to calculate the damage propagation potential value, forming a wall damage propagation feature map. This integrates the damage morphological characteristics within each region with the spatial relationships between regions, quantifying the possibility and direction of damage propagation between adjacent regions. Subsequently, the propagation path is identified using the wall damage propagation feature map, and damage propagation intensity indices are calculated. These indices, along with the structural semantic region map, generate wall damage detection results. This comprehensive identification of wall damage distribution effectively reflects the evolution trend of damage, providing accurate detection basis for the protection and repair of historical building walls.

[0011] Through the above technical solutions, comprehensive and accurate identification of damage to the interior walls of historical buildings is achieved through image visual analysis, and the evolution trend of the damage is effectively reflected, providing a reliable detection basis for the protection, repair and safety assessment of the walls of historical buildings. Attached Figure Description

[0012] Figure 1 A schematic flowchart of the image vision-based method for detecting damage to the interior walls of historical buildings provided by the present invention;

[0013] Figure 2 A schematic diagram of the structure of the image vision-based historical building interior wall damage detection system provided by the present invention.

[0014] In the attached diagram, the components represented by each number are as follows:

[0015] Image enhancement module 11, structural semantic partitioning module 12, damage morphology extraction module 13, propagation feature construction module 14, damage detection output module 15. Detailed Implementation

[0016] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0017] In the description of this invention, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the stated features. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0018] In the description of this invention, the term "for example" is used to mean "used as an example, illustration, or description." Any embodiment described as "for example" in this invention is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use the invention. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that the invention can be made without using these specific details. In other instances, well-known structures and processes will not be described in detail to avoid obscuring the description of the invention with unnecessary detail. Therefore, the invention is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed herein.

[0019] Example 1, as Figure 1 As shown, this embodiment of the invention provides a method for detecting damage to the interior walls of historical buildings based on image vision, including:

[0020] S1. After acquiring the original image of the interior wall of the historical building, perform illumination equalization and texture enhancement processing on the original image to create an enhanced image.

[0021] Specifically, firstly, original images of the interior walls of the historical building are acquired using image acquisition equipment. This equipment can be a digital camera, an industrial camera, or a mobile device with shooting capabilities. During acquisition, the optical axis of the image acquisition equipment should be kept substantially perpendicular to the wall surface to reduce the impact of perspective distortion on subsequent damage feature extraction. The acquired original images should cover the entire area of ​​the wall to be inspected, and the image resolution should meet the requirements for subsequent damage detail identification, typically using a resolution of no less than 1920×1080 pixels to ensure that subtle damage features such as crack textures and peeling boundaries have sufficient pixels to represent them in the image.

[0022] Because the interior spaces of historical buildings often have complex lighting conditions and uneven light source distribution, the brightness differences between different areas in the original image are significant. The wall surface may simultaneously contain areas of strong light and areas of shadow. This uneven lighting can lead to false positives or false negatives during subsequent damage feature extraction. Therefore, it is necessary to perform illumination equalization processing on the original image. In illumination equalization processing, firstly, the original image is converted from the RGB color space to a luminance-chrominance separated color space, resulting in luminance channel images and chrominance channel images. Then, the luminance channel image is divided into local regions, and the average luminance value of each local region is calculated to establish a luminance distribution map of the original image. Next, based on the luminance distribution map, regions whose brightness deviates from the global average luminance are identified. Brightness attenuation is performed on regions with high brightness, and brightness enhancement is performed on regions with low brightness, to make the brightness of each region more uniform. An adaptive adjustment coefficient is used during adjustment, which is positively correlated with the degree of regional brightness deviation; the greater the deviation, the greater the adjustment. The adjusted luminance channel image is then recombined with the original chrominance channel image to obtain the illumination-equalized image. By performing illumination equalization processing, the phenomenon of local overexposure or underexposure caused by uneven illumination in the original image is eliminated, laying the foundation for the accurate extraction of subsequent damaged features.

[0023] The interior walls of historical buildings are typically constructed using a variety of materials such as bricks, adobe, and mortar, resulting in rich material textures that are crucial for subsequent structural semantic partitioning. However, factors such as shooting conditions and image compression can blur or weaken texture details in the original image, hindering the identification of structural features like masonry texture and mortar joint distribution. Therefore, texture enhancement processing is necessary after the image has been evenly illuminated. In texture enhancement, firstly, the evenly illuminated image undergoes multi-scale decomposition, breaking it down into component layers with different spatial frequencies. The low-frequency component layer reflects the overall brightness and color distribution, while the high-frequency component layer reflects edge and texture details. Then, the gain of the high-frequency component layer is adjusted to increase its amplitude, enhancing the texture detail. A gain cap threshold is set during gain adjustment to prevent over-enhancement that could amplify noise. The high-frequency and low-frequency component layers are then recombined to obtain the texture-enhanced image, which serves as the enhanced image.

[0024] Enhanced images are obtained by performing illumination equalization and texture enhancement processing on the original images of the interior walls of historical buildings. Compared with the original images, the enhanced images have the characteristics of uniform illumination distribution and clear texture details, which can more accurately present the material texture and damage morphology of the wall surface. This provides a high-quality image data foundation for subsequent identification of wall structural boundaries, structural semantic partitioning, and extraction of damage morphology features in the enhanced images.

[0025] S2. Identify the structural boundary lines and material texture distribution features of the wall in the enhanced image, and perform structural semantic partitioning to generate a structural semantic region map.

[0026] Specifically, after obtaining the enhanced image, structural semantic partitioning is performed to identify different structural components of the wall, providing spatial localization for subsequent damage morphology extraction within each structural region. The interior walls of historical buildings typically consist of various structural elements, including masonry areas, mortar joint areas, and opening areas. Different structural regions exhibit differences in material properties, surface features, and damage manifestations. For example, damage in masonry areas mainly manifests as surface cracks and spalling, while damage in mortar joint areas primarily manifests as mortar detachment and loosening. Opening areas are prone to radial cracks caused by stress concentration at their edges. Therefore, before performing damage detection, structural semantic partitioning of the wall image clarifies the spatial extent of each structural region. This allows for the adoption of appropriate damage feature extraction strategies tailored to the characteristics of different structural regions, and also provides a structural topological basis for subsequent analysis of the propagation relationship of damage between different structural regions.

[0027] First, the structural boundary lines and material texture distribution features of the wall are identified in the enhanced image. When identifying the structural boundary lines of the wall in the enhanced image, edge detection processing is first performed. Specifically, the gray-level gradient magnitude between each pixel position and its adjacent pixels is calculated, and pixels with gradient magnitudes greater than a preset edge gradient threshold are marked as edge pixels, forming an initial set of edge pixels. Since there are material boundaries between masonry and mortar joints on the wall surface, and morphological boundaries between opening contours and the main body of the wall, these locations exhibit relatively obvious gray-level jumps in the image and can be captured by edge detection. Then, connectivity analysis and line segment fitting processing are performed on the initial set of edge pixels to connect discrete edge pixels into continuous edge segments. The edge segments are classified according to their directional characteristics, identifying horizontal and vertical edge segments, which reflect the arrangement structure of the masonry. Simultaneously, closed contours formed by multiple line segments connected end-to-end are identified; these closed contours typically correspond to opening areas on the wall. The horizontal edge segments, vertical edge segments, and closed contour segments identified above are used as the structural boundary lines of the wall. When identifying material texture distribution features in enhanced images, the enhanced image is divided into multiple local texture analysis windows. Within each texture analysis window, texture description features are calculated based on the gray-level co-occurrence matrix. These texture description features include texture roughness, texture directionality, and texture uniformity. Different materials in the walls of historical buildings exhibit different texture characteristics. For example, brick and stone materials typically have relatively rough texture features with weak directionality; mortar joints usually have a more pronounced texture directionality along the joint's extension direction; and adobe materials typically have fine and highly uniform texture features. Based on the texture description features calculated from each texture analysis window, a material texture distribution feature map of the enhanced image is constructed.

[0028] After obtaining the structural boundary lines and material texture distribution features, structural semantic partitioning is performed. Using the structural boundary lines as the initial boundaries for region division, the enhanced image is divided into multiple initial candidate regions. The texture description features of each initial candidate region are statistically analyzed, and the mean texture feature value is calculated. Region merging is performed based on the similarity of texture features between adjacent regions; adjacent regions with similar texture features are merged into the same structural region, while regions with significantly different texture features are divided into different structural regions. Semantic annotation is performed on each merged structural region. Based on the geometric morphology and texture features of the structural regions, they are labeled with corresponding semantic categories. Regions with large areas and high texture roughness are labeled as masonry regions; regions with strip-like distribution and obvious texture directionality are labeled as mortar joint regions; and regions with closed contour boundaries are labeled as opening regions. The spatial extent and semantic annotation information of each structural region are integrated to generate a structural semantic region map.

[0029] The structural semantic region map identifies the type of wall structure region to which each location in the enhanced image belongs at the pixel level, providing a spatial positioning basis for subsequent damage morphology extraction processing in each wall structure region, and providing structural topology information for subsequent calculation of damage propagation potential based on the adjacency relationship between structural semantic regions.

[0030] S3. Using the structural semantic region map, perform enhanced image damage morphology extraction processing in each wall structure region to identify crack textures, peeling boundaries and color degradation areas on the wall surface, and construct a set of wall damage morphology features based on the continuity of crack texture direction, the shape contour of peeling boundaries and the gradient changes of color degradation areas.

[0031] Specifically, after obtaining the structural semantic region map, the damage morphology extraction process is performed on the enhanced image in each wall structure region using the structural semantic region map. The structural semantic region map identifies the type of wall structure region to which each pixel position in the enhanced image belongs. Based on the structural semantic region map, the pixel set corresponding to each wall structure region in the enhanced image can be determined. The pixel set of each structure region is used as the damage detection region, and damage morphology extraction is performed in the damage detection region.

[0032] The main types of damage to the interior walls of historical buildings include cracks, peeling, and discoloration. Cracks appear as linear damage marks extending in a specific direction on the wall surface; peeling appears as irregular areas of missing material on the wall surface; and discoloration appears as areas of color fading or discoloration on the wall surface caused by factors such as dampness, weathering, and pollution. These three types of damage have different visual characteristics in images and require different feature extraction methods for identification.

[0033] For crack texture identification, directional gradient calculation is performed on the enhanced image within the damaged detection area to identify pixel sequences with linear continuity. Cracks appear in the image as dark linear regions extending along a specific direction, with pixel grayscale values ​​typically lower than the surrounding normal wall areas, and adjacent pixels exhibit directional consistency and spatial connectivity. Crack texture features are extracted based on the directional consistency and spatial connectivity of the pixel sequences, and the extension characteristics of the crack are characterized by the continuity of the crack texture's direction.

[0034] For the identification of spalling boundaries, edge detection and region segmentation are performed on the enhanced image within the defect detection area to identify irregular defect areas on the wall surface. The spalling area appears in the image as a local region with a clear boundary from the surrounding normal wall, and its boundary contour usually exhibits irregular morphological features. Spalling boundary features are extracted based on the contour curvature of the irregular defect area boundary, and the geometric characteristics of the spalling area are characterized based on the morphological contour of the spalling boundary.

[0035] For the identification of chromatic degradation regions, chromatic component gradient analysis is performed on the enhanced image within the defect detection area to identify pixel regions with continuous chromatic attenuation characteristics. Chromatic degradation regions in an image are areas where the color gradually decreases compared to the surrounding normal areas, and their chromaticity values ​​exhibit a continuously changing gradient characteristic along the spatial direction. Chromatic degradation features are extracted based on the spatial distribution of the chromatic gradient, and the spatial expansion characteristics of chromatic degradation are characterized based on the gradient changes in chromatic degradation regions.

[0036] Based on the extracted crack texture features, spalling boundary features, and color degradation features, a set of wall damage morphology features is constructed. This set integrates feature information from three damage types, providing a data foundation for subsequently generating a damage morphology response field and calculating the damage propagation potential.

[0037] S4. Generate a damage morphology response field based on the structural semantic region map and the set of wall damage morphology features. Combine the adjacency relationship between structural semantic regions and the directional consistency of crack texture, the neighborhood expansion trend of the peeling boundary and the gradient diffusion direction of the color degradation region to calculate the damage propagation potential value and form a wall damage propagation feature map.

[0038] Specifically, after obtaining the structural semantic region map and the set of wall damage morphological features, a damage morphological response field is generated based on these features, and the damage propagation potential is calculated to form a wall damage propagation feature map. Existing wall damage detection methods primarily focus on identifying the current state of the damage, failing to reflect its evolutionary trend. However, wall damage typically continues to develop along specific directions after it occurs; cracks extend along the stress direction, spalling areas expand outwards, and color degradation spreads along the direction of moisture penetration or pollution diffusion. Therefore, constructing a damage propagation feature map to characterize the potential evolutionary trend of the damage provides a basis for subsequent identification of damage propagation paths and assessment of damage development directions.

[0039] First, a damage morphology response field is generated based on the spatial distribution of the wall damage morphology features in the enhanced image. Specifically, for each pixel location in the enhanced image, the damage morphology response intensity is calculated based on the presence of crack texture features, peeling boundary features, or color degradation features at that location, as well as the intensity values ​​of each feature. If a pixel location has damage features, its damage morphology response intensity depends on the salience of the damage features; if a pixel location does not have damage features, its damage morphology response intensity is zero. The damage morphology response intensities of all pixel locations in the enhanced image are integrated to form the damage morphology response field. The damage morphology response field characterizes the severity of damage at each pixel location in image form; regions with higher damage morphology response intensities indicate more significant damage.

[0040] Then, based on the structural semantic region map, the adjacency relationships between each wall structural region are determined, and the adjacency propagation relationships of the structural regions are established in the damage morphology response field. Adjacency propagation relationship refers to the spatial proximity and shared boundary between two structural regions. Since damage propagation typically crosses adjacent structural regions—for example, cracks may extend from a masonry region to an adjacent mortar joint region, and spalling may extend from a mortar joint region to an adjacent masonry region—it is necessary to establish adjacency propagation relationships between structural regions to consider cross-regional propagation paths when calculating the damage propagation potential.

[0041] Next, propagation weights are calculated based on the propagation characteristics of the three types of damage features. For crack texture features, the crack propagation direction weight is calculated based on the crack extension direction. This weight characterizes the tendency of the crack to continue propagating along its extension direction, with higher weights in the crack extension direction and lower weights perpendicular to the crack extension direction. For spalling boundary features, the spalling extension weight is calculated based on the outward expansion direction of the spalling region boundary. This weight characterizes the tendency of the spalling region to expand into its surrounding neighborhood, with higher weights in the normal direction of the spalling boundary. For chromatic degradation features, the chromatic diffusion weight is calculated based on the diffusion direction of the chromatic gradient. This weight characterizes the tendency of chromatic degradation to continue spreading along the gradient descent direction, with higher weights in the chromatic gradient descent direction.

[0042] Subsequently, under the constraint of adjacency propagation relations, a direction-weighted propagation calculation is performed on the damaged morphology response field based on the crack propagation direction weight, spalling propagation weight, and chromaticity diffusion weight to generate a damaged propagation potential distribution. Specifically, for each pixel position in the damaged morphology response field, damaged potential energy is propagated to adjacent pixel positions according to its damaged morphology response intensity and corresponding direction propagation weight. The propagation potential energy received by adjacent pixel positions is positively correlated with the damaged morphology response intensity and propagation direction weight of the source pixel. Simultaneously, the propagation calculation is constrained by adjacency propagation relations; when the propagation path crosses different structural regions, the adjacency relationship between structural regions needs to be considered. Through iterative execution of the propagation calculation, the damaged potential energy gradually diffuses along the dominant propagation direction of each damaged feature, forming a damaged propagation potential distribution. A wall damaged propagation feature map is then formed based on the damaged propagation potential distribution.

[0043] The wall damage propagation feature map represents the damage propagation potential value at each location at the pixel level. Areas with higher damage propagation potential values ​​are more likely to become paths for further damage development. The wall damage propagation feature map provides a data foundation for subsequent identification of damage propagation paths and calculation of damage propagation intensity indicators.

[0044] S5. Identify the propagation path using the wall damage propagation feature map, calculate the damage propagation intensity index, and generate the wall damage detection results using the damage propagation intensity index and the structural semantic region map.

[0045] Specifically, the wall damage propagation feature map represents the damage propagation potential value at each pixel location. Areas with higher propagation potential values ​​indicate that these locations are more likely to become paths for further damage development. However, the propagation potential value distribution is discrete pixel-level data, requiring further extraction of spatially continuous propagation paths and quantification of the intensity characteristics of these paths to generate detection results that can be used for damage assessment and repair decisions.

[0046] First, propagation paths are identified in the wall damage propagation feature map. Specifically, pixel regions with continuously increasing propagation potential values ​​are identified in the wall damage propagation feature map. Adjacent pixels with propagation potential values ​​all above a preset potential threshold are grouped together. Connectivity analysis is performed on the grouped pixel regions to divide spatially connected pixels into the same connected component, constructing multiple candidate damage propagation regions. Each candidate damage propagation region represents a potential damage propagation range. Path skeleton extraction is performed on each candidate damage propagation region. By peeling away the edge pixels of the candidate damage propagation regions layer by layer, the central skeleton structure of the region is preserved, generating a propagation path that characterizes the damage propagation trend. The propagation path is presented as a linear structure, reflecting the main spatial extension direction and development trajectory of the damage.

[0047] Then, the damage propagation intensity index is calculated based on the morphological characteristics of the propagation path. Specifically, the extension length of each propagation path is calculated, reflecting the spatial span of damage propagation. The number of branches in each propagation path is calculated, reflecting the degree of diffusion of damage propagation; more branches indicate a more pronounced trend of damage developing in multiple directions simultaneously. The path directional stability of each propagation path is calculated, reflecting the consistency of the propagation path's extension along the dominant direction; higher directional stability indicates a more pronounced trend of damage continuously developing in a single direction. The corresponding damage propagation intensity index is calculated by comprehensively considering the propagation path's extension length, number of branches, and path directional stability. A higher damage propagation intensity index indicates a stronger trend of development and evolution of damage corresponding to that propagation path.

[0048] Subsequently, wall damage detection results are generated using damage propagation intensity indices and structural semantic region maps. Specifically, each propagation path and its corresponding damage propagation intensity index are mapped to the corresponding wall structural region in the structural semantic region map. Based on the mapping results, the number of propagation paths and the cumulative value of damage propagation intensity indices within each structural region are counted to determine the regional damage degree of each structural region. The regional damage degree reflects the severity and development trend of damage in that structural region. Wall damage detection results are generated based on the regional damage degree of each structural region. The wall damage detection results contain damage degree assessment information and damage propagation path information for each wall structural region, reflecting the current state and potential evolution trend of wall damage, and providing a decision-making basis for the protection, repair, and safety assessment of historical building walls.

[0049] Through the above steps, image-based vision-based detection of interior wall damage in historical buildings was achieved. First, the original image underwent illumination equalization and texture enhancement processing to create an enhanced image, addressing the challenges of complex lighting conditions and blurred texture details within historical buildings. Then, structural boundary lines and material texture distribution features of the walls were identified in the enhanced image, and structural semantic partitioning was performed to generate a structural semantic region map, providing spatial localization and structural topological basis for subsequent damage detection. Next, damage morphology extraction processing was performed in each wall structural region, identifying three types of damage morphologies: crack textures, peeling boundaries, and color degradation areas, constructing a set of wall damage morphology features, achieving comprehensive identification of multiple types of damage. Subsequently, a damage morphology response field was generated based on the structural semantic region map and the wall damage morphology feature set. The damage propagation potential value was calculated by combining the directional propagation weights of the three types of damage features, forming a wall damage propagation feature map, characterizing the potential evolution trend of the damage. Finally, the wall damage propagation feature map was used to identify the propagation path, calculate the damage propagation intensity index, and combine it with the structural semantic region map to generate the wall damage detection results. Image visual analysis enables comprehensive and accurate identification of damage to the interior walls of historical buildings. By extracting three types of damage—cracks, peeling, and color degradation—it avoids the problem of missed detection that may occur with a single detection method. At the same time, by constructing a damage propagation feature map and identifying the propagation path, it effectively reflects the evolution trend of damage, providing comprehensive and complete detection results for the protection, repair, and safety assessment of the walls of historical buildings.

[0050] Furthermore, structural semantic region maps are used to perform enhanced image morphology extraction processing in each wall structure region, including:

[0051] S31. Determine the pixel set of each wall structure region in the enhanced image based on the structural semantic region map, and use the pixel set as the damage detection region.

[0052] S32. Perform directional gradient calculation on the enhanced image within the defect detection area, identify pixel sequences with linear continuity characteristics, and extract crack texture features based on the directional consistency and spatial connectivity of the pixel sequences.

[0053] S33. Perform edge detection and region segmentation processing on the enhanced image within the defect detection area to identify irregular defect areas on the wall surface, and extract the peeling boundary features based on the contour curvature of the irregular defect area boundary.

[0054] S34. Perform chromaticity component gradient analysis on the enhanced image within the damaged detection area to identify pixel regions with continuous chromaticity decay characteristics, and extract chromaticity degradation features based on the spatial distribution of the chromaticity gradient.

[0055] S35. Construct a set of wall damage morphology features based on crack texture features, peeling boundary features, and color degradation features.

[0056] In a preferred embodiment, firstly, the pixel set of each wall structure region in the enhanced image is determined based on the structural semantic region map, and this pixel set serves as the damage detection region. Specifically, the structural semantic region map identifies the structural region type to which each pixel location belongs. The pixel locations in the structural semantic region map are traversed, and the structural region label corresponding to each pixel location is read. Pixel locations with the same structural region label are aggregated into a pixel set for that structural region. Each pixel set is stored in the form of a pixel coordinate list, recording all pixel locations covered by the corresponding structural region in the enhanced image. For each wall structure region, its pixel set represents the spatial range corresponding to that region in the enhanced image, and this pixel set serves as the damage detection region for subsequent damage morphology extraction. During subsequent damage morphology extraction, only pixels within the damage detection region are processed, avoiding misprocessing of non-wall or irrelevant regions in the enhanced image, and facilitating differentiated analysis based on the damage characteristics of different structural regions.

[0057] Then, directional gradient calculation is performed on the enhanced image within the defect detection area to identify pixel sequences with linear continuity characteristics. Crack texture features are then extracted based on the directional consistency and spatial connectivity of the pixel sequences. Cracks appear in the image as linear dark regions extending along a specific direction. Pixels with significant directionality can be identified through directional gradient calculation, and crack texture features are then extracted based on the spatial continuity and directional consistency of these pixels.

[0058] Simultaneously, edge detection and region segmentation are performed on the enhanced image within the defect detection area to identify irregular defect areas on the wall surface. The spalling boundary features are then extracted based on the contour curvature of the irregular defect area boundaries. The spalling area appears in the image as a localized defect area with a clear boundary from the surrounding normal wall. Edge detection and region segmentation can locate the extent of the defect area, and then the spalling boundary features are extracted based on the curvature variation characteristics of the defect area's boundary contour.

[0059] Furthermore, chromaticity component gradient analysis is performed on the enhanced image within the defect detection area to identify pixel regions with continuous chromaticity decay characteristics, and chromaticity degradation features are extracted based on the spatial distribution of the chromaticity gradient. Chromaticity degradation regions in the image are areas where the color gradually decreases compared to the surrounding areas. Chromaticity component gradient analysis can identify regions with continuously changing chromaticity values, and then chromaticity degradation features can be extracted based on the spatial distribution characteristics of the chromaticity gradient.

[0060] Subsequently, a set of wall damage morphology features was constructed based on crack texture features, spalling boundary features, and color degradation features. Specifically, the crack texture features, spalling boundary features, and color degradation features extracted from each damage detection area were integrated to form the set of wall damage morphology features. The set of wall damage morphology features contains feature information of three types of damage morphologies on the wall surface and their spatial location information in the enhanced image, providing a data foundation for subsequent generation of the damage morphology response field and calculation of the damage propagation potential.

[0061] Through the above steps, the three types of damage morphologies—crack texture, peeling boundary, and color degradation—were extracted separately in each wall structure area, and a set of wall damage morphology features containing multiple types of damage characteristic information was constructed, providing complete feature data support for subsequent damage propagation feature modeling.

[0062] Furthermore, crack texture features are extracted, including:

[0063] S321. Based on the directional gradient calculation results, establish a pixel orientation distribution map, and generate multiple candidate crack pixel sets by performing orientation clustering on pixels with similar directional gradients.

[0064] S322. Perform connectivity analysis on each candidate crack pixel set to form crack connected segments, and select effective crack segments based on the extension length and directional stability of the crack connected segments.

[0065] S323. Calculate the crack direction consistency index based on the angle between the extension direction of the effective crack segment and the texture direction of the adjacent wall masonry, and generate crack texture features based on the crack direction consistency index.

[0066] In a preferred embodiment, when extracting crack texture features, firstly, directional gradient calculation is performed on the enhanced image within the defect detection area. For each pixel location, the gray-level difference between that pixel and its neighboring pixels in the horizontal and vertical directions is calculated to obtain the horizontal gradient component and the vertical gradient component. Based on the horizontal and vertical gradient components, the gradient magnitude and gradient direction angle of that pixel are calculated, where the gradient magnitude reflects the intensity of the gray-level change at that pixel location, and the gradient direction angle reflects the dominant direction of the gray-level change; the gradient direction angle ranges from 0° to 180°. The gradient magnitude and gradient direction angle of each pixel location are used as the directional gradient calculation results. Then, a pixel orientation distribution map is established based on the directional gradient calculation results. The gradient direction angles of each pixel location within the defect detection area are summarized to establish a pixel orientation distribution map, which records the gradient direction information of each pixel location in image form. Cracks in the image appear as linear dark regions extending along a specific direction, and pixels within the crack region have similar gradient direction angles. Therefore, by performing directional clustering on pixels with similar directional gradients, pixels that may belong to the same crack can be grouped together. Specifically, the gradient direction angle range of 0° to 180° is divided into multiple directional intervals. The span of each directional interval is set according to the crack direction recognition accuracy requirements. For example, if the span of each directional interval is set to 15°, then a total of 12 directional intervals are divided. Pixels whose gradient direction angles fall into the same directional interval and whose gradient magnitude is greater than a preset magnitude threshold are grouped into the same directional category. The magnitude threshold is set according to the grayscale difference between the crack area and the normal wall area in the enhanced image to effectively distinguish crack edge pixels from flat area pixels. For example, it can be set to 5% to 10% of the image grayscale range. For pixels within each directional category, spatial clustering is performed based on their spatial proximity. Specifically, the spatial distance between pixels is calculated, and pixels whose spatial distance is less than a preset proximity distance threshold are grouped into the same candidate crack pixel set. The proximity distance threshold is set according to the width of the crack in the wall image to ensure that adjacent pixels within the same crack can be grouped together. For example, it can be set to a distance of 3 to 5 pixels. Through the above directional clustering process, multiple candidate crack pixel sets are generated, and each candidate crack pixel set represents a pixel region where cracks may exist.

[0067] Then, connectivity analysis is performed on each candidate crack pixel set to form crack connected segments. Valid crack segments are then selected based on their extension length and directional stability. Specifically, connectivity analysis is performed on each candidate crack pixel set to determine the spatial connectivity between pixels within the set. If two pixels are spatially adjacent and belong to the same candidate crack pixel set, they are considered connected. Connected pixels within the candidate crack pixel set are divided into the same connected region, forming crack connected segments. Each crack connected segment represents a spatially continuous potential crack region. Due to interference from image noise, wall surface stains, etc., some candidate crack pixel sets may not be real cracks, requiring screening to eliminate these interferences. The extension length and directional stability of each crack connected segment are calculated. For the calculation of the extension length, a straight line fit is first performed on the coordinates of each pixel within the crack connected segment, and the direction of the fitted line is taken as the main direction of the crack connected segment. Then, the coordinates of each pixel within the crack connection segment are projected onto the main direction, and the difference between the maximum and minimum projected coordinates is calculated. This difference is the extension length of the crack connection segment, reflecting the spatial span of the crack along the main direction. For directional stability calculation, first, the average gradient direction angle of each pixel within the crack connection segment is calculated as the average direction angle. Then, the difference between the gradient direction angle of each pixel and the average direction angle is calculated. The squares of these differences are summed and divided by the number of pixels to obtain the variance. This variance is the measure of directional stability; the smaller the variance, the more consistent the gradient directions of each pixel, and the higher the directional stability. Next, valid crack segments are selected based on the extension length and directional stability of the crack connection segment. Crack connection segments with an extension length greater than a preset length threshold and a gradient direction angle variance less than a preset variance threshold are selected as valid crack segments. The length threshold is set according to the wall image resolution and the minimum crack length to be detected to exclude short, false crack segments caused by noise or stains. For example, in an image with a resolution of 1920×1080, the length threshold can be set to 20 to 30 pixels. The variance threshold is set based on the typical dispersion of pixel gradient directions within a real crack segment to exclude non-crack regions with chaotic directions. For example, the variance threshold can be set to 100 to 200 square degrees. Crack segments with excessively short extension lengths or excessively large gradient direction angle variances are excluded as noise interference.

[0068] Subsequently, a crack direction consistency index is calculated based on the angle between the extension direction of the effective crack segment and the texture direction of the adjacent wall masonry. Crack texture features are then generated based on this index. Specifically, the extension direction of each effective crack segment is determined by performing linear fitting on the pixel coordinates within the effective crack segment, and the direction of the fitted line is taken as the extension direction of that effective crack segment. Simultaneously, the wall structure region where the effective crack segment is located is determined based on the structural semantic region map, and the texture direction of the adjacent masonry within that region is obtained. The masonry texture direction is determined based on the horizontal and vertical edge segments identified in step S2, typically either horizontal or vertical. Next, the angle between the extension direction of the effective crack segment and the texture direction of the adjacent wall masonry is calculated. Crack formation is usually related to the stress state of the wall, and cracks developing along a specific direction often have a certain angular relationship with the masonry texture direction. The crack direction consistency index is calculated based on this angular relationship, specifically by calculating the minimum angle difference between the angle and 0° or 90°, and the cosine of this angle difference is taken as the crack direction consistency index. When the crack propagation direction is parallel or perpendicular to the masonry texture direction, the angle difference is close to 0°, and the crack direction consistency index is close to 1, indicating that the crack may develop along the weak direction of the masonry structure. When the crack propagation direction is oblique to the masonry texture direction at 45°, the angle difference is the largest, and the crack direction consistency index is the lowest. Subsequently, crack texture features are generated based on the crack direction consistency index. The crack texture features include the spatial location, propagation direction, propagation length, and crack direction consistency index of the effective crack segments. The spatial location records the pixel coordinate range of the effective crack segment in the enhanced image, the propagation direction records the main direction angle of the crack, the propagation length records the spatial span of the crack, and the crack direction consistency index records the degree of directional correlation between the crack and the wall structure texture. The crack texture features provide data support for the subsequent construction of the wall damage morphology feature set and the calculation of crack propagation direction weights.

[0069] Through the above steps, the complete extraction of wall crack texture features is achieved, which can accurately identify the crack morphology on the wall surface and quantify the directional correlation between cracks and wall structural texture, providing data support for subsequent construction of wall damage morphology feature set and analysis of crack propagation trend.

[0070] Furthermore, the features of the peeling boundary are extracted, including:

[0071] S331. Perform region growing processing on the edge pixels in the defect detection area to form an irregular defect area;

[0072] S332. Extract the boundary contour curve of the irregular defect area and calculate the curvature change sequence of the boundary contour curve;

[0073] S333. Identify boundary inflection points with abrupt curvature characteristics based on the curvature change sequence, and calculate the boundary irregularity of the defect area based on the spatial distribution of the boundary inflection points.

[0074] S334. Generate peeling boundary features based on the boundary irregularity and the area of ​​the irregular defect region.

[0075] In a preferred embodiment, when extracting the features of the peeling boundary, firstly, region growing is performed on the edge pixels in the damaged area to form an irregular defect region. Specifically, edge detection is performed on the enhanced image within the damaged area. For each pixel location, the gray-level gradient magnitude between that pixel and its neighboring pixels is calculated. Pixels with gray-level gradient magnitudes greater than a preset edge gradient threshold are marked as edge pixels. The edge gradient threshold is set based on the typical gray-level difference between the peeling area boundary and the normal wall area, for example, it can be set to 8% to 12% of the image gray-level range. The peeling area in the image appears as a local area with a significant gray-level difference from the surrounding normal wall, and its boundary position has a significant gray-level jump, which can be captured by edge detection. Then, region growing is performed on the edge pixels in the damaged area. Specifically, connectivity analysis is performed on the edge pixels, and spatially connected edge pixels are aggregated to form an edge contour. In the case of forming a closed edge contour, the edge pixels on the closed edge contour are used as the starting boundary, and region growing and filling is performed into the contour. First, pixels adjacent to the edge pixels and located inside the closed edge contour are included in the filling area. Then, based on these pixels, the process continues to expand inward, gradually including pixels adjacent to already filled pixels and located inside the closed edge contour until all pixels inside the closed edge contour are filled, forming irregular defect areas. Each irregular defect area represents a potential peeling area, the extent of which is determined by the area enclosed by the edge contour.

[0076] Then, the boundary contour curves of the irregular defect areas are extracted, and the curvature change sequence of the boundary contour curves is calculated. Specifically, the boundary contours of each irregular defect area are extracted; these boundary contours are the edge pixels that form closed edge contours during the aforementioned region growing process. Pixel traversal is performed along the boundary of the irregular defect area. Any pixel on the boundary contour is selected as the starting point, and adjacent boundary pixels are visited sequentially in a clockwise or counterclockwise direction. The coordinates of each boundary pixel are recorded in the visiting order to form the boundary contour curve. The boundary contour curve is stored in the form of an ordered sequence of pixel coordinates, recording the complete shape of the defect area boundary. Then, the curvature value is calculated for each pixel on the boundary contour curve. The curvature value reflects the degree of curvature of the boundary contour curve at that point. The curvature is calculated as follows: for the i-th pixel Pi on the boundary contour curve, the k-th pixel Pi-k before it and the k-th pixel Pi+k after it are taken, where the value of k is set according to the smoothness of the boundary contour, for example, k can be set to 3 to 5. Since the boundary contour curve is a closed curve, when ik is less than 0, values ​​are taken from the end of the sequence in a loop; when i+k exceeds the sequence length, values ​​are taken from the beginning of the sequence in a loop. The circle passing through the three pixels Pi-k, Pi, and Pi+k is calculated using a three-point method, a conventional method in geometry. The coordinates of the center and the radius R of the circle are solved by solving a simultaneous equation based on the coordinates of the three pixels. The curvature value is equal to the reciprocal of the radius R, i.e., curvature value = 1 / R. The smaller the radius R, the larger the curvature value, indicating a more severe boundary curvature at that point. When the three pixels are nearly collinear, the radius R tends to infinity, and the curvature value tends to zero, indicating that the boundary at that point is nearly straight. Arranging the curvature values ​​of each pixel on the boundary contour curve in spatial order forms a curvature variation sequence, which reflects the change in the degree of curvature of the boundary contour curve along its direction.

[0077] Next, boundary inflection points with abrupt curvature features are identified based on the curvature change sequence, and the boundary irregularity of the defective region is calculated based on the spatial distribution of these inflection points. Specifically, first, the average curvature value of all curvature values ​​in the curvature change sequence is calculated as the average curvature. Then, each curvature value in the curvature change sequence is traversed. For each pixel, it is determined whether its curvature value is greater than a preset multiple of the average curvature. If it is, the pixel is marked as a boundary inflection point. The preset multiple is set based on the typical curvature distribution characteristics of the boundary contour and the detection sensitivity requirements. The smaller the multiple, the more boundary inflection points are detected; the larger the multiple, the more inflection points with prominent curvature are detected. For example, it can be set to 2 to 3 times, meaning that when the curvature value of a pixel is greater than 2 to 3 times the average curvature, the boundary curvature at that point is considered to be significantly higher than the average level and is marked as a boundary inflection point. Boundary inflection points represent positions on the boundary contour curve where the curvature is significantly greater than the average level. The boundaries of the peeling area usually exhibit irregular shapes and contain many boundary inflection points. Then, the boundary irregularity of the defective region is calculated based on the spatial distribution of the boundary inflection points. The boundary irregularity is calculated as follows: The number of boundary inflection points N on the boundary contour curve is counted; the total length L of the boundary contour curve is calculated, represented by the number of pixels contained in the boundary contour curve; and the boundary irregularity is obtained by dividing the number of boundary inflection points N by the total length L, i.e., boundary irregularity = N / L. A higher boundary irregularity indicates more inflection points per unit length of boundary, more irregular boundary morphology of the damaged area, and a more consistent characteristic with typical peeling and damage.

[0078] Subsequently, peeling boundary features are generated based on boundary irregularity and the area of ​​irregular defect regions. Specifically, the area S of each irregular defect region is calculated, with the number of pixels contained within the irregular defect region serving as a metric; a higher number of pixels indicates a larger peeling region. The peeling boundary features, generated based on boundary irregularity and the area of ​​irregular defect regions, include the spatial location, boundary contour curve, boundary irregularity, and area of ​​the irregular defect region. The spatial location records the pixel coordinate range of the irregular defect region in the enhanced image; the boundary contour curve records the boundary morphology of the defect region; the boundary irregularity records the degree of irregularity of the boundary morphology; and the area records the size of the peeling region. These peeling boundary features provide data support for subsequent construction of a set of wall damage morphology features and the calculation of peeling expansion weights.

[0079] Through the above steps, the complete extraction of wall peeling boundary features was achieved, which can accurately identify the peeling area on the wall surface and quantify the irregularity of the peeling boundary, providing data support for the subsequent construction of a set of wall damage morphology features and analysis of peeling expansion trends.

[0080] Furthermore, chromatic degradation features are extracted, including:

[0081] S341. Convert the enhanced image to chroma component space and extract the chroma channel images;

[0082] S342. Perform local gradient calculation on the chroma channel image within the damage detection area to generate a chroma gradient distribution map;

[0083] S343. Identify continuous chromaticity attenuation regions based on the chromaticity gradient distribution map, and determine the range of chromaticity degradation regions through region expansion;

[0084] S344. Generate chromatic degradation features based on the chromaticity gradient change amplitude and spatial diffusion range within the chromaticity degradation region.

[0085] In a preferred embodiment, when extracting chromaticity degradation features, the enhanced image is first converted to a chromaticity component space, and chromaticity channel images are extracted. Specifically, the enhanced image is stored in the RGB color space. In the RGB color space, the red, green, and blue channels simultaneously contain both luminance and color information, which is not conducive to analyzing color change features separately. Therefore, the enhanced image is converted from the RGB color space to a chromaticity component space, which separately expresses luminance and color information. For example, the Lab color space can be used, where the L channel represents luminance, and the a and b channels represent chromaticity. The converted image contains luminance and chromaticity channels, with the chromaticity channel reflecting the image's color information separately. The chromaticity channels of the converted image are extracted. For cases with multiple chromaticity channels, the values ​​of each chromaticity channel are merged. For example, for the Lab color space, the square root of the sum of the squares of the a and b channel values ​​is calculated as the composite chromaticity value, forming a chromaticity channel image. The value of each pixel in the chromaticity channel image reflects the color attribute at that location, unaffected by luminance changes, facilitating subsequent identification of color fading or discoloration areas caused by factors such as moisture, weathering, and pollution.

[0086] Then, local gradient calculations are performed on the chroma channel image within the defect detection region to generate a chroma gradient distribution map. Specifically, based on the defect detection region determined by the structural semantic region map, local gradient calculations are performed on the chroma channel image within the defect detection region. For each pixel position within the defect detection region, the difference in chroma values ​​between that pixel and its neighboring pixels in the horizontal and vertical directions is calculated to obtain the horizontal and vertical chroma gradient components. The chroma gradient magnitude and chroma gradient direction angle of that pixel are calculated based on the horizontal and vertical chroma gradient components. The chroma gradient magnitude is equal to the square root of the sum of the squares of the horizontal and vertical chroma gradient components, and the chroma gradient direction angle is equal to the arctangent of the ratio of the vertical to the horizontal chroma gradient components. The chroma gradient magnitude reflects the intensity of the chroma change at that pixel position, and the chroma gradient direction angle reflects the dominant direction of the chroma change. The chroma gradient magnitude and chroma gradient direction angle of each pixel position within the defect detection region are summarized to generate a chroma gradient distribution map. The chromaticity gradient distribution map records the chromaticity change information of each pixel position within the defect detection area in the form of an image. Areas with larger chromaticity gradient values ​​indicate that the color at that position has changed significantly compared to the surrounding area.

[0087] Next, continuous chromaticity decay regions are identified based on the chromaticity gradient distribution map, and the range of chromaticity degradation regions is determined through region expansion. Specifically, chromaticity degradation regions in an image are areas where the color gradually decreases compared to the surrounding normal areas. Their characteristic is that the chromaticity gradient changes continuously along a specific direction, and the chromaticity value gradually decreases along the gradient direction. To identify continuous chromaticity decay regions in the chromaticity gradient distribution map, a chromaticity gradient amplitude threshold is first set. Pixels with a chromaticity gradient amplitude greater than this threshold are marked as chromaticity change pixels. The chromaticity gradient amplitude threshold is set based on the typical chromaticity difference between the normal wall area and the chromaticity degradation region; for example, it can be set to 5% to 10% of the chromaticity value range of the chromaticity channel image. Then, connectivity analysis is performed on the chromaticity change pixels. Starting from any chromaticity change pixel as the starting pixel, its spatially adjacent chromaticity change pixels are checked, and the chromaticity gradient direction angle difference between the adjacent pixels and the starting pixel is calculated. If the difference is less than a preset direction tolerance threshold, the adjacent pixels are included in the same continuous chromaticity decay region. The directional tolerance threshold is set based on the typical gradient direction distribution characteristics of the chroma degradation region, for example, it can be set to 30° to 45°. Based on the newly included pixel, its adjacent chroma-changing pixels are checked, iterating until no new pixels meeting the criteria can be included, forming a continuous chroma decay region. The above process is repeated for the remaining unaggregated chroma-changing pixels until all chroma-changing pixels have been processed, forming multiple continuous chroma decay regions. After identifying the continuous chroma decay regions, the range of the chroma degradation region is determined by region expansion. Specifically, the continuous chroma decay region is the core region, and expansion starts from the boundary pixels of the core region and extends outwards. Each boundary pixel checks its adjacent pixels outwards along its respective chroma gradient direction. The expansion criterion is that the chroma value of the pixel to be expanded shows a decreasing trend along the gradient direction, and the decrease is within a reasonable range. The method for determining the reduction magnitude is to calculate the difference between the chroma value of the pixel to be expanded and the chroma value of the adjacent pixel at the boundary of the expanded region. If the chroma value of the pixel at the boundary of the expanded region is greater than the chroma value of the pixel to be expanded, and the difference is less than a preset reduction magnitude threshold, then the pixel to be expanded is included in the chroma degradation region. The reduction magnitude threshold is set according to the typical gradient characteristics of chroma degradation, for example, it can be set to 3% to 5% of the chroma value range of the chroma channel image. The region expansion is continuously performed, with the newly included pixels serving as new boundary pixels and continuing to expand outward along their chroma gradient direction, until there are no pixels that meet the expansion conditions in the expansion direction of all boundary pixels, thus forming a complete chroma degradation region.

[0088] Subsequently, chromaticity degradation features are generated based on the magnitude of chromaticity gradient changes and the spatial diffusion range within the chromaticity degradation region. Specifically, the magnitude of chromaticity gradient changes within the chromaticity degradation region is calculated. The magnitude of chromaticity gradient changes reflects the severity of chromaticity degradation. The calculation method is as follows: pixels within the continuous chromaticity decay region are designated as core pixels, and pixels at the boundary of the chromaticity degradation region are designated as edge pixels. Edge pixels are those pixels within the chromaticity degradation region that do not have adjacent external pixels satisfying the expansion condition. The average chromaticity value of the core pixels and the average chromaticity value of the edge pixels are calculated. The difference between the average chromaticity value of the core pixels and the average chromaticity value of the edge pixels is taken as the magnitude of the chromaticity gradient change; a larger difference indicates a more severe chromaticity degradation. The spatial diffusion range of the chroma degradation region is calculated. This range reflects the extent of the chroma degradation's influence. The calculation method involves counting the number of pixels within the chroma degradation region as an area metric, and simultaneously calculating the maximum extension distance along the principal direction of the chroma gradient as a diffusion distance metric. The principal direction of the chroma gradient is the average angle of the chroma gradient direction of the core pixels, and the maximum extension distance is the farthest distance from the center point of the core region along the principal direction of the chroma gradient to the boundary of the chroma degradation region. Subsequently, chroma degradation features are generated based on the magnitude of the chroma gradient change and the spatial diffusion range. These features include the spatial location of the chroma degradation region, the principal direction of the chroma gradient, the magnitude of the chroma gradient change, and the spatial diffusion range. The spatial location records the pixel coordinates of the chroma degradation region in the enhanced image; the principal direction of the chroma gradient records the dominant diffusion direction of the chroma degradation; the magnitude of the chroma gradient change records the severity of the chroma degradation; and the spatial diffusion range records the size of the area affected by the chroma degradation. These chroma degradation features provide data support for subsequent construction of the wall damage morphology feature set and the calculation of chroma diffusion weights.

[0089] Through the above steps, the complete extraction of the color degradation characteristics of the wall is achieved, which can accurately identify the color degradation areas on the wall surface and quantify the degree and spread of color degradation, providing data support for the subsequent construction of a set of wall damage morphology features and analysis of color degradation spread trends.

[0090] Furthermore, a characteristic map of the propagation of wall damage is generated, including:

[0091] S41. A damage morphology response field is formed based on the spatial distribution of the wall damage morphology feature set in the enhanced image. The damage morphology response field is used to characterize the damage morphology response intensity at each pixel position.

[0092] S42. Determine the adjacency relationship between each wall structure region based on the structural semantic region map, and establish the adjacency propagation relationship of the structural region in the damaged morphology response field;

[0093] S43. Calculate the crack propagation direction weight based on the extension direction of the crack texture features, calculate the spalling extension weight based on the boundary extension direction of the spalling boundary features, and calculate the chromaticity diffusion weight based on the gradient diffusion direction of the chromaticity degradation characteristics.

[0094] S44. Under the constraint of adjacency propagation relationship, the directional weighted propagation calculation of the damage morphology response field is performed based on the crack propagation direction weight, the peeling propagation weight, and the chromaticity diffusion weight to generate the damage propagation potential value distribution, and a wall damage propagation characteristic map is formed based on the damage propagation potential value.

[0095] In a preferred embodiment, when forming the wall damage propagation feature map, firstly, a damage morphology response field is formed based on the spatial distribution of the wall damage morphology feature set in the enhanced image. This field characterizes the damage morphology response intensity at each pixel location. Specifically, the wall damage morphology feature set includes crack texture features, spalling boundary features, and chromatic degradation features. Each feature records the spatial location of the corresponding damaged area in the enhanced image. Each pixel location in the enhanced image is traversed to determine if it falls within a certain damaged area. If a pixel location falls within the effective crack segment range corresponding to the crack texture feature, the crack response intensity is calculated based on the extension length of the crack segment. Specifically, the extension length is divided by a preset crack length normalization benchmark to obtain a normalized extension length, which is then used as the crack response intensity. The normalized reference value for crack length is set based on the extension length of a typical crack in the wall image, for example, it can be set to 100 pixels. If the extension length of a crack segment is 50 pixels, then its crack response intensity is 50 ÷ 100 = 0.5. If a pixel location is within the irregular defect area corresponding to the peeling boundary feature, the peeling response intensity is calculated based on the boundary irregularity and area of ​​the defect area. Specifically, the boundary irregularity is divided by the preset normalized reference value for boundary irregularity to obtain the normalized boundary irregularity, the area is divided by the preset normalized reference value for area area to obtain the normalized area, and the sum of the normalized boundary irregularity and the normalized area is divided by 2 to obtain the peeling response intensity. The normalized baseline value for boundary irregularity is set based on the typical boundary irregularity of the peeling area, for example, it can be set to 0.1. The normalized baseline value for area area is set based on the typical area of ​​the peeling area, for example, it can be set to 500 pixels. If the boundary irregularity of a certain peeling area is 0.05 and the area is 300 pixels, then its normalized boundary irregularity is 0.05÷0.1=0.5, the normalized area is 300÷500=0.6, and the peeling response intensity is (0.5+0.6)÷2=0.55. If a pixel is located within the chromatic degradation region corresponding to the chromatic degradation feature, the chromatic degradation response intensity is calculated based on the chromatic gradient change amplitude and spatial diffusion range of that region. Specifically, the chromatic gradient change amplitude is divided by a preset chromatic gradient change amplitude normalization reference value to obtain the normalized chromatic gradient change amplitude, the spatial diffusion range is divided by a preset spatial diffusion range normalization reference value to obtain the normalized spatial diffusion range, and the sum of the normalized chromatic gradient change amplitude and the normalized spatial diffusion range is divided by 2 to obtain the chromatic degradation response intensity.The normalized reference value for the chromaticity gradient change amplitude is set according to the typical chromaticity change amplitude of the chromaticity degradation region. For example, it can be set to 20% of the chromaticity value range. The spatial diffusion range is represented by the number of pixels contained in the chromaticity degradation region. The normalized reference value for the spatial diffusion range is set according to the typical area of ​​the chromaticity degradation region. For example, it can be set to 500 pixels. If the chromaticity gradient change amplitude of a certain chromaticity degradation region is 10% of the chromaticity value range and the spatial diffusion range is 400 pixels, then its normalized chromaticity gradient change amplitude is 10%÷20%=0.5, the normalized spatial diffusion range is 400÷500=0.8, and the chromaticity degradation response intensity is (0.5+0.8)÷2=0.65. If a pixel location falls within multiple damaged areas, the weighted sum of the response intensities for each type of damage is used to obtain the pixel's overall response intensity. The weights for each type of damage response intensity are set according to the severity of the damage type; for example, the weight for crack response intensity can be set to 0.4, for peeling response intensity to 0.35, and for chromatic degradation response intensity to 0.25. The damage morphology response intensities of all pixel locations in the enhanced image are then integrated to form a damage morphology response field. This field represents the severity of damage at each pixel location in image form; regions with higher response intensities indicate more significant damage.

[0096] Then, the adjacency relationships between each wall structural region are determined based on the structural semantic region map, and the adjacency propagation relationship of the structural regions is established in the damage morphology response field. Specifically, the structural semantic region map identifies the type of wall structural region to which each pixel position in the enhanced image belongs, including masonry regions, mortar joint regions, opening regions, etc. Traversing each structural region in the structural semantic region map, for any two structural regions, if there exists a pixel position such that the pixel belongs to one structural region and its adjacent pixel belongs to another structural region, then these two structural regions are considered to have an adjacency relationship. All pairs of structural regions with adjacency relationships are recorded to form a structural region adjacency relationship table. The adjacency propagation relationship of the structural regions is established in the damage morphology response field, indicating that damage can propagate from one structural region to another adjacent structural region. For two structural regions with an adjacency relationship, their adjacency boundary is determined. The adjacency boundary is the set of pixels at the intersection of the two structural regions, that is, the pixels in one structural region that are adjacent to pixels in the other structural region. Adjacent boundaries serve as channels for the propagation of damage between two structural regions. During subsequent propagation calculations, the potential energy of the damage is transferred from one region to another through the adjacent boundaries.

[0097] Next, the crack propagation direction weight is calculated based on the extension direction of the crack texture features, the spalling extension weight is calculated based on the boundary expansion direction of the spalling boundary features, and the chromaticity diffusion weight is calculated based on the gradient diffusion direction of the chromaticity degradation features. For the calculation of the crack propagation direction weight, the extension direction of each effective crack segment is recorded in the crack texture features. For a pixel located within the effective crack segment, the propagation direction weight from that pixel to its neighboring pixels is calculated based on the extension direction of that crack segment. Specifically, the angle θ between the direction from the current pixel to each neighboring pixel and the crack extension direction is calculated. The crack propagation direction weight is equal to the absolute value of the cosine of the angle θ, i.e., crack propagation direction weight = |cos(θ)|. When the propagation direction is parallel to the crack extension direction, the angle θ is 0° or 180°, the absolute value of the cosine is 1, and the crack propagation direction weight is the highest; when the propagation direction is perpendicular to the crack extension direction, the angle θ is 90°, the cosine is 0, and the crack propagation direction weight is the lowest. Through this method, the residual potential energy in the crack region is preferentially propagated along the crack extension direction. For calculating the peeling propagation weight, the peeling boundary features record the boundary contour curves of each irregular defect region. For pixels located near the boundary of an irregular defect region, the peeling propagation weight propagating from that pixel to its neighboring pixels is calculated based on the normal direction of the pixel's location on the boundary. Specifically, for a boundary pixel, the tangent direction of the boundary contour curve at that pixel's location is calculated based on the coordinates of that pixel and its neighboring boundary pixels on the boundary contour curve. The normal direction is perpendicular to the tangent direction and points outward from the region. The angle θ between the direction from the current pixel to each neighboring pixel and the normal direction is calculated. The peeling propagation weight is equal to the cosine of the angle θ, and is zero when the cosine is negative, i.e., peeling propagation weight = max(cos(θ), 0). When the propagation direction is parallel to the normal direction and points outward, the angle θ is 0°, and the peeling propagation weight is 1, the highest. When the propagation direction is perpendicular to the normal direction or points inward, the peeling propagation weight is 0. In this way, the residual potential energy of the peeling region preferentially propagates outward along the boundary normal direction. For the calculation of chroma diffusion weight, the chroma degradation features record the principal direction of the chroma gradient in each chroma degradation region and the chroma gradient direction of each pixel. For a pixel located within the chroma degradation region, the chroma diffusion weight propagating from that pixel to its neighboring pixels is calculated based on its chroma gradient direction. Specifically, the angle θ between the direction from the current pixel to each neighboring pixel and the chroma gradient direction of that pixel is calculated. The chroma diffusion weight is equal to the cosine of the angle θ, and is zero when the cosine is negative, i.e., chroma diffusion weight = max(cos(θ), 0). The chroma diffusion weight is highest when the propagation direction is parallel and in the same direction as the chroma gradient direction; the chroma diffusion weight is 0 when the propagation direction is perpendicular or opposite to the chroma gradient direction. In this way, the residual potential energy in the chroma degradation region is preferentially diffused and propagated along the chroma gradient direction.

[0098] Subsequently, under the constraint of adjacency propagation relationship, a directional weighted propagation calculation is performed on the damage morphology response field based on crack propagation direction weight, spalling expansion weight, and chromaticity diffusion weight to generate a damage propagation potential value distribution. A wall damage propagation feature map is then formed based on these potential values. Specifically, the damage propagation potential value distribution is initialized by using the damage morphology response intensity of each pixel position in the damage morphology response field as the initial damage propagation potential value. Then, the propagation calculation is iteratively executed. In each iteration, for pixel positions with a damage propagation potential value greater than zero, the corresponding directional propagation weight is selected based on the damage type corresponding to that pixel. If the pixel is located in a crack region, the crack propagation direction weight is used; if the pixel is located near the boundary of a spalling region, the spalling expansion weight is used; if the pixel is located in a chromaticity degradation region, the chromaticity diffusion weight is used; if the pixel is located in multiple damage regions simultaneously, the directional propagation weights are arithmetically averaged. If the pixel is not located in any original damage region but has already received a propagation potential value, it is propagated uniformly to all neighboring pixels, and the propagation direction weight corresponding to each neighboring pixel is set to 1. Then, the potential energy increment propagated from the current pixel to each neighboring pixel is calculated based on the directional propagation weight. The potential energy increment is equal to the residual propagation potential value of the current pixel multiplied by the corresponding directional propagation weight and then multiplied by a preset propagation attenuation coefficient, i.e., potential energy increment = residual propagation potential value × directional propagation weight × propagation attenuation coefficient. The propagation attenuation coefficient is used to control the degree of potential energy attenuation during propagation, and can be set to, for example, 0.1 to 0.3. For each neighboring pixel, if it receives potential energy increments from multiple pixels in this iteration, the potential energy increments are accumulated to obtain the total potential energy increment of the neighboring pixel in this iteration, and the total potential energy increment is added to the residual propagation potential value of the neighboring pixel. At the same time, the propagation calculation is constrained by the adjacency propagation relationship. When the propagation path is located within the same structural region, the propagation is not constrained and proceeds according to the above-described directional weighting method. When the propagation path crosses different structural regions, the system first determines whether the structural region where the current pixel is located is adjacent to the structural regions where its neighboring pixels are located based on the structural region adjacency table. If they are adjacent and the current pixel is on the adjacent boundary, propagation is allowed, and the potential energy increment is accumulated to the neighboring pixel. If they are not adjacent, propagation is not allowed, and the potential energy increment is not accumulated to the neighboring pixel. Adjacency propagation constraints ensure that the residual propagation path conforms to the actual topological relationship of the wall structure. The propagation calculation is performed iteratively until the termination condition is met. The termination condition is that the change in residual propagation potential value of all pixels in this iteration is less than a preset convergence threshold, or the number of iterations reaches a preset maximum number of iterations. The convergence threshold can be set to, for example, 0.001, and the maximum number of iterations can be set to, for example, 50 to 100. After the propagation calculation is completed, the residual propagation potential values ​​at each pixel location form a residual propagation potential value distribution.Based on the distribution of damage propagation potential values, a wall damage propagation feature map is formed. The wall damage propagation feature map represents the damage propagation potential value at each location at the pixel level. The higher the damage propagation potential value, the more likely that location is to become a path for the continued development of damage.

[0099] Through the above steps, a feature map of wall damage propagation was constructed, which can model the potential propagation trend of damage based on the morphological characteristics of the damage and the topological relationship of the wall structure, providing data support for subsequent identification of damage propagation paths and assessment of damage development direction.

[0100] Furthermore, the propagation path is identified using the wall damage propagation characteristic map, and the damage propagation intensity index is calculated, including:

[0101] S51. Identify pixel regions with continuously increasing propagation potential values ​​in the wall damage propagation feature map, and perform connected component analysis on the pixel regions to construct multiple candidate damage propagation regions;

[0102] S52. Perform path skeleton extraction processing on each candidate damage propagation area to generate a propagation path that characterizes the damage propagation trend;

[0103] S53. Calculate the corresponding residual propagation intensity index based on the extension length of the propagation path, the number of branches, and the stability of the path direction.

[0104] In a preferred embodiment, when calculating the damage propagation intensity index, firstly, pixel regions with continuously increasing propagation potential values ​​are identified in the wall damage propagation feature map, and connected component analysis is performed on these pixel regions to construct multiple candidate damage propagation regions. Specifically, the wall damage propagation feature map characterizes the damage propagation potential value at each location at the pixel level; regions with higher propagation potential values ​​indicate that the location is more likely to become a path for continued damage development. To identify pixel regions with continuously increasing propagation potential values ​​in the wall damage propagation feature map, a propagation potential value threshold is first set. Pixels with propagation potential values ​​greater than this threshold are marked as high-potential-value pixels. The propagation potential value threshold is set according to the distribution characteristics of propagation potential values ​​in the wall damage propagation feature map to filter out pixel regions with propagation potential values ​​significantly higher than the background; for example, it can be set to 10% to 20% of the maximum propagation potential value. Then, a continuity judgment is performed on the high-potential-value pixels. For any high-potential-value pixel, it is checked whether the propagation potential values ​​of its adjacent high-potential-value pixels show a continuously increasing or stable trend, i.e., the propagation potential values ​​of adjacent pixels are not lower than a preset proportion of the current pixel's propagation potential value. Adjacent high-potential pixels that satisfy the continuity condition are marked as pixels whose propagation potential continuously increases.

[0105] Then, connected component analysis is performed on pixel regions with continuously increasing propagation potential to construct multiple candidate residual propagation regions. Specifically, starting from any pixel with continuously increasing propagation potential as the starting pixel, it is checked whether its spatially adjacent pixels also belong to the continuously increasing propagation potential pixel category. If they do, the adjacent pixels are included in the same connected component. Based on the newly included pixels, the adjacent pixels are checked again, and this process is iterated until no new pixels that meet the conditions can be included, forming a connected component. The above process is repeated for the remaining unaggregated pixels with continuously increasing propagation potential until all pixels with continuously increasing propagation potential have been processed, forming multiple connected components. Each connected component is a candidate residual propagation region, and each candidate residual propagation region represents a potential residual propagation range.

[0106] Then, path skeleton extraction is performed on each candidate damaged propagation region to generate a propagation path representing the propagation trend of the damage. Specifically, the path skeleton is the central axis structure of the candidate damaged propagation region, which can represent the main extension direction and morphological features of the region in a linear form. Path skeleton extraction is performed on each candidate damaged propagation region, using a layer-by-layer peeling method to extract the skeleton structure of the region. First, the boundary pixels of the candidate damaged propagation region are identified. Boundary pixels are pixels within the region whose adjacent pixels do not belong to that region. Then, it is determined whether each boundary pixel is a peelable pixel. The criteria for a peelable pixel are: peeling the pixel will not cause a break in the connectivity of the region, and the pixel is not an endpoint pixel of the region. An endpoint pixel is a pixel whose only adjacent pixel belongs to the region. Boundary pixels that meet the peelable criteria are removed from the region, and the set of boundary pixels of the region is updated. The above peeling process is performed iteratively, peeling one layer of peelable boundary pixels in each iteration, until there are no more peelable boundary pixels in the region. The remaining pixels after peeling are the path skeleton of the candidate damaged propagation region, and the path skeleton is used as the propagation path representing the damage propagation trend.

[0107] Subsequently, the corresponding residual propagation intensity index is calculated based on the propagation path's extension length, number of branches, and path direction stability. For calculating the propagation path's extension length, the number of pixels contained in the propagation path is counted, and this number is used as the propagation path's extension length. If the propagation path has a branching structure, the number of pixels in all branches is summed to obtain the total extension length of the propagation path. The extension length reflects the spatial span of residual propagation; a longer extension length indicates a larger spatial range of residual propagation. For calculating the number of branches in the propagation path, branch nodes are identified in the propagation path. A branch node is a pixel on the propagation path that has three or more adjacent path pixels, meaning that the pixel connects to three or more path branches. The number of branch nodes in the propagation path is counted, and the number of branch nodes plus 1 is the number of branches in the propagation path. The number of branches reflects the degree of residual propagation diffusion; a higher number of branches indicates a more pronounced trend of residual propagation in multiple directions simultaneously. For calculating the path direction stability of the propagation path, for each pixel on the propagation path, the local orientation angle of that pixel is calculated. The local orientation angle is obtained by calculating the coordinate difference between that pixel and its adjacent path pixels. The average local directional angle of all pixels along the propagation path is calculated as the principal directional angle. The difference between each local directional angle and the principal directional angle is calculated, and the sum of the squares of each difference is divided by the number of pixels to obtain the directional angle variance. Path directional stability is equal to 1 minus the directional angle variance divided by a preset variance normalization benchmark value, i.e., path directional stability = 1 - directional angle variance / variance normalization benchmark value. The variance normalization benchmark value is set according to the typical range of the propagation path directional angle variance to ensure that the path directional stability value is distributed between 0 and 1. The closer the path directional stability value is to 1, the higher the consistency of the propagation path along the principal direction, and the more obvious the trend of continuous damage development along a single direction; the closer the value is to 0, the more drastic the change in the propagation path direction, and the less stable the damage development direction.

[0108] Subsequently, the damage propagation intensity index is calculated comprehensively based on the extension length, number of branches, and path direction stability of the propagation path. Specifically, the extension length is divided by a preset extension length normalization benchmark to obtain the normalized extension length, which is set according to the typical range of extension length values ​​for the propagation path in the wall image. The number of branches is divided by a preset branch number normalization benchmark to obtain the normalized branch number, which is set according to the typical range of branch number values ​​for the propagation path. The damage propagation intensity index is equal to the weighted sum of the normalized extension length, normalized branch number, and path direction stability. The weight of each index is set according to its importance to the damage development trend, and the sum of the weights is 1. The higher the damage propagation intensity index, the stronger the development and evolution trend of the damage corresponding to the propagation path.

[0109] Through the above steps, the identification of damage propagation paths and the calculation of damage propagation intensity indicators are realized. It is possible to extract spatially continuous propagation paths from the wall damage propagation feature map and quantify the development trend intensity of the propagation paths, providing data support for the subsequent generation of wall damage detection results.

[0110] Furthermore, wall damage detection results are generated using damage propagation intensity indices and structural semantic region maps, including:

[0111] S54. Map the damage propagation intensity index to the corresponding wall structure area in the structural semantic region diagram.

[0112] S55. Determine the degree of regional damage in the structural region based on the mapping results;

[0113] S56. Generate wall damage detection results using the degree of damage in the area.

[0114] In a preferred embodiment, when generating wall damage detection results, firstly, the damage propagation intensity index is mapped to the corresponding wall structure region in the structural semantic region map. Specifically, each propagation path has a corresponding damage propagation intensity index, and each propagation path has a clear spatial location in the enhanced image. The structural semantic region map identifies the type of wall structure region to which each pixel position in the enhanced image belongs. For each propagation path, the pixel positions contained in the propagation path are traversed, and the wall structure region to which each pixel position belongs is queried according to the structural semantic region map. The damage propagation intensity index of the propagation path is then mapped to the corresponding wall structure region. If a propagation path crosses multiple wall structure regions, the damage propagation intensity index of the propagation path is mapped to each wall structure region it crosses, and the distribution is based on the proportion of pixels in each structural region. That is, the damage propagation intensity index obtained by a structural region is equal to the damage propagation intensity index of the propagation path multiplied by the number of pixels of the propagation path in that structural region divided by the total number of pixels of the propagation path.

[0115] Then, the degree of damage to the structural area is determined based on the mapping results. Specifically, for each wall structural area, all damage propagation intensity indicators mapped to that area are statistically analyzed. If a structural area is traversed by multiple propagation paths, it will receive multiple damage propagation intensity indicators. All damage propagation intensity indicators mapped to the structural area are summed to obtain the cumulative damage propagation intensity for that area. Simultaneously, the area of ​​the structural area is calculated, represented by the number of pixels it contains. The cumulative damage propagation intensity is divided by the area of ​​the structural area to obtain the damage propagation intensity per unit area, which is used as the degree of damage to that structural area. The degree of damage reflects the severity and development trend of damage to the wall structural area; a higher degree of damage indicates more severe damage and a greater likelihood of continued damage.

[0116] Subsequently, wall damage detection results are generated based on the degree of damage in each area. Specifically, the structural areas are classified into damage levels according to the degree of damage in each structural area. Multiple damage level thresholds are set to classify the degree of damage in each area into different levels, such as slight damage, moderate damage, and severe damage. Structural areas with a degree of damage below the first threshold are classified as slightly damaged, structural areas with a degree of damage between the first and second thresholds are classified as moderately damaged, and structural areas with a degree of damage above the second threshold are classified as severely damaged. The damage level thresholds are set based on the actual needs of wall damage detection and historical data statistics. The spatial location, structural area type, degree of damage, damage level, and propagation path information of each structural area are integrated to generate the wall damage detection results. The wall damage detection results include assessment information on the degree of damage in each structural area of ​​the wall and information on the path of damage propagation. They can reflect the current state and potential evolution trend of wall damage, and provide a basis for decision-making on the protection, repair and safety assessment of the walls of historical buildings.

[0117] Through the above steps, the damage propagation intensity index is combined with the structural area of ​​the wall to generate wall damage detection results with structural semantic information. This can clarify the degree of damage and the trend of damage development in each structural area, providing a basis for targeted repair of historical building walls.

[0118] Furthermore, a visual damage indicator is configured based on the wall damage detection results, and the visual damage indicator is used for early warning and alert processing.

[0119] In one feasible implementation, the wall damage detection results include the spatial location, degree of damage, damage level, and propagation path information of each wall structural area. Based on the wall damage detection results, visual damage markers are configured for each wall structural area, which are used to visually present the damage status of each structural area in the image.

[0120] When configuring visual damage markers, corresponding marker colors are assigned based on the damage level of each wall structure area. Different damage levels are distinguished by different colors; for example, lightly damaged areas are marked in yellow, moderately damaged areas in orange, and severely damaged areas in red. The marker colors are overlaid as a semi-transparent overlay onto the corresponding wall structure areas in the enhanced image, allowing inspectors to visually identify the damage level of each area. Simultaneously, the propagation path is drawn as a linear marker on the enhanced image. The line width or color depth of the propagation path can be set according to the corresponding damage propagation intensity index; the higher the damage propagation intensity index, the thicker the line width or the darker the color, to visually present the propagation trend and direction of the damage.

[0121] Next, visual damage indicators are used for early warning issuance. Specifically, early warning judgments are made based on the damage level of each structural area in the wall damage inspection results. If a structural area with severe damage exists, a high-level early warning message is generated; if a structural area with moderate damage exists but no severely damaged areas exist, a medium-level early warning message is generated; if only slightly damaged areas exist, a low-level early warning message is generated. The early warning message includes the early warning level, the location of the damaged area, the numerical value of the damage degree, the damage level, and recommended measures. The early warning message, along with the image configured with visual damage indicators, is output for inspection personnel or relevant management systems to review and process.

[0122] The above methods enable the visualization and early warning of wall damage detection results, allowing inspectors to intuitively understand the damage status and development trend of each area of ​​the wall, and to take corresponding protection and repair measures in a timely manner according to the warning level, thus providing support for the safety management of historical building walls.

[0123] Example 2, as Figure 2 As shown, based on the same inventive concept as the image-vision-based method for detecting damage to the interior walls of historical buildings provided in Embodiment 1, this embodiment of the invention also provides an image-vision-based system for detecting damage to the interior walls of historical buildings, including:

[0124] Image enhancement module 11 is used to perform illumination equalization and texture enhancement processing on the original image after acquiring the original image of the interior wall of the historical building, and to create an enhanced image;

[0125] The structural semantic partitioning module 12 is used to identify the structural boundary lines and material texture distribution features of the wall in the enhanced image, and to perform structural semantic partitioning processing to generate a structural semantic region map.

[0126] The damaged morphology extraction module 13 is used to perform damaged morphology extraction processing of enhanced images in each wall structure region using structural semantic region map, identify crack texture, peeling boundary and color degradation area on the wall surface, and construct a set of wall damaged morphology features based on the direction continuity of crack texture, the shape contour of peeling boundary and the gradient change of color degradation area.

[0127] The propagation feature construction module 14 is used to generate a damage morphology response field based on the structural semantic region map and the wall damage morphology feature set, and to calculate the damage propagation potential value by combining the adjacency relationship between structural semantic regions and the direction consistency of crack texture, the neighborhood expansion trend of the peeling boundary and the gradient diffusion direction of the color degradation region, so as to form a wall damage propagation feature map.

[0128] The damage detection output module 15 is used to identify the propagation path using the wall damage propagation feature map, calculate the damage propagation intensity index, and generate the wall damage detection result using the damage propagation intensity index and the structural semantic region map.

[0129] Furthermore, the damaged morphology extraction module 13 is also used for:

[0130] Based on the structural semantic region map, the pixel set of each wall structure region in the enhanced image is determined, and the pixel set is used as the damage detection region;

[0131] In the defect detection area, directional gradient calculation is performed on the enhanced image to identify pixel sequences with linear continuity features, and crack texture features are extracted based on the directional consistency and spatial connectivity of the pixel sequences.

[0132] Edge detection and region segmentation are performed on the enhanced image within the defect detection area to identify irregular defect areas on the wall surface, and the peeling boundary features are extracted based on the contour curvature of the irregular defect area boundary.

[0133] Chromaticity component gradient analysis is performed on the enhanced image within the damaged detection area to identify pixel regions with continuous chromaticity decay characteristics, and chromaticity degradation features are extracted based on the spatial distribution of the chromaticity gradient.

[0134] A set of wall damage morphology features is constructed based on crack texture characteristics, peeling boundary characteristics, and color degradation characteristics.

[0135] Furthermore, the damaged morphology extraction module 13 is also used for:

[0136] A pixel orientation distribution map is established based on the orientation gradient calculation results, and multiple candidate crack pixel sets are generated by performing orientation clustering on pixels with similar orientation gradients.

[0137] Connectivity analysis is performed on each candidate crack pixel set to form crack connected segments, and effective crack segments are selected based on the extension length and directional stability of the crack connected segments.

[0138] The crack direction consistency index is calculated based on the angle between the extension direction of the effective crack segment and the texture direction of the adjacent wall masonry. Crack texture features are then generated based on the crack direction consistency index.

[0139] Furthermore, the damaged morphology extraction module 13 is also used for:

[0140] Perform region growing processing on the edge pixels in the defect detection area to form irregular defect areas;

[0141] Extract the boundary contour curve of the irregular defect region and calculate the curvature change sequence of the boundary contour curve;

[0142] Identify boundary inflection points with abrupt curvature features based on the curvature change sequence, and calculate the boundary irregularity of the defect region based on the spatial distribution of the boundary inflection points.

[0143] The peeling boundary features are generated based on the boundary irregularity and the area of ​​the irregular defect region.

[0144] Furthermore, the damaged morphology extraction module 13 is also used for:

[0145] The enhanced image is converted to chroma component space, and the chroma channel images are extracted;

[0146] Local gradient calculation is performed on the chroma channel image within the defect detection area to generate a chroma gradient distribution map;

[0147] Identify continuous chromaticity attenuation regions based on the chromaticity gradient distribution map, and determine the range of chromaticity degradation regions by region expansion;

[0148] Chromaticity degradation features are generated based on the magnitude of chromaticity gradient change and spatial diffusion range within the chromaticity degradation region.

[0149] Furthermore, the propagation feature building module 14 is also used for:

[0150] A damage morphology response field is formed based on the spatial distribution of the wall damage morphology feature set in the enhanced image. The damage morphology response field is used to characterize the damage morphology response intensity at each pixel location.

[0151] The adjacency relationship between each wall structure region is determined based on the structural semantic region map, and the adjacency propagation relationship of the structural region is established in the damaged morphology response field;

[0152] The crack propagation direction weight is calculated based on the extension direction of the crack texture features, the spalling extension weight is calculated based on the boundary extension direction of the spalling boundary features, and the chromaticity diffusion weight is calculated based on the gradient diffusion direction of the chromaticity degradation characteristics.

[0153] Under the constraint of adjacency propagation relationship, the directional weighted propagation calculation of the damage morphology response field is performed based on the crack propagation direction weight, the peeling propagation weight, and the chromaticity diffusion weight to generate the damage propagation potential value distribution, and a wall damage propagation feature map is formed based on the damage propagation potential value.

[0154] Furthermore, the damage detection output module 15 is also used for:

[0155] In the wall damage propagation feature map, pixel regions with continuously increasing propagation potential are identified, and connected component analysis is performed on the pixel regions to construct multiple candidate damage propagation regions;

[0156] Path skeleton extraction is performed on each candidate damage propagation region to generate a propagation path that characterizes the damage propagation trend;

[0157] The residual propagation intensity index is calculated based on the extension length of the propagation path, the number of branches, and the stability of the path direction.

[0158] Furthermore, the damage detection output module 15 is also used for:

[0159] Map the damage propagation intensity index to the corresponding wall structure region in the structural semantic region diagram;

[0160] The degree of damage to the structural region is determined based on the mapping results;

[0161] The wall damage detection results are generated based on the degree of damage in the area.

[0162] Furthermore, a visual damage indicator is configured based on the wall damage detection results, and the visual damage indicator is used for early warning and alert processing.

[0163] Although preferred embodiments of the invention have been described, those skilled in the art, once they have learned the basic inventive concept, can make other changes and modifications to these embodiments.

[0164] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of this invention and its equivalents, this invention also intends to include these modifications and variations.

Claims

1. A method for detecting damage to the interior walls of historical buildings based on image vision, characterized in that, include: After acquiring the original image of the interior walls of the historical building, the original image is subjected to illumination equalization and texture enhancement processing to create an enhanced image; The structural boundary lines and material texture distribution features of the wall are identified in the enhanced image, and structural semantic partitioning is performed to generate a structural semantic region map; Using structural semantic region maps, we perform enhanced image morphology extraction processing in each wall structure region to identify crack textures, peeling boundaries, and color degradation areas on the wall surface. Based on the continuity of crack texture direction, the morphological contour of peeling boundaries, and the gradient changes of color degradation areas, we construct a set of wall morphology features. Based on the structural semantic region map and the set of wall damage morphology features, a damage morphology response field is generated. The damage propagation potential value is calculated by combining the adjacency relationship between structural semantic regions, the directional consistency of crack texture, the neighborhood expansion trend of the peeling boundary, and the gradient diffusion direction of the color degradation region, thus forming a wall damage propagation feature map. The propagation path is identified using the wall damage propagation feature map, the damage propagation intensity index is calculated, and the wall damage detection results are generated using the damage propagation intensity index and the structural semantic region map.

2. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 1, characterized in that, Using structural semantic region maps, enhanced image morphology extraction processing is performed in each wall structure region, including: Based on the structural semantic region map, the pixel set of each wall structure region in the enhanced image is determined, and the pixel set is used as the damage detection region; In the defect detection area, directional gradient calculation is performed on the enhanced image to identify pixel sequences with linear continuity features, and crack texture features are extracted based on the directional consistency and spatial connectivity of the pixel sequences. Edge detection and region segmentation are performed on the enhanced image within the defect detection area to identify irregular defect areas on the wall surface, and the peeling boundary features are extracted based on the contour curvature of the irregular defect area boundary. Chromaticity component gradient analysis is performed on the enhanced image within the damaged detection area to identify pixel regions with continuous chromaticity decay characteristics, and chromaticity degradation features are extracted based on the spatial distribution of the chromaticity gradient. A set of wall damage morphology features is constructed based on crack texture characteristics, peeling boundary characteristics, and color degradation characteristics.

3. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 2, characterized in that, Extract crack texture features, including: A pixel orientation distribution map is established based on the orientation gradient calculation results, and multiple candidate crack pixel sets are generated by performing orientation clustering on pixels with similar orientation gradients. Connectivity analysis is performed on each candidate crack pixel set to form crack connected segments, and effective crack segments are selected based on the extension length and directional stability of the crack connected segments. The crack direction consistency index is calculated based on the angle between the extension direction of the effective crack segment and the texture direction of the adjacent wall masonry. Crack texture features are then generated based on the crack direction consistency index.

4. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 2, characterized in that, Extracting the features of the peeling boundary, including: Perform region growing processing on the edge pixels in the defect detection area to form irregular defect areas; Extract the boundary contour curve of the irregular defect region and calculate the curvature change sequence of the boundary contour curve; Identify boundary inflection points with abrupt curvature features based on the curvature change sequence, and calculate the boundary irregularity of the defect region based on the spatial distribution of the boundary inflection points. The peeling boundary features are generated based on the boundary irregularity and the area of ​​the irregular defect region.

5. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 2, characterized in that, Extracting chromaticity degradation features, including: The enhanced image is converted to chroma component space, and the chroma channel images are extracted; Local gradient calculation is performed on the chroma channel image within the defect detection area to generate a chroma gradient distribution map; Identify continuous chromaticity attenuation regions based on the chromaticity gradient distribution map, and determine the range of chromaticity degradation regions by region expansion; Chromaticity degradation features are generated based on the magnitude of chromaticity gradient change and spatial diffusion range within the chromaticity degradation region.

6. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 1, characterized in that, A characteristic map of the propagation of wall damage is generated, including: A damage morphology response field is formed based on the spatial distribution of the wall damage morphology feature set in the enhanced image. The damage morphology response field is used to characterize the damage morphology response intensity at each pixel location. The adjacency relationship between each wall structure region is determined based on the structural semantic region map, and the adjacency propagation relationship of the structural region is established in the damaged morphology response field; The crack propagation direction weight is calculated based on the extension direction of the crack texture features, the spalling extension weight is calculated based on the boundary extension direction of the spalling boundary features, and the chromaticity diffusion weight is calculated based on the gradient diffusion direction of the chromaticity degradation characteristics. Under the constraint of adjacency propagation relationship, the directional weighted propagation calculation of the damage morphology response field is performed based on the crack propagation direction weight, the peeling propagation weight, and the chromaticity diffusion weight to generate the damage propagation potential value distribution, and a wall damage propagation feature map is formed based on the damage propagation potential value.

7. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 1, characterized in that, The propagation path is identified using the wall damage propagation characteristic map, and the damage propagation intensity index is calculated, including: In the wall damage propagation feature map, pixel regions with continuously increasing propagation potential are identified, and connected component analysis is performed on the pixel regions to construct multiple candidate damage propagation regions; Path skeleton extraction is performed on each candidate damage propagation region to generate a propagation path that characterizes the damage propagation trend; The residual propagation intensity index is calculated based on the extension length of the propagation path, the number of branches, and the stability of the path direction.

8. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 7, characterized in that, The wall damage detection results are generated using damage propagation intensity indices and structural semantic region maps, including: Map the damage propagation intensity index to the corresponding wall structure region in the structural semantic region diagram; The degree of damage to the structural region is determined based on the mapping results; The wall damage detection results are generated based on the degree of damage in the area.

9. The method for detecting damage to the interior walls of historical buildings based on image vision as described in claim 1, characterized in that, Based on the wall damage detection results, a visual damage indicator is configured, and the visual damage indicator is used for early warning and alert processing.

10. A system for detecting damage to the interior walls of historical buildings based on image vision, characterized in that, A method for implementing the image-based vision-based method for detecting damage to the interior walls of historical buildings as described in any one of claims 1 to 9, comprising: The image enhancement module is used to perform illumination equalization and texture enhancement processing on the original image after acquiring the original image of the interior wall of the historical building, and to create an enhanced image. The structural semantic partitioning module is used to identify the structural boundary lines and material texture distribution features of the wall in the enhanced image, and to perform structural semantic partitioning processing to generate a structural semantic region map. The damage morphology extraction module is used to perform damage morphology extraction processing of enhanced images in each wall structure region using structural semantic region map, identify crack texture, peeling boundary and color degradation area on the wall surface, and construct a set of wall damage morphology features based on the continuity of crack texture, the shape contour of peeling boundary and the gradient change of color degradation area. The propagation feature construction module is used to generate a damage morphology response field based on the structural semantic region map and the wall damage morphology feature set, and to calculate the damage propagation potential value by combining the adjacency relationship between structural semantic regions, the directional consistency of crack texture, the neighborhood expansion trend of the peeling boundary, and the gradient diffusion direction of the color degradation region, thus forming a wall damage propagation feature map. The damage detection output module is used to identify the propagation path using the wall damage propagation feature map, calculate the damage propagation intensity index, and generate the wall damage detection results using the damage propagation intensity index and the structural semantic region map.