Method for reasoning and rebuilding original appearance of damaged decorative components of ancient buildings
By integrating 3D laser scanning and multispectral imaging technologies, multi-source data features of decorative components of damaged ancient buildings are extracted. Combined with morphological rule library and historical style constraints, high-precision geometric, decorative and color reconstruction of damaged components is achieved, solving the problem of incomplete reconstruction in existing technologies and ensuring the accuracy of reconstruction results and the continuity of cultural connotation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- INNER MONGOLIA UNIV OF TECH
- Filing Date
- 2026-01-12
- Publication Date
- 2026-07-31
AI Technical Summary
Existing technologies struggle to fully capture geometric details, material properties, and color traces in the reconstruction of the original appearance of decorative components of damaged ancient buildings. They also lack adaptability to complex, incomplete, or irregular patterns, failing to achieve a unified restoration of the original appearance in terms of form, pattern, and color.
By integrating 3D laser scanning and multispectral imaging to acquire multi-source sensing data, features of damaged edges, decorative fragments and color traces are extracted. Combined with morphological rule library and historical style constraints, geometric continuity deduction, pattern bone method analysis and multi-source color fusion are used to generate an integrated 3D model.
It achieves high-precision collaborative reconstruction of the geometry, patterns, and colors of damaged components, ensuring that the reconstruction results are highly consistent with the original components, taking into account both accuracy and the continuity of cultural connotations, and supporting visual identification and traceability of the repair process.
Smart Images

Figure CN121746887B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of original appearance reasoning and reconstruction technology of building components, specifically to a system and method for original appearance reasoning and reconstruction of decorative components of damaged ancient buildings. Background Technology
[0002] Ancient buildings, as important carriers of historical and cultural heritage, often bear unique artistic styles and craft information in their decorative components (such as carvings, brackets, and column heads). However, due to factors such as natural weathering and human damage, a large number of decorative components are damaged or missing, making it difficult to identify their original appearance, patterns, and color information. Traditional restoration work relies heavily on expert experience and manual operation, which has problems such as low efficiency, strong subjectivity, and lack of scientific basis. With the development of three-dimensional digital technology, some progress has been made in the geometric reconstruction of components based on point cloud and image data. However, in terms of inferring the original appearance of damaged components, especially the intelligent restoration of deep features such as irregular patterns and colors, there is still a lack of systematic technical solutions.
[0003] In the existing technology, a method and system for inferring and reconstructing the original appearance of decorative components of damaged historical buildings, disclosed in CN118261825A, mainly constructs a database of decorative symbols, matches similar decorative symbols based on connection state attributes, and performs point cloud registration and surface reconstruction. While this method achieves inference and restoration of specific decorative types to a certain extent, it still has the following limitations: First, this method mainly relies on two-dimensional image fitting and symbol matching, failing to fully integrate multi-source data such as three-dimensional geometry and multispectral data, making it difficult to comprehensively capture the geometric details, material properties, and color traces of the component surface; second, its decorative matching mechanism is limited to a predefined symbol library and connection attributes, lacking adaptability to complex, incomplete, or irregular decorative patterns, and failing to consider the structural confidence and historical style consistency of decorative units; third, it does not involve the inference and fusion of color information, lacking a systematic reconstruction method for the original color distribution of components, making it difficult to achieve integrated restoration of shape, pattern, and color. Therefore, there is an urgent need for a method that can integrate multi-source data and achieve geometric restoration. Ornament The intelligent reconstruction system based on color collaborative reasoning can more scientifically and completely restore the original appearance of the decorative components of damaged ancient buildings.
[0004] The information disclosed in the background section is only intended to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0005] The purpose of this invention is to provide a system and method for reconstructing the original appearance of decorative components of damaged ancient buildings, so as to solve the problems mentioned in the background art.
[0006] To achieve the above objectives, this invention provides a system for reconstructing the original appearance of decorative components of damaged ancient buildings, specifically comprising: The feature extraction module is used to acquire multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. It performs fusion processing on the multi-source current status perception data to generate a fused 3D model, and extracts the damage edge features, ornamentation fragment features and color trace features from it. The contour reasoning module is used to infer and generate the complete three-dimensional contour of the missing part of the damaged component based on the features of the damaged edge, combined with the preset morphological structure rule base and reference geometric data, through geometric continuity deduction and rule matching. The ornamentation reasoning module is used to generate a candidate matching unit set by matching the smallest repeatable ornamentation unit with the ornamentation fragment features and reference ornamentation data through pattern bone analysis, and to calculate the ornamentation structure confidence of each candidate matching unit. The candidate matching unit with the highest ornamentation structure confidence is selected as the benchmark to infer and generate the complete surface ornamentation of the missing part. The color reasoning module is used to determine at least two candidate color sources based on color trace features, combined with historical color database, reference geometric data and reference pattern data, calculate the color source weight for each candidate color source, fuse the candidate color sources and their weights, and infer to generate the original color distribution. The fusion module is used to input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. It then performs geometric alignment and seamless fusion with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified.
[0007] Furthermore, the multi-source current status perception data refers to three-dimensional point cloud data that characterizes the current geometric shape of the damaged component, obtained through three-dimensional laser scanning, and multispectral feature image data that records the physicochemical properties of the surface of the damaged component, obtained through multispectral imaging equipment. The related components of the damaged component refer to other components that are directly related to the damaged component in terms of form, decorative style, construction period or structural function and have reference value, including other similar components belonging to the same building, components in symmetrical positions or components of the same known craftsmanship system; The reference geometric data refers to data obtained from the associated components of the damaged component that contains its complete or partial three-dimensional geometric shape; the reference decorative data refers to data obtained from the associated components of the damaged component and the damaged component archive that characterizes its surface decorative pattern style, structure and color information. The multi-source current situation perception data is fused to generate a fused 3D model. Specifically, the 3D point cloud data and multispectral feature image data are pixel-point cloud registered based on a common coordinate system, so that each 3D point is associated with the corresponding multispectral attribute vector, and a fused 3D model is generated. Extracting broken edge features from the fused 3D model specifically involves: based on the local curvature changes and normal abrupt changes of the 3D points in the fused 3D model, identifying and tracing the boundary lines constituting the broken fracture surface, forming a set of broken edge feature lines representing geometric discontinuities, which serve as broken edge features; Extracting decorative fragment features specifically involves: performing image segmentation on the surface texture image of the fused 3D model to obtain several closed regions; based on the color consistency measure and gradient direction consistency measure of the pixels in each closed region, regions whose color consistency measure is higher than a first preset threshold and whose gradient direction consistency measure is higher than a second preset threshold are selected as decorative fragment features. The extraction of color trace features specifically involves: analyzing the multispectral attribute vectors associated with each 3D point in the fused 3D model. These multispectral attribute vectors, after registration, are vectors composed of pixel values from multispectral feature images across multiple preset bands, corresponding to the spatial location of each 3D point. Principal component analysis is used to reduce the dimensionality of these multispectral attribute vectors. Then, a clustering algorithm is used to group the pixels in the reduced feature space, resulting in several pixel clusters. The mean spectral feature vector of each pixel cluster is calculated and compared with a preset benchmark vector of spectral features from a typical weathered and polluted area. The Euclidean distance between the two is calculated. If the Euclidean distance is greater than a set discrimination threshold, the pixel cluster is determined to be a potential original color or material residue, and its corresponding color and material information is extracted as color trace features.
[0008] Furthermore, each boundary line in the set of damaged edge feature lines is traversed and discretized into an ordered sequence of points. For each boundary line, at its endpoint, the tangent vector of that point is calculated using the difference method based on the coordinates of adjacent points, thereby determining its tangent direction. At the same time, the curvature value at the endpoint is obtained by calculating the locally fitted arc of the sequence of points near the endpoint. Establishing a topological connection between adjacent boundary lines involves setting a distance threshold. If the spatial Euclidean distance between the endpoints of two different boundary lines is less than the distance threshold, then the two endpoints are determined to be connected points, and the connection is recorded. The endpoint tangent directions, endpoint curvatures, and all identified endpoint connection relationships of all boundary lines are integrated to form the continuity constraint parameter set. The set of continuity constraint parameters is input into the morphological composition rule base for matching. The morphological composition rule base contains several morphological generation rules derived from historical intact components. Each rule defines a possible surface or block shape under given boundary conditions. Based on the degree of matching, at least one candidate morphological rule that meets the conditions is selected, and one or more preliminary morphological hypotheses are generated based on each candidate morphological rule and the set of continuity constraint parameters. The characteristic geometric elements in the reference geometric data are obtained. The characteristic geometric elements refer to specific geometric structures that are predefined according to the architectural style and form knowledge base to which the component belongs, or automatically identified through curvature analysis, including specific relief protrusions, groove cross sections, arch curves, bracket body outlines, and column head volute curves.
[0009] Furthermore, after spatially aligning each preliminary morphological hypothesis with the characteristic geometric elements in the reference geometric data, geometric similarity is calculated. Specifically, this involves extracting the specific cross-sectional contour lines of each preliminary morphological hypothesis and the contour lines of the characteristic geometric elements, sampling each contour line with equal arc lengths to obtain an ordered set of feature points, and converting the coordinates of each feature point set into a complex sequence. in, It is a complex sequence; ) is the first The coordinates of each sampling point The index of the sampling point; This represents the total number of sampling points for the contour line. For complex sequences Performing a Discrete Fourier Transform yields the Fourier descriptor, based on the following formula: in, Indicates the first Fourier descriptors corresponding to each frequency component Frequency index; The imaginary unit; The Fourier descriptor is normalized to obtain the shape feature vector: in, Represents the shape feature vector; The number of low-frequency components selected, and satisfying the following conditions: ; Calculate the Euclidean distance between the shape feature vector of each preliminary morphological hypothesis and the shape feature vector of the characteristic geometric element, and determine the negative value of the Euclidean distance as the geometric similarity. Select the preliminary morphological hypothesis with the highest geometric similarity as the optimization benchmark. The selected optimization benchmark is optimized using a surface optimization method based on energy minimization. Under the premise of satisfying the continuity constraint parameter set, its boundary is made to match the existing partial boundary in the fused 3D model. Continuity means that the position and normal vector at the boundary are continuous. At the same time, the interior of the surface is smoothed, and finally a complete three-dimensional contour model of the missing part of the damaged component is output, which is geometrically compatible with the existing part.
[0010] Furthermore, based on the features of the decorative fragments extracted from the fused 3D model, bone-like features that can characterize its overall direction and shape are extracted, specifically represented as one or more center lines obtained after skeletonization processing; at the same time, the minimum repeatable decorative unit library of decorative units extracted from the reference decorative data is analyzed and established; the minimum repeatable decorative unit refers to the smallest complete pattern unit in the reference decorative pattern that can fill a continuous area without overlap through symmetrical transformations such as translation, rotation or mirroring. Then, the bone structure features of the ornamentation fragments are matched with the bone structure features of each unit in the minimum repeatable ornamentation unit library. The matching process is achieved by calculating the regular distance between two centerline sequences. The smaller the distance value, the more the two curves match in shape and trend. This generates a candidate matching unit set containing several matching units and their corresponding regular distance values. For each candidate matching unit in the candidate matching unit set, the confidence score of the decorative structure is calculated using the following formula: In the formula, Confidence level of decorative structure; Indicates the degree of difference in historical styles; Indicates a regular distance; and The preset weights for the corresponding indicators, And satisfy ; The determination method is as follows: Query the historical color database or architectural style knowledge base, compare the known historical period and regional style of the candidate matching unit with the known construction period and region of the target damaged component. If both the period and region match perfectly, then... If only one of the periods or regions matches, then If none of them match, then ; The candidate matching unit with the highest confidence in the pattern structure is selected as the benchmark. Using the complete pattern information of the unit and the spatial range defined by the broken edge features, the complete surface pattern covering the entire missing area is generated by inferring through pattern extension and boundary fusion algorithms.
[0011] Furthermore, based on the color trace features extracted from the fused 3D model, the original color information and distribution pattern remaining on the surface of the damaged component are obtained; at the same time, by comprehensively querying the historical color database and the color information parsed from the reference geometric data and reference pattern data, at least two candidate color sources are determined; the candidate color sources include: measured color data extracted from the surface of intact related components of the same building at the same time, historical color spectrum data summarized from historical drawings, document records or similar buildings of the same period, and the dominant color system analyzed and inferred from the residual color traces of the component itself; For each candidate color source, calculate its corresponding color source weight: in, Indicates the first The weights of each candidate color source; , and Representing the first The spatiotemporal correlation score, information reliability score, and style coherence score of each candidate color source. , , The preset weighting coefficients are used, and they satisfy the following conditions: ; The candidate color sources and their weights are then merged: in, The total number of candidate color sources. This represents the coordinates of the j-th color source on the model surface. The color attribute vector provided at that location Indicates in Color attributes after fusion; The original color distribution is generated by calculating the coordinates of all missing regions.
[0012] Furthermore, the complete 3D contour, complete surface texture, and original color distribution are used as reconstruction parameters and input into a pre-trained 3D modeling system to obtain a 3D reconstruction model of the missing parts. The training process of the 3D modeling system is as follows: First, a large number of high-precision 3D models of decorative components of well-preserved ancient buildings and their corresponding geometric, decorative, and color data are collected to construct a training sample set. Then, based on a deep learning architecture, a model capable of inferring and generating a complete 3D structure from multi-parameter inputs is designed. During training, the system learns to reconstruct the mapping relationship of complete components from incomplete geometric contours, local decorative fragments, and color traces. The network parameters are optimized by minimizing the geometric error, texture difference, and color distribution distance between the generated model and the real complete model. Finally, after multiple rounds of iterative training and verification, the system has the ability to automatically generate 3D models that conform to historical style and structural logic based on the input inference and reconstruction parameters. The generated 3D reconstruction model of the missing part is geometrically aligned with the existing part in the fused 3D model. Spatial position matching is achieved through an iterative nearest point algorithm, and a seamless fusion technology based on surface continuity is adopted to ensure that the reconstructed part and the original part have a smooth and natural geometric transition without abrupt boundaries. Finally, an integrated 3D model is generated to fully present the original appearance of the component through reasoning reconstruction. In the integrated 3D model, the missing part generated by reasoning reconstruction and the original existing part are visually distinguished and marked, thus completing the original appearance reasoning reconstruction of the damaged component.
[0013] This invention also provides a method for reconstructing the original appearance of decorative components of damaged ancient buildings, the specific steps of which include: Step 1: Obtain multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. Perform fusion processing on the multi-source current status perception data to generate a fused 3D model, and extract the damaged edge features, ornamentation fragment features and color trace features from it. Step 2: Based on the features of the damaged edge, combined with the preset morphological rule base and reference geometric data, the complete three-dimensional outline of the missing part of the damaged component is generated through geometric continuity deduction and rule matching. Step 3: Based on the features of the decorative fragments and combined with the reference decorative data, the pattern bone method is used to analyze and match the smallest repeatable decorative unit to generate a set of candidate matching units. The confidence of the decorative structure corresponding to each candidate matching unit is calculated. The candidate matching unit with the highest confidence of the decorative structure is selected as the benchmark, and the complete surface decoration of the missing part is inferred and generated. Step 4: Based on color trace features, combined with historical color database, reference geometric data and reference pattern data, determine at least two candidate color sources, calculate the color source weight for each candidate color source, fuse each candidate color source and its weight, and infer to generate the original color distribution. Step 5: Input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. Then, geometrically align and seamlessly merge the model with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified.
[0014] Compared with the prior art, the beneficial effects of the present invention are: First, by integrating multi-source sensing data such as 3D laser scanning and multispectral imaging, this invention achieves simultaneous acquisition and high-precision modeling of geometric, decorative, and color information of damaged components. Based on the fused 3D model, it automatically extracts features of damaged edges, decorative fragments, and color traces, overcoming the limitations of traditional methods that rely on 2D images. This provides a comprehensive and reliable data foundation for subsequent reasoning and reconstruction, significantly improving the completeness and scientific rigor of the original restoration.
[0015] Secondly, this invention establishes a progressive reasoning mechanism from geometric contours to surface patterns and then to color distribution. Through morphological rule library matching and geometric continuity deduction, pattern bone method analysis and confidence assessment, and multi-source color fusion and weight calculation, it achieves the collaborative reconstruction of the shape, pattern, and color of the missing parts. This method not only effectively solves the adaptation problem of complex and incomplete patterns, but also ensures that the reconstruction results are highly consistent with the original components in terms of style, structure, and color by introducing historical style constraints and multi-source confidence assessment, thus taking into account both the accuracy of restoration and the continuity of cultural connotation.
[0016] Furthermore, this invention introduces a pre-trained 3D modeling system that can automatically generate high-quality reconstruction models based on inference parameters and achieve a natural transition between old and new parts through geometric alignment and seamless fusion technology. The final integrated 3D model supports the visual differentiation and identification of the reconstructed parts, ensuring the traceability and verifiability of the restoration process while fully presenting the restoration effect. This provides an efficient, intelligent, and operable complete solution for the digital protection and restoration of ancient buildings. Attached Figure Description
[0017] Figure 1 This is a schematic diagram of the overall system modules of the present invention; Figure 2 A dual Y-axis image for regularized distance, historical style differences, and confidence level of decorative structure; Figure 3 3D scatter images for regularized distances, historical stylistic differences, and confidence levels of decorative structure; Figure 4 This is a schematic diagram of the overall method flow of the present invention. Detailed Implementation
[0018] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to specific embodiments.
[0019] It should be noted that, unless otherwise defined, the technical or scientific terms used in this invention should have the ordinary meaning understood by one of ordinary skill in the art to which this invention pertains. The terms "first," "second," and similar terms used in this invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "comprising" or "including" mean that the element or object preceding the word encompasses the elements or objects listed following the word and their equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. Terms such as "upper," "lower," "left," and "right" are used only to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship may also change accordingly.
[0020] Example: Please see Figures 1-3 This invention provides a system for reconstructing the original appearance of decorative components of damaged ancient buildings, specifically including: The feature extraction module is used to acquire multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. It performs fusion processing on the multi-source current status perception data to generate a fused 3D model, and extracts the damage edge features, ornamentation fragment features and color trace features from it. In this embodiment, the multi-source current status perception data refers to the three-dimensional point cloud data that characterizes the current geometric shape of the damaged component obtained by three-dimensional laser scanning, and the multispectral feature image data that records the physical and chemical properties of the surface of the damaged component obtained by multispectral imaging equipment. The related components of the damaged component refer to other components that are directly related to the damaged component in terms of form, decorative style, construction period or structural function and have reference value, including other similar components belonging to the same building, components in symmetrical positions or components of the same known craftsmanship system; The reference geometric data refers to data obtained from the associated components of the damaged component that contains its complete or partial three-dimensional geometric shape; the reference decorative data refers to data obtained from the associated components of the damaged component and the damaged component archive that characterizes its surface decorative pattern style, structure and color information. The multi-source current situation perception data is fused to generate a fused 3D model. Specifically, the 3D point cloud data and multispectral feature image data are pixel-point cloud registered based on a common coordinate system, so that each 3D point is associated with the corresponding multispectral attribute vector, and a fused 3D model is generated. Extracting broken edge features from the fused 3D model specifically involves: based on the local curvature changes and normal abrupt changes of the 3D points in the fused 3D model, identifying and tracing the boundary lines constituting the broken fracture surface, forming a set of broken edge feature lines representing geometric discontinuities, which serve as broken edge features; Extracting decorative fragment features specifically involves: performing image segmentation on the surface texture image of the fused 3D model to obtain several closed regions; based on the color consistency measure and gradient direction consistency measure of the pixels in each closed region, regions whose color consistency measure is higher than a first preset threshold and whose gradient direction consistency measure is higher than a second preset threshold are selected as decorative fragment features. The calculation method for color consistency measure is as follows: the image is converted from RGB color space to Lab color space, and then the standard deviation of the luminance component L and chrominance components a and b are calculated for all pixels in the region. Then, the three standard deviations are weighted and summed, and the weighted sum is mapped to the interval [0,1] through an exponential function to obtain the color consistency measure value. The higher the value, the more uniform the color in the region. The weight of the luminance component is set to 0.4, and the weights of the chrominance components a and b are both set to 0.3 to reflect the dominant influence of luminance change on visual consistency.
[0021] The gradient orientation consistency measure is calculated as follows: First, the Sobel operator is used to calculate the gradient of the image in the horizontal and vertical directions respectively, and then the gradient magnitude and orientation angle of each pixel are obtained; then, for all pixels in the region, their gradient orientation angles are mapped to the circumferential angle range, and the variance of the orientation angles is calculated; then, the variance value is converted into a consistency measure through a Gaussian function, so that the more concentrated the orientation distribution, the higher the measure value; finally, the value is normalized to the interval [0,1] as the gradient orientation consistency measure.
[0022] Extracting color trace features specifically involves: analyzing the multispectral attribute vectors associated with each 3D point in the fused 3D model. These multispectral attribute vectors, after registration, are vectors composed of pixel values from multispectral feature images across multiple preset bands, corresponding to the spatial location of each 3D point. Principal component analysis is used to reduce the dimensionality of these multispectral attribute vectors. Then, a clustering algorithm is used to group the pixels in the reduced feature space, resulting in several pixel clusters. The mean spectral feature vector of each pixel cluster is calculated and compared with a preset baseline spectral feature vector for typical weathered and polluted areas. The Euclidean distance between the two is calculated. If the Euclidean distance is greater than a set discrimination threshold, the pixel cluster is determined to be a potential original color or material residue, and its corresponding color and material information is extracted as color trace features. The method for determining the spectral feature reference vector of the typical weathered and polluted area is as follows: Select the surface area that has been clearly identified as weathered, stained or polluted, collect its spectral intensity data in multiple preset bands, and after normalization, calculate the mean and variance of the intensity of each band to form a reference vector that characterizes the typical spectral distribution of this type of area; at the same time, establish a reference library containing multiple common weathering types to support the discrimination of different pollution patterns; this reference serves as a reference standard for spectral features in the system to distinguish between polluted areas and potential original color residues.
[0023] The contour reasoning module is used to infer and generate the complete three-dimensional contour of the missing part of the damaged component based on the features of the damaged edge, combined with the preset morphological structure rule base and reference geometric data, through geometric continuity deduction and rule matching. In this embodiment, each boundary line in the set of damaged edge feature lines is traversed and discretized into an ordered sequence of points. For each boundary line, at its endpoint, the tangent vector of the point is calculated using the difference method based on the coordinates of adjacent points, thereby determining its tangent direction. At the same time, the curvature value at the endpoint is obtained by calculating the locally fitted arc of the sequence of points near the endpoint. Establishing a topological connection between adjacent boundary lines involves setting a distance threshold. If the spatial Euclidean distance between the endpoints of two different boundary lines is less than the distance threshold, then the two endpoints are determined to be connected points, and the connection is recorded. The endpoint tangent directions, endpoint curvatures, and all identified endpoint connection relationships of all boundary lines are integrated to form the continuity constraint parameter set. The set of continuity constraint parameters is input into the morphological composition rule base for matching. The morphological composition rule base contains several morphological generation rules derived from historical intact components. Each rule defines a possible surface or block shape under given boundary conditions. Based on the degree of matching, at least one candidate morphological rule that meets the conditions is selected, and one or more preliminary morphological hypotheses are generated based on each candidate morphological rule and the set of continuity constraint parameters. The characteristic geometric elements in the reference geometric data are obtained. The characteristic geometric elements refer to specific geometric structures that are predefined according to the architectural style and form knowledge base to which the component belongs, or automatically identified through curvature analysis, including specific relief protrusions, groove cross sections, arch curves, bracket body outlines, and column head volute curves.
[0024] After spatially aligning each preliminary morphological hypothesis with the characteristic geometric elements in the reference geometric data, geometric similarity is calculated. Specifically, the specific cross-sectional contour lines of each preliminary morphological hypothesis and the contour lines of the characteristic geometric elements are extracted. Equal arc length sampling is performed on each contour line to obtain an ordered set of feature points. The coordinates of each feature point set are then converted into a complex sequence. in, It is a complex sequence; ) is the first The coordinates of each sampling point The index of the sampling point; This represents the total number of sampling points for the contour line. For complex sequences Performing a Discrete Fourier Transform yields the Fourier descriptor, based on the following formula: in, Indicates the first Fourier descriptors corresponding to each frequency component Frequency index; The imaginary unit; The Fourier descriptor is normalized to obtain the shape feature vector: in, Represents the shape feature vector; The number of low-frequency components selected, and satisfying the following conditions: ; Calculate the Euclidean distance between the shape feature vector of each preliminary morphological hypothesis and the shape feature vector of the characteristic geometric element, and determine the negative value of the Euclidean distance as the geometric similarity. Select the preliminary morphological hypothesis with the highest geometric similarity as the optimization benchmark. The significance of calculating geometric similarity lies in providing an objective screening basis for the 3D contour reasoning of missing parts of damaged components. By comparing the preliminary morphological assumptions with the characteristic geometric elements in the reference geometric data, candidate schemes that do not match the geometric shape and style of the original component can be effectively eliminated. Its core value is reflected in the following: Based on the shape feature extraction of discrete Fourier transform and the calculation of Euclidean distance, it can overcome the limitations of subjective experience judgment, accurately capture the key geometric features and overall morphological rules of the contour, and ensure that the selected optimization benchmark is highly consistent with the existing part and similar components of the same period in terms of structural logic, size ratio and style consistency. At the same time, by converting Euclidean distance into geometric similarity, the degree of fit of different preliminary morphological assumptions can be intuitively quantified, providing a reliable foundation for subsequent surface optimization based on energy minimization. Ultimately, it achieves geometric compatibility and G1 continuous transition between the 3D contour of the missing part and the existing part, ensuring the accuracy, naturalness and historical rationality of the reconstructed contour, and providing solid geometric support for the restoration of the original appearance of decorative components of ancient buildings.
[0025] The selected optimization benchmark is optimized using a surface optimization method based on energy minimization. Under the premise of satisfying the continuity constraint parameter set, its boundary is made to match the existing partial boundary in the fused 3D model. Continuity means that the position and normal vector at the boundary are continuous. At the same time, the interior of the surface is smoothed, and finally a complete three-dimensional contour model of the missing part of the damaged component is output, which is geometrically compatible with the existing part.
[0026] The ornamentation reasoning module is used to generate a candidate matching unit set by matching the smallest repeatable ornamentation unit with the ornamentation fragment features and reference ornamentation data through pattern bone analysis, and to calculate the ornamentation structure confidence of each candidate matching unit. The candidate matching unit with the highest ornamentation structure confidence is selected as the benchmark to infer and generate the complete surface ornamentation of the missing part. In this embodiment, based on the features of the decorative fragments extracted from the fused 3D model, bone-like features that can characterize its overall direction and shape are extracted, specifically represented as one or more center lines obtained after skeletonization. At the same time, the minimum repeatable decorative unit library of decorative units extracted from the reference decorative data is analyzed and established. The minimum repeatable decorative unit refers to the smallest complete pattern unit in the reference decorative pattern that can fill a continuous area without overlap through symmetrical transformations such as translation, rotation or mirroring. Then, the bone structure features of the ornamentation fragments are matched with the bone structure features of each unit in the minimum repeatable ornamentation unit library. The matching process is achieved by calculating the regular distance between two centerline sequences. The smaller the distance value, the more the two curves match in shape and trend. This generates a candidate matching unit set containing several matching units and their corresponding regular distance values. For each candidate matching unit in the candidate matching unit set, the confidence score of the decorative structure is calculated using the following formula: In the formula, Confidence level of decorative structure; Indicates the degree of difference in historical styles; Indicates a regular distance; and The preset weights for the corresponding indicators, And satisfy The reason for setting the weights in this way is that the regularity distance directly reflects the degree of agreement between the remaining decorative fragments and the candidate decorative units in terms of geometric shape and spatial trend, which has a direct impact on the geometric continuity and visual naturalness of the reconstruction results. While the historical style difference reflects the consistency of the decoration in the cultural and historical context, its judgment often relies on historical information such as documents and knowledge bases, which may be incomplete or have multiple interpretations. Moreover, the consistency of style does not directly determine whether the local pattern can achieve geometric connection at the damaged edge. Therefore, giving the regularity distance a higher weight in the confidence calculation can prioritize the rationality and integrity of the reconstructed decoration in terms of form, and avoid geometric mismatches or breaks caused by over-reliance on style inference.
[0027] For this formula, the dependent variable This value characterizes the reliability of a candidate matching unit for reconstructing the surface texture of a damaged component. A higher value indicates a high degree of geometrical similarity to the remaining texture fragments and consistency with the component's historical style, thus making it a reliable reconstruction benchmark. Conversely, a lower value indicates a lower reliability. A smaller value indicates that the candidate matching unit either has a large shape difference, an inconsistent style, or both. Therefore, it is of higher risk as a basis for reconstruction and may cause the reconstruction result to deviate from the original appearance at the visual or cultural level.
[0028] Ancient architectural ornamentation often possesses distinct characteristics of its era and region. Decorative styles from different historical periods or regions exhibit systematic differences in pattern themes, compositional rules, and symbolic meanings. If the selected candidate matching unit does not match the construction period or regional background of the target component, even if the geometric shapes are partially similar, the overall cultural connotation and artistic style of the ornamentation may not align, resulting in a reconstruction that is "similar in form but not in spirit." Therefore... The larger, The lower; regular distance Influence This is because it directly depicts the degree of matching between the remaining decorative fragments and the candidate units in terms of centerline direction, curvature, etc. If the two shapes differ greatly, it means that the candidate unit cannot naturally connect with the existing decorative fragments. Forcing its use will lead to pattern breakage and discontinuous trends, affecting visual integrity and structural logic. The larger, The lower the value, the better.
[0029] This formula uses a fractional structure, ensuring... The range of values is Between, and when , , Time-complete matching; as any difference increases, the denominator increases. Decreasing tone, which aligns with intuition; secondly, linear weighted sum. Two indicators with different dimensions and physical meanings are integrated into a comprehensive difference measure, and their relative importance is reflected through weights.
[0030] Table 1: Confidence Statistical Table of Ornament Structure Based on the analysis of the 14 candidate matching unit data in Table 1, the following key conclusions can be drawn: In calculating the confidence level of ornamentation structure, regularity distance and historical style difference are the core influencing factors. As can be seen from the data, when both regularity distance and historical style difference are 0 (such as candidate matching unit 1 and candidate matching unit 2), the confidence level of ornamentation structure reaches its maximum value of 1. As regularity distance increases or historical style difference increases, the confidence level shows a significant downward trend. For example, when regularity distance is maintained at 0.2 and historical style difference is 0, the confidence level drops to 0.8772; if regularity distance increases to 0.4 and historical style difference is 0.5, the confidence level further decreases to 0.7042; in extreme cases, such as when regularity distance is 1 and historical style difference is 1, the confidence level is only 0.4762, indicating that when the shape difference is significant and the historical style is completely mismatched, the confidence level of candidate matching units is greatly reduced.
[0031] Overall, regularity distance is more sensitive to the impact on confidence level, but historical style difference also plays an important moderating role; this reflects that in the process of pattern matching, the system not only pays attention to the similarity of geometric shapes, but also relies heavily on the coherence of historical styles, so as to ensure that the reconstruction results conform to the original features in both form and meaning.
[0032] The determination method is as follows: Query the historical color database or architectural style knowledge base, compare the known historical period and regional style of the candidate matching unit with the known construction period and region of the target damaged component. If both the period and region match perfectly, then... If only one of the periods or regions matches, then If none of them match, then ; The candidate matching unit with the highest confidence in the pattern structure is selected as the benchmark. Using the complete pattern information of the unit and the spatial range defined by the broken edge features, the complete surface pattern covering the entire missing area is generated by inferring through pattern extension and boundary fusion algorithms.
[0033] The color reasoning module is used to determine at least two candidate color sources based on color trace features, combined with historical color database, reference geometric data and reference pattern data, calculate the color source weight for each candidate color source, fuse the candidate color sources and their weights, and infer to generate the original color distribution. In this embodiment, based on the color trace features extracted from the fused 3D model, the original color information and distribution pattern remaining on the surface of the damaged component are obtained; at the same time, by comprehensively querying the historical color database and the color information parsed from the reference geometric data and reference pattern data, at least two candidate color sources are determined; the candidate color sources include: measured color data extracted from the surface of intact related components of the same building at the same time, historical color spectrum data summarized from historical drawings, document records or similar buildings of the same period, and the dominant color system analyzed and inferred from the residual color traces of the component itself; For each candidate color source, calculate its corresponding color source weight: in, Indicates the first The weights of each candidate color source; , and Representing the first The spatiotemporal correlation score, information reliability score, and style coherence score of each candidate color source. , , The preset weighting coefficients are used, and they satisfy the following conditions: , The reason for this weighting is that the spatiotemporal correlation score measures the consistency between the candidate color source and the target component in terms of historical period and region. This is the cultural foundation of color restoration, because the colors used in ancient buildings often have clear characteristics of the era and region. Color information from the same period and place has the most direct reference value, hence it is given the highest weight. The information reliability score reflects the credibility of the data itself. If the measured data is higher than the literature's estimation, it is important but less important than spatiotemporal correlation, because even if the data is reliable, if the spatiotemporal background is inconsistent, it may still lead to a mismatch in color style. Therefore, the weighting is relatively low. Secondly, the style synergy score evaluates the degree of matching between color and the established decorative style. Its importance is relatively low because color style can be inferred to some extent from spatiotemporal relationships, and while the synergy between decoration and color contributes to overall harmony, it does not directly affect the historical authenticity of the color itself. Therefore, its weight is relatively low. Minimum.
[0034] For this formula, the dependent variable Used to characterize the The relative reliability and contribution of each candidate color source in reconstructing the original color distribution of the damaged component are considered. A higher value indicates that the color source is closer to the target component in time and space, the data is more reliable, and it is more coordinated with the component's decorative style; therefore, it should occupy a higher proportion in color fusion. Conversely, if... A lower weight indicates that the color source has deficiencies in historical background, data quality, or style consistency. It should be given a lower weight during the reconstruction process to avoid introducing inaccurate or inconsistent color information.
[0035] If the candidate color source and the target component belong to the same historical period and region, their color information best represents the original appearance. The higher, The larger the score, the higher the information reliability rating. Influence This is because the quality of the source of color data directly determines its reliability. For example, measured color data obtained through 3D laser scanning and multispectral imaging has an objective and accurate physical basis, while inferences based on literature descriptions or low-resolution images have significant uncertainties. The higher, Larger; Style Coherence Score Influence This is because patterns and colors in architectural decoration often follow a unified artistic style system. If the candidate colors are highly coordinated with the deduced pattern style, it can enhance the artistic consistency of the overall restoration. The higher, The larger.
[0036] The method for determining the spatiotemporal correlation score is as follows: obtain the known or verified construction period of the target damaged component. and region For the first Each candidate color source was identified, and the corresponding period for that source was determined. and region Then, a score is calculated using a preset time difference function and a regional correlation function. and For the same historical period (accurate to the dynasty), and and If they are from the same region, then ;like and Belonging to the same historical period but differing in early and late stages, such as both being from the Ming Dynasty but divided into early, middle, and late periods, or and If they belong to the same cultural region but not the same specific location, then ;like and Belonging to different historical periods but sharing a cultural inheritance relationship, or and For neighboring regions influenced by the same mainstream culture, then ;otherwise, The specific thresholds for judging the period difference function and the regional correlation function are pre-set based on historical research consensus.
[0037] The method for determining the information reliability score is as follows: if the color data originates from the direct measurement and analysis results of three-dimensional laser scanning and multispectral imaging of the intact surface of the associated component, then... If the color data originates from high-resolution, undisputed historical photographs or survey maps, and is extracted using color correction techniques, then... If the color data originates from historical images of general clarity, textual descriptions in documents, or color information from indirect but similarly styled reference components, then... If the color data is primarily based on inferences from residual traces or comes from reference sources with significantly different styles, then .
[0038] The method for determining the style synergy score is as follows: obtain the decorative art style identifier corresponding to the candidate matching unit with the highest confidence in the pattern structure, and simultaneously obtain the... For each candidate color source, the associated or represented color art style identifier is queried against a pre-defined historical art style association knowledge base. This knowledge base defines the matching relationships between different decorative styles and typical color styles. If the color art style identifier is recorded as a strong association in this knowledge base, then... If recorded as coexistent, then If there is no clearly related record in the knowledge base, or if the style identifiers of the two are contradictory, then .
[0039] The formula uses linear weighting to integrate the scores from three different dimensions into a single comprehensive weight, resulting in a clear structure that is easy to calculate. Furthermore, the weight settings ensure that each score contributes to the normalization of the total weight while also reflecting their relative importance in the decision-making process through the magnitude of the coefficients, which aligns with the actual logic of color reconstruction.
[0040] The candidate color sources and their weights are then merged: in, The total number of candidate color sources. Indicates the first The coordinates of each color source on the model surface The color attribute vector provided at that location Indicates in Color attributes after fusion; By calculating the coordinates of all missing regions, the original color distribution is inferred and generated, specifically as follows: After obtaining each candidate color source and its weight, the system performs dense coordinate sampling on the surface of the missing region, targeting each sampling point. The color vectors in the CIELAB color space are obtained from each color source: for measured data, the corresponding pixel values are extracted from the aligned multispectral image; for historical color spectra, typical color values are mapped according to the pattern partitions; for residual traces, they are obtained through interpolation; subsequently, the formula is used... The color vectors of each candidate color source are channel-weighted and fused to obtain the final color of that point. After traversing all sampling points, a continuous color distribution field covering the missing area is formed, and Laplacian smoothing is applied to eliminate abrupt changes. Finally, a color texture mapping that matches the geometric region is output as the original color distribution result.
[0041] The fusion module is used to input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. It then performs geometric alignment and seamless fusion with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified. In this embodiment, the complete 3D contour, complete surface texture and original color distribution are used as reconstruction parameters and input into a pre-trained 3D modeling system to obtain a 3D reconstruction model of the missing part. The training process of the 3D modeling system is as follows: First, a large number of high-precision 3D models of decorative components of well-preserved ancient buildings and their corresponding geometric, decorative, and color data are collected to construct a training sample set. Then, based on a deep learning architecture, a model capable of inferring and generating a complete 3D structure from multi-parameter inputs is designed. During training, the system learns to reconstruct the mapping relationship of complete components from incomplete geometric contours, local decorative fragments, and color traces. The network parameters are optimized by minimizing the geometric error, texture difference, and color distribution distance between the generated model and the real complete model. Finally, after multiple rounds of iterative training and verification, the system has the ability to automatically generate 3D models that conform to historical style and structural logic based on the input inference and reconstruction parameters. The generated 3D reconstructed model of the missing part is geometrically aligned with the existing part in the fused 3D model. Spatial position matching is achieved through an iterative nearest-point algorithm, and a seamless fusion technique based on surface continuity is employed. Specifically, using the point cloud of the existing part as the target point set and the point cloud of the reconstructed model as the source point set, the optimal rigid body transformation between the two point sets is iteratively calculated to minimize the average distance between point pairs in the overlapping area between the reconstructed model and the existing part, thereby achieving precise alignment of the two in the spatial coordinate system. Building upon this, a further seamless fusion technique based on surface continuity is used: in the aligned boundary region, adjacent surface patches of the existing and reconstructed parts are extracted. A smooth transition surface satisfying G1 continuity is solved, and a Laplacian smoothing-based surface deformation method is used to locally adjust the adjacent surfaces of the reconstructed part, ensuring a geometrically smooth connection between its boundary and the boundary of the existing part. The curvature transitions naturally, ultimately forming an integrated 3D model that is seamless both visually and geometrically, presenting the original appearance of the component's inferential reconstruction. Within this integrated 3D model, the missing parts generated by the inferential reconstruction are visually distinguished from the original existing parts: a dedicated label is added to all triangular faces or vertices of the reconstructed part in the model data structure, indicating that it belongs to the "inferential reconstruction area." Subsequently, in the 3D visualization environment, the system uses semi-transparent rendering and highlighted borders for visual differentiation. Simultaneously, it supports interactive switching of display modes, such as displaying only the reconstructed part, only the existing part, or a mixed display. A switchable label layer can be overlaid on the model surface to intuitively mark the extent and confidence level of the reconstructed area. This ensures that while fully presenting the component's restoration effect, it clearly distinguishes between the original and reconstructed content, guaranteeing the traceability of the restoration process and the verifiability of the results.
[0042] Please see Figure 4 The method for reconstructing the original appearance of decorative components of damaged ancient buildings includes the following specific steps: Step 1: Obtain multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. Perform fusion processing on the multi-source current status perception data to generate a fused 3D model, and extract the damaged edge features, ornamentation fragment features and color trace features from it. Step 2: Based on the features of the damaged edge, combined with the preset morphological rule base and reference geometric data, the complete three-dimensional outline of the missing part of the damaged component is generated through geometric continuity deduction and rule matching. Step 3: Based on the features of the decorative fragments and combined with the reference decorative data, the pattern bone method is used to analyze and match the smallest repeatable decorative unit to generate a set of candidate matching units. The confidence of the decorative structure corresponding to each candidate matching unit is calculated. The candidate matching unit with the highest confidence of the decorative structure is selected as the benchmark, and the complete surface decoration of the missing part is inferred and generated. Step 4: Based on color trace features, combined with historical color database, reference geometric data and reference pattern data, determine at least two candidate color sources, calculate the color source weight for each candidate color source, fuse each candidate color source and its weight, and infer to generate the original color distribution. Step 5: Input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. Then, geometrically align and seamlessly merge the model with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified.
[0043] The above formulas are all dimensionless calculations. The formulas are derived from software simulations based on a large amount of collected data to obtain the most recent real-world results. The preset parameters in the formulas are set by those skilled in the art according to the actual situation.
[0044] The above embodiments can be implemented, in whole or in part, by software, hardware, firmware, or any other combination thereof. When implemented in software, the above embodiments can be implemented, in whole or in part, as a computer program product. Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution.
[0045] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment, depending on actual needs.
[0046] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A system for reconstructing the original appearance of a damaged ornamental component of an ancient building, characterized in that it comprises: include: The feature extraction module is used to acquire multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. It performs fusion processing on the multi-source current status perception data to generate a fused 3D model, and extracts the damage edge features, ornamentation fragment features and color trace features from it. The contour reasoning module is used to infer and generate the complete three-dimensional contour of the missing part of the damaged component based on the features of the damaged edge, combined with the preset morphological structure rule base and reference geometric data, through geometric continuity deduction and rule matching. The ornamentation reasoning module is used to generate a candidate matching unit set by matching the smallest repeatable ornamentation unit with the ornamentation fragment features and reference ornamentation data through pattern bone analysis, and to calculate the ornamentation structure confidence of each candidate matching unit. The candidate matching unit with the highest ornamentation structure confidence is selected as the benchmark to infer and generate the complete surface ornamentation of the missing part. The color reasoning module is used to determine at least two candidate color sources based on color trace features, combined with historical color database, reference geometric data and reference pattern data, calculate the color source weight for each candidate color source, fuse the candidate color sources and their weights, and infer to generate the original color distribution. The fusion module is used to input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. It then performs geometric alignment and seamless fusion with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified. Based on the features of the decorative fragments extracted from the fused 3D model, bone-like features that can characterize its overall direction and shape are extracted, specifically represented as one or more center lines obtained after skeletonization. At the same time, the minimum repeatable decorative unit library of decorative units extracted from the reference decorative data is analyzed and established. The minimum repeatable decorative unit refers to the smallest complete pattern unit in the reference decorative pattern that can fill a continuous area without overlap through symmetrical transformations such as translation, rotation or mirroring. Then, the bone structure features of the ornamentation fragments are matched with the bone structure features of each unit in the minimum repeatable ornamentation unit library. The matching process is achieved by calculating the regular distance between two centerline sequences. The smaller the distance value, the more the two curves match in shape and trend. This generates a candidate matching unit set containing several matching units and their corresponding regular distance values. For each candidate matching unit in the candidate matching unit set, the confidence score of the decorative structure is calculated using the following formula: In the formula, Confidence level of decorative structure; Indicates the degree of difference in historical styles; Indicates a regular distance; and The preset weights for the corresponding indicators, And satisfy ; The determination method is as follows: Query the historical color database or architectural style knowledge base, compare the known historical period and regional style of the candidate matching unit with the known construction period and region of the target damaged component. If both the period and region match perfectly, then... If only one of the periods or regions matches, then If none of them match, then ; The candidate matching unit with the highest confidence in the decorative structure is selected as the benchmark. Using the complete pattern information of the unit and the spatial range defined by the broken edge features, the complete surface pattern covering the entire missing area is generated by inferring through pattern extension and boundary fusion algorithms. Based on the color trace features extracted from the fused 3D model, the original color information and distribution pattern remaining on the surface of the damaged component are obtained; at the same time, by comprehensively querying the historical color database and the color information parsed from the reference geometric data and reference pattern data, at least two candidate color sources are determined. The candidate color sources include: measured color data extracted from the surface of intact related components of the same building at the same time; historical color spectrum data summarized from historical drawings, documents, or similar buildings of the same period; and dominant color systems analyzed and inferred from the residual color traces of the components themselves. For each candidate color source, calculate its corresponding color source weight: in, Indicates the first The weights of each candidate color source; , and Representing the first The spatiotemporal correlation score, information reliability score, and style coherence score of each candidate color source. , , The preset weighting coefficients are used, and they satisfy the following conditions: ; The candidate color sources and their weights are then merged: in, The total number of candidate color sources. This represents the coordinates of the j-th color source on the model surface. The color attribute vector provided at that location Indicates in The color attributes after fusion; The original color distribution is generated by calculating the coordinates of all missing regions.
2. The system for reconstructing the original appearance of decorative components of damaged ancient buildings according to claim 1, characterized in that: The multi-source current status perception data refers to three-dimensional point cloud data that characterizes the current geometric shape of the damaged component, obtained through three-dimensional laser scanning, and multispectral feature image data that records the physicochemical properties of the surface of the damaged component, obtained through multispectral imaging equipment. The related components of the damaged component refer to other components that are directly related to the damaged component in terms of form, decorative style, construction period or structural function and have reference value, including other similar components belonging to the same building, components in symmetrical positions or components of the same known craftsmanship system; The reference geometric data refers to data obtained from the associated components of the damaged component that contains its complete or partial three-dimensional geometric shape; The reference decorative data refers to data obtained from the associated components of the damaged component and the archives of the damaged component, which characterizes the surface decorative pattern style, structure and color information; The multi-source current situation perception data is fused to generate a fused 3D model. Specifically, the 3D point cloud data and multispectral feature image data are pixel-point cloud registered based on a common coordinate system, so that each 3D point is associated with the corresponding multispectral attribute vector, and a fused 3D model is generated. Extracting broken edge features from the fused 3D model specifically involves: based on the local curvature changes and normal abrupt changes of the 3D points in the fused 3D model, identifying and tracing the boundary lines constituting the broken fracture surface, forming a set of broken edge feature lines representing geometric discontinuities, which serve as broken edge features; Extracting decorative fragment features specifically involves: performing image segmentation on the surface texture image of the fused 3D model to obtain several closed regions; based on the color consistency measure and gradient direction consistency measure of the pixels in each closed region, regions whose color consistency measure is higher than a first preset threshold and whose gradient direction consistency measure is higher than a second preset threshold are selected as decorative fragment features. The extraction of color trace features specifically involves: analyzing the multispectral attribute vectors associated with each 3D point in the fused 3D model. These multispectral attribute vectors, after registration, are vectors composed of pixel values from multispectral feature images across multiple preset bands, corresponding to the spatial location of each 3D point. Principal component analysis is used to reduce the dimensionality of these multispectral attribute vectors. Then, a clustering algorithm is used to group the pixels in the reduced feature space, resulting in several pixel clusters. The mean spectral feature vector of each pixel cluster is calculated and compared with a preset benchmark vector of spectral features from a typical weathered and polluted area. The Euclidean distance between the two is calculated. If the Euclidean distance is greater than a set discrimination threshold, the pixel cluster is determined to be a potential original color or material residue, and its corresponding color and material information is extracted as color trace features.
3. The system for reconstructing the original appearance of decorative components of damaged ancient buildings according to claim 2, characterized in that: Traverse each boundary line in the set of damaged edge feature lines and discretize it into an ordered sequence of points; for each boundary line, at its endpoint, use the difference method based on the coordinates of adjacent points to calculate the tangent vector of that point, thereby determining its tangent direction; at the same time, by calculating the locally fitted arc of the sequence of points near the endpoint, obtain the curvature value at that endpoint. Establishing a topological connection between adjacent boundary lines involves setting a distance threshold. If the spatial Euclidean distance between the endpoints of two different boundary lines is less than the distance threshold, then the two endpoints are determined to be connected points, and the connection is recorded. The endpoint tangent directions, endpoint curvatures, and all identified endpoint connection relationships of all boundary lines are integrated to form a set of continuity constraint parameters. The set of continuity constraint parameters is input into the morphological composition rule base for matching. The morphological composition rule base contains several morphological generation rules derived from historical intact components. Each rule defines a possible surface or block shape under given boundary conditions. Based on the degree of matching, at least one candidate morphological rule that meets the conditions is selected, and one or more preliminary morphological hypotheses are generated based on each candidate morphological rule and the set of continuity constraint parameters. The characteristic geometric elements in the reference geometric data are obtained. The characteristic geometric elements refer to specific geometric structures that are predefined according to the architectural style and form knowledge base to which the component belongs, or automatically identified through curvature analysis, including specific relief protrusions, groove cross sections, arch curves, bracket body outlines, and column head volute curves.
4. The system for reconstructing the original appearance of decorative components of damaged ancient buildings according to claim 3, characterized in that: After spatially aligning each preliminary morphological hypothesis with the characteristic geometric elements in the reference geometric data, geometric similarity is calculated. Specifically, the specific cross-sectional contour lines of each preliminary morphological hypothesis and the contour lines of the characteristic geometric elements are extracted. Equal arc length sampling is performed on each contour line to obtain an ordered set of feature points. The coordinates of each feature point set are then converted into a complex sequence. in, It is a complex sequence; ) is the first The coordinates of each sampling point The index of the sampling point; This represents the total number of sampling points for the contour line. For complex sequences Performing a Discrete Fourier Transform yields the Fourier descriptor, based on the following formula: in, Indicates the first Fourier descriptors corresponding to each frequency component Frequency index; The imaginary unit; The Fourier descriptor is normalized to obtain the shape feature vector: in, Represents the shape feature vector; The number of low-frequency components selected, and satisfying the following conditions: ; Calculate the Euclidean distance between the shape feature vector of each preliminary morphological hypothesis and the shape feature vector of the characteristic geometric element, and determine the negative value of the Euclidean distance as the geometric similarity. Select the preliminary morphological hypothesis with the highest geometric similarity as the optimization benchmark. The selected optimization benchmark is optimized using a surface optimization method based on energy minimization. Under the premise of satisfying the continuity constraint parameter set, its boundary is made to match the existing partial boundary in the fused 3D model. The process is continuous, and the interior of the curved surface is smoothed to finally output a complete three-dimensional contour model of the missing part of the damaged component that is geometrically compatible with the existing part.
5. The system for reconstructing the original appearance of decorative components of damaged ancient buildings according to claim 1, characterized in that: The complete 3D contour, complete surface texture, and original color distribution are used as reconstruction parameters and input into a pre-trained 3D modeling system to obtain a 3D reconstruction model of the missing parts. The training process of the 3D modeling system is as follows: First, a large number of high-precision 3D models of decorative components of well-preserved ancient buildings and their corresponding geometric, decorative, and color data are collected to construct a training sample set. Then, based on a deep learning architecture, a model capable of inferring and generating a complete 3D structure from multi-parameter inputs is designed. During training, the system learns to reconstruct the mapping relationship of complete components from incomplete geometric contours, local decorative fragments, and color traces. The network parameters are optimized by minimizing the geometric error, texture difference, and color distribution distance between the generated model and the real complete model. Finally, after multiple rounds of iterative training and verification, the system has the ability to automatically generate 3D models that conform to historical style and structural logic based on the input inference and reconstruction parameters. The generated 3D reconstruction model of the missing part is geometrically aligned with the existing part in the fused 3D model. Spatial position matching is achieved through an iterative nearest point algorithm, and a seamless fusion technology based on surface continuity is adopted to ensure that the reconstructed part and the original part have a smooth and natural geometric transition without abrupt boundaries. Finally, an integrated 3D model is generated to fully present the original appearance of the component through reasoning reconstruction. In the integrated 3D model, the missing part generated by reasoning reconstruction and the original existing part are visually distinguished and marked, thus completing the original appearance reasoning reconstruction of the damaged component.
6. A method for reconstructing the original appearance of decorative components of damaged ancient buildings, characterized by: The method for reconstructing the original appearance of decorative components of damaged ancient buildings is performed using the system for reconstructing the original appearance of decorative components of damaged ancient buildings as described in any one of claims 1-5, and the specific steps include: Step 1: Obtain multi-source current status perception data of the damaged component, as well as reference geometric data and reference ornamentation data of the related components of the damaged component. Perform fusion processing on the multi-source current status perception data to generate a fused 3D model, and extract the damaged edge features, ornamentation fragment features and color trace features from it. Step 2: Based on the features of the damaged edge, combined with the preset morphological rule base and reference geometric data, the complete three-dimensional outline of the missing part of the damaged component is generated through geometric continuity deduction and rule matching. Step 3: Based on the features of the decorative fragments and combined with the reference decorative data, the pattern bone method is used to analyze and match the smallest repeatable decorative unit to generate a set of candidate matching units. The confidence of the decorative structure corresponding to each candidate matching unit is calculated. The candidate matching unit with the highest confidence of the decorative structure is selected as the benchmark, and the complete surface decoration of the missing part is inferred and generated. Step 4: Based on color trace features, combined with historical color database, reference geometric data and reference pattern data, determine at least two candidate color sources, calculate the color source weight for each candidate color source, fuse each candidate color source and its weight, and infer to generate the original color distribution. Step 5: Input the complete 3D contour, complete surface texture and original color distribution as reconstruction parameters into the pre-trained 3D modeling system to obtain the 3D reconstruction model of the missing part. Then, geometrically align and seamlessly merge the model with the existing part in the fused 3D model to generate an integrated 3D model. In this model, the missing part generated by inference reconstruction and the original existing part are visually distinguished and identified.