A method for three-dimensional quantification of concrete surface spalling based on RGB-D camera

By using an improved instance segmentation model and polynomial surface fitting, the problems of depth map voids and perspective distortion in concrete surface spalling detection by RGB-D cameras were solved, achieving high-precision three-dimensional quantization calculation.

CN123160477APending Publication Date: 2026-11-24ZHEJIANG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611319703.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-28
Publication Date
2026-11-24

AI Technical Summary

Technical Problem

In existing RGB-D cameras, the detection of spalling on concrete surfaces suffers from inaccurate 3D quantization calculations due to voids in the depth map, interference from transition zones in fitting the undamaged reference surface, and measurement errors caused by uncorrected perspective distortion.

Method used

An improved instance segmentation model based on an RGB-D camera is used to extract hole state markers from the depth map. The two branches of the improved instance segmentation model are used to separate boundary deformation from background texture. By combining a two-dimensional response weight map and polynomial surface fitting, the normal peeling depth and perspective deformation are corrected, and three-dimensional quantization calculation is performed.

Benefits of technology

It improves the accuracy of 3D quantization calculation, ensures the continuity of input data, eliminates pixel interference in transition zones, corrects perspective distortion errors, and improves the calculation accuracy of the area and volume of irregular peeling areas.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123160477A_ABST
    Figure CN123160477A_ABST
Patent Text Reader

Abstract

This invention relates to the field of concrete defect detection technology and discloses a three-dimensional quantization method for concrete surface spalling based on an RGB-D camera. The method includes acquiring color images and depth maps and performing pixel registration; marking pixels with missing depths as having void states; outputting damage detection boxes and masks using an improved instance segmentation model; extracting two-dimensional response weight maps of network branches; using thresholding to eliminate transition zone pixels within the undamaged candidate region; mapping the remaining pixels to generate a three-dimensional point cloud; fitting the equation of the undamaged reference surface; calculating the effective pixel normal spalling depth and repairing the void pixel depths; multiplying the area element by the normal depth and performing discrete integration to calculate the area and volume. This invention improves the accuracy of reference surface fitting by isolating boundary transition zone pixels through a weight map, and eliminates projection errors from non-orthogonal viewpoints by combining normal depth and perspective distortion correction factors, thereby improving the quantization accuracy of the spalling area.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of concrete defect detection technology, specifically a three-dimensional quantification method for concrete surface spalling based on an RGB-D camera. Background Technology

[0002] Concrete surface spalling is a common form of structural damage. Quantifying the three-dimensional volume and area of ​​concrete surface spalling is a fundamental step in assessing the service condition of a structure. Current technologies often use RGB-D cameras to simultaneously acquire color images and depth maps of the concrete surface, and combine image recognition algorithms with depth information to perform three-dimensional reconstruction and quantitative calculations.

[0003] In actual inspection operations, due to the physical range constraints of the RGB-D camera depth sensor and the reflective characteristics of the concrete surface, the original depth map acquired by the hardware device contains pixels with zero values ​​or no reflection signals. These discrete depth holes disrupt the continuity of the input data required for subsequent three-dimensional quantization calculations. Before calculating the specific spalling depth, it is necessary to extract the undamaged background area to fit the reference surface. Conventional methods do not isolate the transition zone pixels at the boundary between the spalled area and the undamaged area when extracting the undamaged background area. The transition zone pixels are mixed into the point cloud fitting data, which will cause the final calculated undamaged reference surface equation to deviate from the original structural morphology of the concrete, resulting in geometric distortion of the reference surface used as the measurement benchmark.

[0004] Furthermore, conventional 3D quantization methods directly extract depth values ​​along the camera's line of sight and perform discrete integration calculations using the area of ​​the color image on the pixel plane. This calculation logic does not take into account the relative angle between the camera's shooting angle and the normal direction of the structural reference plane. When the camera's line of sight is not strictly orthogonal to the concrete structure surface, or when the concrete structure itself has surface curvature, the depth values ​​obtained along the line of sight and the two-dimensional projected area both contain perspective distortion errors, causing the final calculated irregular spalling area and volume to deviate from the true physical dimensions. Summary of the Invention

[0005] To address the shortcomings of existing technologies, this invention provides a three-dimensional quantization method for concrete surface spalling based on an RGB-D camera, which solves the problems of voids in depth maps, interference from transition zones in fitting undamaged reference surfaces, and measurement errors caused by uncorrected perspective distortion in existing quantization methods.

[0006] To achieve the above objectives, the present invention provides the following technical solution: a three-dimensional quantization method for concrete surface spalling based on an RGB-D camera, comprising: Acquire color images and corresponding depth maps of the concrete surface test targets; Pixel registration and alignment are performed on the color image and depth map based on the pre-calibrated camera intrinsic and extrinsic parameter matrices, and the pixels with zero values ​​or no reflection signal in the aligned depth map are marked with hole status. The aligned color image is input into an improved instance segmentation model containing a first branch network and a second branch network, and the output is a damage detection box and a mask. Extract the first two-dimensional response weight map of the first branch network and the second two-dimensional response weight map of the second branch network in the improved instance segmentation model; Extract non-damage candidate regions inside the damage detection box and outside the mask; Combining the first two-dimensional response weight map, the system uses a preset edge isolation threshold to remove transition zone pixels in the non-damage candidate area, and combines the retained pixels with the aligned depth map to generate a three-dimensional non-damage point cloud. Using the second two-dimensional response weight map as the feature confidence, a quadratic polynomial surface fitting is performed on the three-dimensional undamaged point cloud to generate the undamaged reference surface equation. The normal peeling depth of effective pixels within the mask that are not marked with a void state is calculated using the equation of the undamaged reference surface. By combining the normal peeling depth, the normal peeling depth is used to repair the pixels with void status marks in the mask; Calculate the area of ​​the tangent plane corresponding to each pixel in the mask, multiply the area of ​​the tangent plane by the corresponding normal peeling depth and perform discrete integration to accumulate, and calculate the peeling area and volume.

[0007] Furthermore, the steps for acquiring a color image containing the concrete surface test target and the corresponding depth map include: sending a hardware-level synchronous trigger electrical signal to the data acquisition module to capture a three-dimensional tensor format color image containing RGB channels and a single-channel matrix format depth map containing physical depth within the same clock cycle.

[0008] Furthermore, the steps of performing pixel registration and alignment of the color image and depth map based on the pre-calibrated camera intrinsic and extrinsic parameter matrices, and marking the holes in the aligned depth map for pixels with zero values ​​or no reflection signals, include: extracting the initial three-dimensional coordinate sequence of each pixel in the original single-channel depth map, substituting it into the camera extrinsic parameter matrix to perform spatial rigid body transformation, and reprojecting it onto the two-dimensional pixel plane in combination with the camera intrinsic parameter matrix; calculating the approximate depth values ​​of discrete grid coordinate points using a bilinear interpolation algorithm to generate the aligned depth map; determining whether the measured depth value falls within the set sensor physical range; constructing a binary logic state indication function to assign a hole state mark to pixels with zero depth values, not falling within the sensor physical range, or non-digital data; defining discrete missing points with hole state marks; and classifying the two-dimensional spatial coordinates containing the hole state marks into the invalid hole point set.

[0009] Furthermore, the improved instance segmentation model internally deploys a hybrid expert model computation unit. The steps of deploying two parallel feature extraction branch networks within the hybrid expert model computation unit include: calling a deformable convolution operator and introducing a learnable spatial offset matrix to extract the deformation features of irregular spalling boundaries on the concrete surface; calling a basic convolution operator with inference-time linear structure reparameterization properties to extract the underlying concrete texture features of the non-damaged background region; and performing a weighted summation calculation on the independent feature matrices output by the two branch networks through a global attention mechanism to generate a fused feature matrix of the damage detection box and mask for the prediction head to output.

[0010] Furthermore, the steps for extracting the first two-dimensional response weight map of the first branch network and the second two-dimensional response weight map of the second branch network in the improved instance segmentation model include: calling the forward hook function built into the deep learning framework to intercept the first initial three-dimensional feature tensor representing the response intensity of the heterogeneous features at the output of the first branch network and the second initial three-dimensional feature tensor representing the steady-state response intensity of the background texture at the output of the second branch network; performing mean pooling dimensionality reduction operation on the first initial three-dimensional feature tensor and the second initial three-dimensional feature tensor along the feature map channel dimension, and calling the bilinear interpolation algorithm to perform upsampling amplification operation to obtain the first two-dimensional response weight map and the second two-dimensional response weight map.

[0011] Furthermore, the steps of using a system-preset edge isolation threshold to remove transition zone pixels in the non-damage candidate region and combining the retained pixels with the aligned depth map to generate a 3D non-damage point cloud include: extracting the activation value corresponding to each pixel in the non-damage candidate region in the first two-dimensional response weight map; determining pixels with activation values ​​greater than the system-preset edge isolation threshold as transition zone pixels and removing them; the system-preset edge isolation threshold ranges from 0.65 to 0.85; extracting the depth values ​​of the retained valid pixels in the aligned depth map; performing spatial inverse projection calculations in combination with the inverse of the camera intrinsic parameter matrix; and mapping to generate a 3D non-damage point cloud.

[0012] Furthermore, the steps for performing surface fitting on the 3D undamaged point cloud to generate the undamaged reference surface equation include: constructing the undamaged reference surface equation in quadratic polynomial form for the 3D undamaged point cloud; constructing an over-constrained least squares objective function with the goal of minimizing the weighted sum of squared errors of the vertical residuals from the 3D measurement points to the fitted surface; and obtaining the local undamaged reference surface equation by taking the partial derivatives of the coefficients to be determined for each term of the objective function and setting the derivatives to zero.

[0013] Furthermore, the steps for calculating the normal peeling depth of effective pixels without void status markings within the mask using the undamaged reference surface equation include: inversely projecting the effective pixels without void status markings using the camera intrinsic parameter matrix to obtain the spatial X-axis and Y-axis coordinate components of the actual 3D measurement point; substituting the spatial X-axis and Y-axis coordinate components into the undamaged reference surface equation to calculate the 3D coordinates of the coaxial projection theoretical reference point, and obtaining the unit normal vector by differentiation; constructing the spatial displacement vector between the actual 3D measurement point and the theoretical reference point, and performing a dot product projection operation on the spatial displacement vector onto the unit normal vector to obtain the normal peeling depth.

[0014] Furthermore, the steps for normal peeling depth repair of pixels with hole status markers within the mask include: defining a central search neighborhood for each pixel with a hole status marker, extracting the normal peeling depth of the effective pixels already calculated within the search neighborhood; using an inverse distance weighted spatial interpolation algorithm, weighting the depth filling calculation based on the two-dimensional Euclidean distance between the pixel with the hole status marker and each effective pixel; when the calculation finds that the two-dimensional Euclidean distance between the pixel with the hole status marker and a certain effective pixel is zero, the depth value of the effective pixel is directly assigned to the hole status marker to prevent meaningless calculations caused by zero distance.

[0015] Further, the steps for calculating the peeling area and volume include: constructing a unit view vector; calculating the absolute value of the dot product of the unit normal vector and the unit view vector of the undamaged reference surface at the corresponding pixel point as a perspective distortion correction factor; dividing the image projection area micro-element of the corresponding pixel point by the perspective distortion correction factor to obtain the tangent plane area micro-element; and discretely integrating the tangent plane area micro-element of all pixels in the mask to obtain the total peeling area; and multiplying each tangent plane area micro-element with the corresponding normal peeling depth value and discretely integrating to calculate the total peeling volume.

[0016] This invention provides a three-dimensional quantitative method for concrete surface spalling based on an RGB-D camera. It has the following beneficial effects: 1. This invention marks the void state of non-reflective signal pixels in the depth map during the pixel registration and alignment stage. After calculating the normal peeling depth of the effective pixels, it uses an inverse distance weighted spatial interpolation algorithm to fill the depth based on the weights allocated by the two-dimensional Euclidean distance. In this way, it uses the surrounding effective data to infer and repair the local depth loss caused by the physical range limitation of the sensor or the surface reflection characteristics, ensuring the continuity of the input data required for subsequent three-dimensional quantization calculation.

[0017] 2. This invention extracts the two-dimensional response weight maps of the two independent branch networks of the improved instance segmentation model, uses the first two-dimensional response weight map in conjunction with the edge isolation threshold to remove transition zone pixels in the undamaged candidate area, and uses the second two-dimensional response weight map as the feature confidence to perform surface fitting on the retained three-dimensional undamaged point cloud. This separates the boundary deformation from the background texture at the feature level and eliminates the interference of transition zone pixels at the boundary between the damaged and undamaged areas at the physical level, making the constructed undamaged reference surface equation more consistent with the original structural morphology of concrete.

[0018] 3. This invention constructs a unit line-of-sight vector and calculates the absolute value of the dot product between the unit line-of-sight vector and the unit normal vector of the undamaged reference surface equation to obtain the perspective distortion correction factor. At the same time, it uses the actual measurement point displacement to project onto the unit normal vector to obtain the normal spalling depth. Then, in the discrete integration stage, the image projection area micro-element is divided by the perspective distortion correction factor to obtain the tangent plane area micro-element. This simultaneously corrects the two-dimensional area projection error caused by the non-orthogonal shooting angle of the camera and the depth measurement deviation caused by the curvature of the structural surface, thereby improving the final calculation accuracy of the area and volume of the irregular spalling area. Attached Figure Description

[0019] Figure 1 This is a schematic diagram of the timing interaction of the present invention; Figure 2 This is a schematic diagram of the method flow of the present invention; Figure 3 This is a schematic diagram of the timing of data acquisition and depth map registration and alignment interaction in this invention; Figure 4 This is a two-dimensional schematic diagram illustrating the principle of normal peeling depth calculation in this invention; Figure 5 This is a schematic diagram of the surface fitting and three-dimensional quantization calculation logic of the present invention; Figure 6 This is a three-dimensional spatial schematic diagram of the undamaged reference surface equation and normal peeling depth of the present invention. Detailed Implementation

[0020] The technical solutions in 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.

[0021] Please see the appendix Figure 1 This invention provides a three-dimensional quantization system for concrete surface spalling based on an RGB-D camera. The system includes: The data acquisition module uses an RGB-D camera to photograph the concrete surface, simultaneously acquiring color images of the test target and depth maps containing depth information; The processing module communicates with the data acquisition module and is used to receive and process color images and depth maps. It contains a processor and memory. The memory is logically divided into a program instruction storage unit, a model weight storage unit, and a runtime data cache unit. The model weight storage unit non-volatilely stores the network topology configuration and corresponding static weight parameter matrix of the pre-trained improved instance segmentation model. The program instruction storage unit stores the computer-executable logic instructions for feature segmentation, surface fitting, and 3D geometry quantization. The runtime data cache unit temporarily stores the input image data and intermediate feature tensors generated by the network's forward propagation. The improved instance segmentation model includes at least a first branch network for extracting damage boundary deformation features, a second branch network for extracting non-damaged background texture features, and a prediction structure that generates damage detection boxes and damage masks based on the feature outputs of the two branch networks. The processor establishes data interaction with the memory to read logical instructions from the program instruction storage unit, loads the static weight parameter matrix from the model weight storage unit into memory to instantiate and deploy the improved instance segmentation model, and schedules the model and related algorithm modules according to the logical instructions to execute subsequent feature segmentation, surface reconstruction and 3D geometric quantization calculations.

[0022] See attached document Figure 2This invention provides a three-dimensional quantization method for concrete surface spalling based on an RGB-D camera, the method comprising the following steps: S1, acquires a color image and corresponding depth map of the concrete surface test target through the data acquisition module; S2, performs pixel registration and alignment on the color image and depth map based on the pre-calibrated camera intrinsic and extrinsic parameter matrices, and marks the holes in the depth map for pixels with zero values ​​or no reflection signal. S3: Input the aligned color image into the improved instance segmentation model and output the damage detection box and mask; S4, extract the first two-dimensional response weight map of the first branch network and the second two-dimensional response weight map of the second branch network in the improved instance segmentation model; S5, extract the non-damage candidate region inside the damage detection box and outside the mask; S6, using the threshold set by the first two-dimensional response weight map, remove transition zone pixels in the non-damage candidate region, and combine the retained pixels with the depth map to generate a three-dimensional non-damage point cloud. S7. Using the second two-dimensional response weight map as the feature confidence, the three-dimensional undamaged point cloud is fitted with a weighted quadratic polynomial overdetermined least squares method to generate the undamaged reference surface equation. S8, calculates the normal peeling depth of effective pixels within the mask using the equation of the undamaged reference surface; S9 uses an inverse distance weighted spatial interpolation algorithm, combined with the normal peeling depth of effective pixels, to repair the normal peeling depth of pixels with hole state markers. S10: Calculate the tangent plane area micro-element corresponding to each pixel point in the mask, multiply the tangent plane area micro-element with the corresponding normal peeling depth and perform discrete integration to accumulate, and calculate the peeling area and volume.

[0023] Please see the appendix Figure 3 In specific implementations, step S1 provided by the present invention may include the following steps: S11, the processing module sends a hardware-level synchronous trigger signal to the data acquisition module through the communication bus. After receiving the trigger signal, the data acquisition module captures the RGB channel three-dimensional tensor format color image of the concrete test target surface and the single-channel matrix format depth map containing physical depth distance information within the same clock cycle, and outputs color image and depth map data that are consistent on the physical time axis.

[0024] In specific implementations, step S2 provided by this invention may include the following steps: S21, the processing module retrieves the pre-calibrated and stored camera intrinsic parameter matrix containing physical focal length and optical principal point coordinate parameters, and simultaneously retrieves the pre-calibrated camera extrinsic parameter matrix containing rotation and translation vectors. Based on the principle of spatial perspective projection, it extracts the initial three-dimensional coordinate sequence of each pixel in the original single-channel depth map. The processing module substitutes the initial three-dimensional coordinate sequence into the camera extrinsic parameter matrix to perform spatial rigid body transformation, unifying it to the color camera coordinate system. Then, it substitutes it into the camera intrinsic parameter matrix to perform perspective projection operation, reprojecting it onto the two-dimensional pixel plane of the color image. Combining the bilinear interpolation algorithm, it calculates the approximate depth value of each discrete grid coordinate point in the reprojected two-dimensional plane, generating an aligned depth map that is unified with the color image to the same pixel coordinate reference in terms of spatial resolution and coordinate reference.

[0025] S22, the processing module scans the aligned depth map matrix after registration by row, extracts the measured depth value corresponding to each two-dimensional pixel position, and determines whether the measured depth value falls within the set sensor physical range. The set sensor physical range can be dynamically set according to the specific camera hardware model and application scenario. In this embodiment, the set sensor physical range range is from 0.5m to 8.0m. Pixels with depth values ​​of zero, below 0.5m, above 8.0m, or non-digital data are determined as hole pixels, and a hole state mark is assigned to the hole pixels through the binarized logic state indicator function. The corresponding two-dimensional spatial coordinates are assigned to the invalid hole point set.

[0026] The mathematical expression for the depth indicator function that performs binarization tagging during the determination calculation is defined as follows: ; In the formula, This is the feature marker state value output by the depth indicator function. A value of 1 indicates a valid depth pixel, and a value of 0 indicates a pixel with a hole state marker. This is the horizontal column coordinate index of the target detection point within the color image domain; This is the vertical row coordinate index of the target detection point within the color image domain; This refers to the physical depth measurement value of the corresponding coordinates extracted from the aligned depth map matrix; The minimum effective range threshold parameter is set to 0.5m in this embodiment. The maximum effective range threshold parameter is set to 8.0m in this embodiment.

[0027] Please see the appendix Figure 4 In specific implementations, step S3 provided by the present invention may include the following steps: S31, the computational processing module performs pixel resampling and pixel value normalization processing on the registered and aligned color image according to the set network receiving size, and constructs a three-dimensional tensor format color image with width, height and red, green and blue three channels (RGB). In this embodiment, the resolution of the set network receiving size is 640×640. The improved instance segmentation model is an improved network built on the single-stage instance segmentation series network with instance segmentation function known in the art. The computational processing module calls the backbone network of the improved instance segmentation model pre-loaded into the memory to perform downsampling convolution calculations in sequence to obtain a deep feature matrix with macroscopic semantic information and a shallow feature matrix that retains the original physical space details.

[0028] S32, the operation and processing module inputs the deep feature matrix into the dynamic sampling module in the feature pyramid path. The dynamic sampling module calculates the corresponding spatial offset matrix based on the channel value distribution of the input deep feature matrix. The operation and processing module performs deformation upsampling operation based on the spatial offset matrix to amplify the spatial resolution of the deep feature matrix, and then splices and merges the amplified deep feature matrix with the corresponding shallow feature matrix along the channel dimension to form a multi-scale pyramid feature tensor.

[0029] S33, the computational processing module sends the multi-scale pyramid feature tensor to the hybrid expert model computation unit constructed in the deep layers of the network. The hybrid expert model computation unit deploys two parallel feature extraction branch networks: the first branch network calls the deformable convolution operator and introduces a learnable spatial offset matrix to adjust the standard convolution kernel sampling grid to extract the deformation features of irregular spalling boundaries on the concrete surface; the second branch network calls the basic convolution operator with the linear structure reparameterization property during inference, and extracts the underlying concrete texture features of the stable non-damaged background area by equivalently converting the multi-branch structure in the training stage into a single basic convolution operation matrix.

[0030] S34, the computational processing module inputs the independent feature matrices output from the two branch networks into the global attention mechanism calculation module within the hybrid expert model computational unit to generate attention weight coefficients corresponding to each feature channel. The weight calculation process is normalized using a normalized exponent or a sigmoid gating function. The computational processing module uses the calculated attention weight coefficients combined with a nonlinear gating mechanism function to perform a weighted summation calculation on the two independent feature matrices to generate a fused feature matrix. The prediction head of the improved instance segmentation model receives the fused feature matrix, and the detection branch and segmentation branch separated within the prediction head perform damage detection box regression calculation and mask prototype calculation respectively, outputting the damage detection box coordinate parameters corresponding to the test target and an instance segmentation mask representing the pixel region of the damaged target.

[0031] It should be noted that, before executing the inference step, supervised training iterations of the improved instance segmentation model must be completed in advance. The specific training process is as follows: input the concrete damage dataset with manually labeled damage detection box coordinates and instance segmentation pixel labels into the initial model, calculate the cross-union ratio loss between the predicted damage detection box and the real label, and the binary cross-entropy loss used for classification and mask segmentation respectively; then update the weight parameters of each layer of the network through the backpropagation algorithm until the model loss function converges, and finally save the trained model parameters for the computing module to call during actual detection; in this embodiment, the training dataset includes 2000 concrete surface images, where the training set, validation set and test set are divided in an 8:1:1 ratio; the model training uses the AdamW optimizer with an initial learning rate of 0.001, a batch size of 16, 150 training epochs, and weights of detection box loss, classification loss and mask segmentation loss of 1.0, 1.0 and 2.0 respectively.

[0032] In specific implementations, step S4 provided by this invention may include the following steps: S41, during the forward propagation computation graph execution of the improved instance segmentation model, the computation processing module calls the forward hook function built into the deep learning framework to monitor the internal data flow of the hybrid expert model computation unit, intercepts the initial three-dimensional feature tensor representing the response intensity of the boundary heterogeneous features extracted by the forward hook function at the output end of the first branch network, and simultaneously intercepts the initial three-dimensional feature tensor representing the steady-state response intensity of the background texture extracted by the forward hook function at the output end of the second branch network.

[0033] S42, the computation and processing module performs mean pooling dimensionality reduction operations on the two extracted initial three-dimensional feature tensors along the feature map channel dimension to compress and generate two sets of initial two-dimensional single-channel weight matrices; the min-max normalization method is used to normalize the two sets of initial two-dimensional single-channel weight matrices respectively, and a very small positive number is added to the denominator as a stabilizing term to prevent division by zero anomalies when extreme values ​​are equal, so that each response value is within the range of 0 to 1; the computation and processing module calls the bilinear interpolation algorithm to perform upsampling and amplification operations based on pixel spatial distance weighting on the dimensionality-reduced initial two-dimensional single-channel weight matrices, and outputs the response weight map that is restored and expanded in spatial scale.

[0034] S43, the processing module writes the first two-dimensional response weight map and the second two-dimensional response weight map, which have completed the spatial scale restoration operation, into the memory for the subsequent geometric reconstruction module to call the normalized response value in the first two-dimensional response weight map for comparison with the edge isolation threshold; for any retained pixel, the normalized response value of that pixel in the second two-dimensional response weight map is used as the fitting confidence weight of the three-dimensional point formed by the back projection of that pixel; the mathematical calculation expression for the upsampling alignment operation is extracted as follows: ; ; In the formula, This is the first two-dimensional response weighting graph output by the system; This is a two-dimensional spatial upsampling and amplification operation function performed using the bilinear interpolation algorithm; This is the mean pooling dimensionality reduction operation function along the channel dimension; This is a function for extracting intermediate output tensors of a specific network layer from the forward hook function. This is the initial multichannel feature tensor input to the hybrid expert model's computational unit; These are the weight parameters of the deformable convolution operator in the first branch network; This is the second two-dimensional response weighting graph output by the system; These are the weight parameters of the structurally reparameterized convolution operator in the second branch network.

[0035] Please see the appendix Figure 5 In specific implementations, step S5 provided by the present invention may include the following steps: S51, the computation and processing module obtains the coordinates of the damage detection box and the mask of the corresponding concrete surface spalling damage predicted by the improved instance segmentation model; the computation and processing module extracts the set of pixels whose spatial coordinates are inside the boundary of the damage detection box and outside the boundary of the binary mask in the color image domain, and defines the set of pixels obtained by spatial logical difference operation as the non-damage candidate region.

[0036] In specific implementations, step S6 provided by the present invention may include the following steps: S61, the computational processing module traverses each pixel within the non-damaged candidate region and extracts the normalized response value corresponding to each pixel in the first two-dimensional response weight map; the computational processing module determines pixels with normalized response values ​​greater than the system's preset edge isolation threshold as transition zone pixels and removes them from the candidate region; in this embodiment, the system's preset edge isolation threshold ranges from 0.65 to 0.85. The computational processing module extracts the depth values ​​of the retained effective pixels in the aligned depth map and performs spatial inverse projection calculation in conjunction with the inverse matrix of the camera intrinsic parameter matrix to map the two-dimensional effective pixels to generate a three-dimensional non-damaged point cloud set for subsequent surface fitting; the three-dimensional spatial mapping calculation expression is: ; In the formula, The X-axis spatial coordinates of the generated 3D non-destructive point cloud in the camera coordinate system; The Y-axis spatial coordinates of the generated 3D non-destructive point cloud in the camera coordinate system; The Z-axis spatial coordinates of the generated 3D non-destructive point cloud in the camera coordinate system; The actual physical depth measurement value corresponding to the retained valid pixels; The inverse matrix of the camera intrinsic parameter matrix pre-calibrated and determined for the data acquisition module hardware; The horizontal column coordinate index of the retained valid pixels in the color image plane; The vertical row coordinate index of the retained valid pixels in the color image plane.

[0037] In specific implementations, step S7 provided by the present invention may include the following steps: S71, the computational processing module extracts the normalized response values ​​corresponding to the retained effective pixels in the second two-dimensional response weight map, and uses these normalized response values ​​as the fitting confidence weights for the three-dimensional points formed by the inverse projection of the corresponding effective pixels. It then constructs a quadratic polynomial form of the undamaged reference surface equation for the three-dimensional undamaged point cloud set. The computational processing module constructs an over-constrained least squares objective function with the goal of minimizing the weighted sum of squared errors of the vertical residuals from the three-dimensional measurement points to the fitted surface. It constructs a normal equation system by taking the partial derivatives of the coefficients of the objective function and setting the derivatives to zero. The coefficients of the undamaged reference surface equation are obtained by solving the system using matrix inversion or singular value decomposition algorithms. The mathematical expression of the weighted least squares objective function is: ; In the formula, Output the weighted sum of squared errors objective function; An incremental index variable for summing discrete spatial points within a 3D non-damaged point cloud set; The total number of discrete spatial points contained within the three-dimensional non-destructive point cloud set; To extract the corresponding second two-dimensional response weight map The feature confidence of a 3D point; , , , , , The coefficients of the quadratic polynomial undamaged reference surface equation to be solved; For the first X-axis coordinate components of a 3D point; For the first Y-axis coordinate components of a three-dimensional point; For the first The Z-axis coordinate components of a three-dimensional point.

[0038] In specific implementations, step S8 provided by the present invention may include the following steps: S81, the computational processing module extracts the effective pixels within the mask matrix that are not marked as empty states, and inversely projects these effective pixels using the camera intrinsic parameter matrix to obtain the spatial X-axis and Y-axis coordinate components of the actual 3D measurement point. The computational processing module keeps the spatial X-axis and Y-axis coordinate components unchanged, substitutes them into the equation of the undamaged reference surface obtained from the previous solution, calculates the corresponding 3D coordinates of the theoretical reference point for coaxial projection, and uses the derivative of the equation coefficients to obtain the unit normal vector at the theoretical reference point for coaxial projection. The direction of the unit normal vector is uniformly oriented towards the camera projection center; the specific unit normal vector... The calculation formula is: ; In the formula, This is the unit normal vector at the theoretical reference point of coaxial projection; The depth function is the equation of the undamaged reference surface; The X-axis coordinate components of the actual 3D measurement point in the color camera coordinate system; The Y-axis coordinate components of the actual 3D measurement point in the color camera coordinate system; This is the partial derivative of the surface depth function along the X-axis. Let be the partial derivative of the surface depth function along the Y-axis.

[0039] The computational processing module constructs a spatial displacement vector between the actual 3D measurement point and the coaxial projection theoretical reference point. It then performs a dot product projection operation on the spatial displacement vector onto the obtained unit normal vector to obtain the normal peeling depth value of the effective pixel point perpendicular to the undamaged reference surface equation. To avoid negative peeling depth due to measurement noise, the dot product result is truncated to its absolute value or non-negative value. The calculation formula is: ; In the formula, This represents the normal peeling depth value of the effective pixels; This is a function to find the maximum value. The spatial displacement vector from the theoretical reference point of coaxial projection to the actual three-dimensional measurement point; This is the unit normal vector at the theoretical reference point of coaxial projection.

[0040] In specific implementations, step S9 provided by the present invention may include the following steps: S91, the computational processing module, for pixels with hole state markers within the mask matrix, delineates a search neighborhood centered on the pixel within the two-dimensional mask domain, and extracts the normal peeling depth values ​​of the effective pixels already calculated within the search neighborhood. The search neighborhood can be a square or circular neighborhood, with an initial search radius of 3 pixels. When the number of effective pixels in the search neighborhood is less than 5, the search neighborhood is expanded incrementally in steps of 1 pixel until the number of effective pixels reaches a preset number or the search radius reaches 15 pixels. When calculating the distance weight, if the two-dimensional Euclidean distance between the hole to be repaired and an effective pixel is zero, the depth value of the effective pixel is directly assigned to the hole state marker. To prevent division by zero anomalies, a minimum positive stable term is introduced into the distance term in the denominator of the formula. The interpolation repair calculation expression is: ; In the formula, The final normal spalling depth value is calculated for the cavity to be repaired; This is the summation operator; The set of valid pixels contained within the search neighborhood defined around the hole to be repaired; This is the traversal index variable for valid pixels within the search neighborhood; To search the neighborhood of the first The normal peeling depth values ​​for each valid pixel have been calculated and determined; For the cavity point to be repaired and the first The geometric Euclidean distance parameter of each effective pixel in the color image plane; Minimal positive stable terms are introduced to prevent division by zero anomalies; The spatial distance attenuation coefficient set for the system.

[0041] The normal peeling depth of the holed pixel is obtained. Then, based on the coordinates of this point on the color image plane, the coordinates of the theoretical reference point on the reference surface and the unit normal vector are obtained. Then, the approximate value of the physical depth distance is calculated. For subsequent area integral calculations, the inverse calculation formula is: ; In the formula, This is an approximate value of the physical depth distance calculated from the hole pixel. The coordinates of the theoretical reference point on the Z-axis of the camera coordinate system; The final normal spalling depth value is calculated for the cavity to be repaired; This is the unit normal vector at the theoretical reference point on the reference surface corresponding to the void point to be repaired. It is the unit vector along the Z-axis of the camera coordinate system.

[0042] In specific implementations, step S10 provided by the present invention may include the following steps: S101, the computational processing module constructs a unit line-of-sight vector using the camera center coordinates and pixel measurement point coordinates, and calculates the absolute value of the dot product of the unit normal vector and the unit line-of-sight vector at the corresponding pixel point of the undamaged reference surface as the perspective distortion correction factor; the computational processing module divides the image projection area micro-element of the corresponding pixel point by the perspective distortion correction factor after being truncated by the set minimum effective perspective distortion correction factor constraint to obtain the tangent plane area micro-element, and performs discrete integration on the tangent plane area micro-element of all effective pixels and the repair hole point to obtain the total peeling area; the computational processing module multiplies each tangent plane area micro-element with the corresponding normal peeling depth value and performs discrete integration accumulation to obtain the total peeling volume; the mathematical calculation expression is: ; ; ; ; In the formula, The corresponding number obtained after perspective correction The area of ​​the tangent plane at each measuring point is a micro-element; For the first Depth values ​​at each measuring point; This is the lateral focal length in the camera intrinsic parameter matrix; This is the longitudinal focal length in the camera intrinsic parameter matrix; The corresponding first image obtained after perspective distortion correction The area of ​​the tangent plane at each measuring point is a micro-element; The corresponding number calculated based on the pinhole camera model The image projection area of ​​each measurement point is a micro-element; Point the camera projection center to the first Unit line-of-sight vector for each measurement point; The calculated undamaged reference surface in the corresponding first... Unit normal vector at each measurement point; The minimum effective perspective correction factor is set, and in this embodiment, the value range of the minimum effective perspective correction factor is 0.01 to 0.1. The index variable containing measurement points inside the damage mask; Point the camera projection center to the first Unit line-of-sight vector for each measurement point; This is the total area of ​​concrete surface damage and spalling that is ultimately calculated and output. The total number of valid measuring points and interpolated repair voids inside the damage mask; For the corresponding number The area of ​​the tangent plane at each measuring point is a micro-element; The final calculated output is the total volume of concrete surface damage and spalling. For the corresponding number The normal spalling depth values ​​at each measuring point.

[0043] Please see the appendix Figure 6 To aid in understanding the technical solution of this invention, the following is an application example of a three-dimensional quantization method for concrete surface spalling based on an RGB-D camera.

[0044] In a specific application scenario, taking the detection of spalling on the surface of bridge piers as an example, firstly, the data acquisition module takes pictures of the pier surface, simultaneously acquiring color images and corresponding original depth maps; then, the depth map coordinate system is transformed and reprojected onto the color image plane to complete pixel-level registration, the registered depth map is scanned and the areas with missing depth values ​​are marked as void states; the registered color image is input into a pre-trained improved instance segmentation model, which outputs a damage detection box that defines the spalling damage and the corresponding mask.

[0045] During the forward inference stage of the neural network, the system captures the low-level feature tensor and amplifies it to generate a first two-dimensional response weight map and a second two-dimensional response weight map. Based on the spatial logical difference between the damage detection box and the mask, the non-damage candidate region is delineated, and the transition zone pixels in the candidate region are screened out using the first two-dimensional response weight map. Then, the retained non-damage pixels are combined with the depth numerical mapping to generate a three-dimensional non-damage point cloud. The value of the second two-dimensional response weight map is used as the confidence level to perform a quadratic polynomial fitting on the three-dimensional non-damage point cloud to construct the equation of the undamaged reference surface.

[0046] In the quantization calculation stage, the effective measurement points within the mask are inversely projected into three-dimensional space, and the vertical distance from the actual three-dimensional measurement point to the equation of the undamaged reference surface is calculated as the normal peeling depth. For pixels with void markings within the mask, effective measurement points with known depths are searched in the two-dimensional neighborhood, and inverse distance weighted interpolation is performed to complete the depth data. Finally, combining the perspective distortion correction factor calculated from the unit line-of-sight vector and the unit normal vector, the two-dimensional pixel area micro-element is converted into the tangent plane area micro-element. By performing discrete integration and accumulation on the tangent plane area micro-element of all pixels within the mask and the corresponding normal peeling depth, the accurate surface area and volume of the bridge pier peeling damage are obtained.

[0047] While specific embodiments of the present invention have been described above, those skilled in the art should understand that these specific embodiments are merely illustrative. Those skilled in the art can omit, substitute, and modify the details of the methods and systems in various ways without departing from the principles and essence of the present invention. For example, merging method steps to perform substantially the same function in substantially the same way to achieve substantially the same result falls within the scope of the present invention.

Claims

1. A three-dimensional quantization method for concrete surface spalling based on an RGB-D camera, characterized in that, The methods include: Acquire color images and corresponding depth maps of the concrete surface test targets; The color image and the depth map are pixel registered and aligned based on the pre-calibrated camera intrinsic and extrinsic parameter matrices, and the pixels with zero values ​​or no reflection signal in the aligned depth map are marked with a hole state. The aligned color image is input into an improved instance segmentation model containing a first branch network and a second branch network, and the damage detection box and mask are output. Extract the first two-dimensional response weight map of the first branch network and the second two-dimensional response weight map of the second branch network from the improved instance segmentation model; Non-damage candidate regions are extracted inside the damage detection frame and outside the mask. Combining the first two-dimensional response weight map, the transition zone pixels in the non-damaged candidate region are removed using the system's preset edge isolation threshold, and the retained pixels are combined with the aligned depth map to generate a three-dimensional non-damaged point cloud; the second two-dimensional response weight map is used as the feature confidence level to perform quadratic polynomial surface fitting on the three-dimensional non-damaged point cloud to generate an undamaged reference surface equation. The normal peeling depth of the effective pixels within the mask that are not marked with the void state is calculated using the equation of the undamaged reference surface. Based on the normal peeling depth, an inverse distance weighted spatial interpolation algorithm is used to repair the normal peeling depth of the pixels with the hole state markers within the mask; Calculate the area of ​​the tangent plane corresponding to each pixel in the mask, multiply the area of ​​the tangent plane by the corresponding normal peeling depth and perform discrete integration to accumulate, and calculate the peeling area and volume.

2. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The step of performing pixel registration and alignment of the color image and the depth map based on the pre-calibrated camera intrinsic and extrinsic parameter matrices, and marking the holes in the aligned depth map for pixels with zero values ​​or no reflection signals, includes: The initial three-dimensional coordinates of each pixel in the original single-channel depth map are substituted into the camera extrinsic matrix to perform a spatial rigid body transformation, and then combined with the camera intrinsic matrix to reproject it onto the two-dimensional pixel plane of the color image. The depth approximation of discrete grid coordinate points is calculated by combining the bilinear interpolation algorithm to generate the aligned depth map; Determine whether the measured depth value falls within the set sensor physical range. Mark pixels with a depth value of zero, not falling within the sensor physical range, or being non-digital data as void pixels, and assign the corresponding two-dimensional spatial coordinates to the invalid void point set.

3. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The step of inputting the aligned color image into an improved instance segmentation model containing a first branch network and a second branch network, and outputting damage detection boxes and masks includes: The first branch network calls a deformable convolution operator and introduces a learnable spatial offset matrix to extract the deformation features of irregular spalling boundaries on the concrete surface. The second branch network invokes a basic convolution operator with inference-time linear structure reparameterization properties to extract low-level concrete texture features from the non-damaged background region; The improved instance segmentation model also includes a hybrid expert model computation unit, which is equipped with a global attention mechanism computation module. This module performs a weighted summation calculation on the independent feature matrices output by the two branch networks through the global attention mechanism, generating a fusion feature matrix of the damage detection box and the mask for the prediction head to output.

4. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The steps of extracting the first two-dimensional response weight map of the first branch network and the second two-dimensional response weight map of the second branch network in the improved instance segmentation model include: The built-in forward hook function of the deep learning framework is called to intercept the first initial three-dimensional feature tensor representing the response intensity of the boundary heterogeneous features at the output of the first branch network, and the second initial three-dimensional feature tensor representing the steady-state response intensity of the background texture at the output of the second branch network. Mean pooling is performed on the first and second initial three-dimensional feature tensors along the feature map channel dimension to reduce dimensionality. The resulting two-dimensional single-channel response matrix is ​​normalized so that the response values ​​are in the range of 0 to 1. The normalized two-dimensional single-channel response matrix is ​​then upsampled using a bilinear interpolation algorithm to obtain the first two-dimensional response weight map and the second two-dimensional response weight map.

5. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The step of combining the first two-dimensional response weight map, using a system-preset edge isolation threshold to remove transition zone pixels in the non-damaged candidate region, and combining the remaining pixels with the aligned depth map to generate a three-dimensional non-damaged point cloud includes: Extract the normalized response value of each pixel in the non-damage candidate region in the first two-dimensional response weight map, and determine the pixels with normalized response values ​​greater than the system preset edge isolation threshold as transition zone pixels and remove them, where 0.65≤the system preset edge isolation threshold≤0.85; The depth values ​​of the retained valid pixels in the aligned depth map are extracted, and spatial inverse projection calculation is performed in combination with the inverse of the camera intrinsic parameter matrix to generate the three-dimensional non-destructive point cloud.

6. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The steps for performing polynomial surface fitting on the three-dimensional undamaged point cloud to generate an undamaged reference surface equation include: For the aforementioned three-dimensional undamaged point cloud, construct an undamaged reference surface equation in the form of a quadratic polynomial; A constrained least squares objective function is constructed with the goal of minimizing the weighted sum of squared residual errors from the 3D measurement points to the fitted surface along the Z-axis of the camera coordinate system. By taking the partial derivatives of the coefficients to be determined for each term of the objective function and setting the derivatives to zero, the equation of the undamaged reference surface corresponding to the three-dimensional undamaged point cloud is obtained.

7. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The step of calculating the normal peeling depth of effective pixels within the mask that are not assigned the hole state marker using the equation of the undamaged reference surface includes: By combining the camera intrinsic parameter matrix, the effective pixels that were not assigned the hole state mark are back-projected to obtain the X-axis coordinate components and Y-axis coordinate components of the actual three-dimensional measurement points in the color camera coordinate system; Substitute the spatial X-axis and Y-axis coordinate components into the equation of the undamaged reference surface to calculate the three-dimensional coordinates of the coaxial projection theoretical reference point, and obtain the unit normal vector by taking the derivative. Construct a spatial displacement vector between the actual 3D measurement point and the coaxial projection theoretical reference point, and perform a dot product projection operation on the spatial displacement vector onto the unit normal vector to obtain the normal peeling depth.

8. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The step of performing normal peeling depth repair on the pixels with the hole state markers within the mask includes: For a pixel with the hole state marker, a search neighborhood is defined with the pixel as the center, and the normal peeling depth of the effective pixels that have been calculated within the search neighborhood is extracted. An inverse distance weighted spatial interpolation algorithm is used to perform depth filling calculations based on the weights assigned between the pixels marked with the hole state and each effective pixel.

9. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The steps of calculating the area micro-element of the tangent plane corresponding to each pixel point within the mask, multiplying the area micro-element of the tangent plane by the corresponding normal peeling depth, and performing discrete integration and accumulation to calculate the peeling area and volume include: Construct a unit view vector, and calculate the absolute value of the dot product between the unit normal vector of the surface represented by the equation of the undamaged reference surface at each pixel point in the mask and the unit view vector as the perspective distortion correction factor. The larger of the perspective distortion correction factor and the preset minimum perspective distortion correction threshold is determined as the effective perspective distortion correction factor. The image projection area micro-element of each pixel in the mask is divided by the effective perspective distortion correction factor to obtain the tangent plane area micro-element. The tangent plane area micro-element of all pixels in the mask is discretely integrated to obtain the total peeling area. The total spalling volume is obtained by multiplying the area of ​​each tangential plane by the corresponding normal spalling depth and then performing discrete integration and summing.

10. The method for three-dimensional quantification of concrete surface spalling based on an RGB-D camera according to claim 1, characterized in that, The steps of acquiring a color image containing the concrete surface test target and the corresponding depth map include: A hardware-level synchronization trigger electrical signal is sent to the data acquisition module to capture the color image in RGB channel three-dimensional tensor format and the depth map in single-channel matrix format containing physical depth distance information within the same clock cycle.