Road crack segmentation method and device based on deep learning, electronic equipment and program product

By introducing block-level representation, state modeling, and local detail feature fusion into the road crack segmentation method, the problem of insufficient accuracy and robustness of crack segmentation in complex road scenarios is solved, and higher accuracy and stable crack recognition are achieved.

CN121937729BActive Publication Date: 2026-07-03STREAMAP TECHNOLOGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
STREAMAP TECHNOLOGY CO LTD
Filing Date
2026-03-31
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Existing deep learning-based road crack segmentation methods suffer from low segmentation accuracy and robustness in complex road scenarios, especially in the inaccurate identification and characterization of small cracks.

Method used

Two collaborative and complementary processing paths are used to process the image to be segmented in parallel, respectively acquiring global semantic features and local detail features, and then fusing the two to output the crack segmentation result. This includes converting the image into a block-level representation and introducing positional information, performing state modeling, extracting local detail features, and finally generating target fusion features.

Benefits of technology

It improves the accuracy and adaptability of image segmentation results for small cracks, enabling more continuous and clearer crack segmentation in complex environments, and enhancing the detection and characterization of low-contrast and small cracks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121937729B_ABST
    Figure CN121937729B_ABST
Patent Text Reader

Abstract

This application discloses a road crack segmentation method, apparatus, electronic device, and program product based on deep learning. The method employs two collaborative and complementary processing paths to process the image to be segmented in parallel to obtain corresponding feature information: on the one hand, the image to be segmented is converted into a feature sequence containing spatial location information, and global semantic modeling is performed on it to obtain global semantic features characterizing the overall morphology and long-range semantic dependencies of the crack; on the other hand, local texture and edge detail information of the crack is directly extracted from the image to be segmented to obtain detail enhancement features. Subsequently, the global semantic features and detail enhancement features are fused to obtain a target fusion feature that takes into account crack localization, connectivity, and boundary and texture representation. Based on the segmentation result output by the target fusion feature, even tiny cracks can be effectively depicted, thereby improving the continuity, boundary clarity, and robustness of small crack segmentation in complex road backgrounds.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of image processing technology, and in particular relates to a road crack segmentation method based on deep learning, a road crack segmentation device based on deep learning, electronic equipment and computer program products. Background Technology

[0002] Roads inevitably suffer various types of damage during long-term service, among which pavement cracks are one of the most common and significant defects. Cracks reduce road driving quality, accelerate pavement structural deterioration, and pose a potential threat to driving safety. Accurate identification and assessment in the early stages can effectively extend road lifespan and reduce maintenance costs. However, microcracks are difficult to detect in their early stages. Therefore, given my country's rapid urbanization and continuous construction of transportation infrastructure, developing high-precision, high-efficiency automatic road crack detection technology has significant engineering application value.

[0003] Traditional crack detection methods often rely on manual inspections or semi-automatic image processing-based approaches, which suffer from limitations such as low efficiency and significant susceptibility to environmental influences. In recent years, deep learning-based image segmentation algorithms have been widely applied in crack detection, achieving pixel-level extraction of crack regions through end-to-end learning, resulting in a significant improvement in overall performance compared to traditional methods. However, in complex road scenarios, crack morphologies are highly variable and contain a high proportion of fine features, leading to generally low segmentation accuracy and robustness in some existing segmentation methods. Summary of the Invention

[0004] This application provides a road crack segmentation method, a road crack segmentation device, an electronic device, and a computer program product based on deep learning, which can improve the continuity, boundary clarity, and robustness of fine crack segmentation in complex road backgrounds.

[0005] Firstly, this application provides a road crack segmentation method based on deep learning, including:

[0006] The acquired image containing road cracks is converted into a block-level representation, and location information is introduced to obtain a feature sequence.

[0007] State modeling is performed on the feature sequence to obtain global semantic features;

[0008] Extract local detail features from the image to be segmented;

[0009] The global semantic features and the local detail features are fused to obtain the target fusion features;

[0010] Based on the target fusion features, the crack segmentation result corresponding to the image to be segmented is output.

[0011] Secondly, this application provides a road crack segmentation device based on deep learning, comprising:

[0012] The encoding module is used to convert the acquired image containing road cracks into a block-level representation and incorporate location information to obtain a feature sequence;

[0013] The first extraction module is used to perform state modeling on the feature sequence to obtain global semantic features;

[0014] The second extraction module is used to extract local detail features from the image to be segmented;

[0015] The fusion module is used to fuse the global semantic features with the local detail features to obtain the target fused features;

[0016] The segmentation module is used to output the crack segmentation result corresponding to the image to be segmented based on the fusion features.

[0017] Thirdly, this application provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method described in the first aspect.

[0018] Fourthly, this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the method described in the first aspect above.

[0019] Fifthly, this application provides a computer program product comprising a computer program that, when executed by one or more processors, implements the steps of the method described in the first aspect.

[0020] The advantages of this application compared to existing technologies are as follows: First, it converts the image to be segmented containing road cracks into a block-level representation and introduces location information to form a feature sequence. This reduces computational redundancy while preserving the spatial relationships between blocks, providing a foundation for a holistic understanding of the crack's direction, connectivity, and morphological structure. Second, it performs state modeling on this feature sequence, which can aggregate contextual information and capture long-range dependencies over a larger scope. This enhances the ability to distinguish between cracked and non-cracked regions in complex backgrounds (such as uneven lighting, stains, and texture interference), resulting in a more globally consistent semantic representation. Simultaneously, it directly extracts local features from the original image to be segmented. Detailed features help preserve the high-frequency texture and edge information of tiny cracks, compensating for problems such as crack breakage and blurred boundaries that may occur when relying solely on global semantics. On this basis, fusing global semantic features with local detailed features enables the target fusion features to simultaneously possess the ability of "global localization and connectivity judgment" and "local boundary and texture characterization," which improves both the integrity of the crack region and the contour accuracy. Finally, the segmentation results output based on the target fusion features can achieve more continuous and clearer crack segmentation in complex real road environments, and also have better detection and characterization effects for low-contrast and small cracks, thereby improving the overall segmentation accuracy and robustness.

[0021] It is understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant descriptions in the first aspect mentioned above, and will not be repeated here. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 This is a flowchart illustrating the road crack segmentation method based on deep learning provided in an embodiment of this application;

[0024] Figure 2 This is a schematic diagram of two-dimensional multi-directional scanning provided in an embodiment of this application;

[0025] Figure 3 This is a schematic diagram of the GAVM module structure provided in an embodiment of this application;

[0026] Figure 4 This is a schematic diagram of the lightweight gated convolution structure provided in an embodiment of this application;

[0027] Figure 5This is a schematic diagram of the network structure of the road crack segmentation model provided in the embodiments of this application;

[0028] Figure 6 This is a schematic diagram of the road crack segmentation device based on deep learning provided in an embodiment of this application;

[0029] Figure 7 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Detailed Implementation

[0030] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.

[0031] In complex road scenarios, cracks have varied shapes and a high proportion of fine features, which leads to low segmentation accuracy and robustness in some existing segmentation methods.

[0032] To address the aforementioned issues, this application proposes a deep learning-based method for road crack segmentation. This method employs two collaborative and complementary processing paths to process the image to be segmented in parallel, acquiring global semantic features and local detail features respectively. These two paths are then fused to output the crack segmentation result, thereby improving the accuracy and adaptability of the segmentation results for small cracks.

[0033] The deep learning-based road crack segmentation method provided in this application can be applied to electronic devices such as mobile phones, tablets, in-vehicle devices, augmented reality (AR) / virtual reality (VR) devices, laptops, ultra-mobile personal computers (UMPCs), netbooks, and personal digital assistants (PDAs). This application does not impose any restrictions on the specific type of electronic device.

[0034] To illustrate the technical solutions proposed in this application, the following description will use an electronic device as the execution subject to illustrate various embodiments.

[0035] Figure 1 A schematic flowchart of the deep learning-based road crack segmentation method provided in this application is shown. The deep learning-based road crack segmentation method includes:

[0036] Step 110: The electronic device converts the acquired image containing road cracks into a block-level representation and incorporates location information to obtain a feature sequence.

[0037] To effectively capture the overall morphological features of road cracks and the long-range semantic dependencies between different regions in the subsequent state modeling process, the acquired image to be segmented can first be converted into a block-level representation. Specifically, the electronic device can divide the image to be segmented into multiple image blocks using patch embedding, and map each image block to a corresponding feature vector, thereby converting the original two-dimensional image data into a serialized representation composed of features from multiple image blocks. In this way, the image can be divided into multiple basic feature units containing local semantic information, enabling the subsequent state modeling process to uniformly model the semantic relationships between different image regions at a higher level. This is more conducive to capturing the overall structural features of road cracks in the image and their long-range dependencies.

[0038] However, after dividing an image into multiple image patches and constructing a feature sequence, the two-dimensional spatial adjacency relationship between adjacent regions in the original image is no longer explicitly expressed in the sequence representation. This may lead to difficulties in directly perceiving the spatial distribution relationship between different image patches and the continuity features of local structures when performing sequence modeling. Especially for structures like road cracks, which are elongated and directionally continuous, relying solely on sequence features may be insufficient to fully characterize their spatial extension morphology. Therefore, after obtaining block-level feature representations, electronic devices can introduce positional information encoding into the feature vectors corresponding to each image patch to represent the spatial positional relationship of each image patch in the original image. This allows the feature sequence to simultaneously include both semantic and spatial positional information of the image patches during subsequent state modeling.

[0039] Based on the introduced location information encoding, when modeling the state of feature sequences, the model can not only learn the semantic relationships between different image patches, but also perceive the spatial distribution of each image patch in the image, thereby establishing a more reasonable semantic relationship structure globally. In this way, the spatial extension morphology and overall distribution characteristics of road cracks in images can be captured more effectively, thus obtaining feature representations containing global semantic information. This provides a more sufficient feature foundation for the subsequent generation of crack segmentation results, thereby improving the accuracy and stability of crack segmentation.

[0040] Step 120: The electronic device performs state modeling on the feature sequence to obtain global semantic features.

[0041] After obtaining the feature sequence, the electronic device can perform state modeling on the feature sequence to establish contextual relationships between features of different image patches. State modeling refers to the sequential dynamic modeling of the input feature sequence, enabling the model to comprehensively utilize feature information from other locations in the sequence when processing the current feature element, thereby forming a global representation of the overall structure of the sequence. Through state modeling, contextual dependencies between different image patches can be established in the feature sequence, allowing the model to capture long-distance semantic associations between different regions of the image, thus obtaining feature representations containing global semantic information.

[0042] In some embodiments, state modeling can be implemented using a State Space Model (SSM). A State Space Model is a modeling approach used to describe the dynamic evolution of sequence data. It constructs latent state variables and recursively updates these latent states based on the input sequence, thereby gradually aggregating historical information along the sequence dimension. This allows the model to establish dependencies between features over a longer period. In this way, long-range dependencies between image patch features can be effectively modeled, leading to a global semantic understanding of the overall image structure.

[0043] In some embodiments, a sequence modeling structure based on Visual Mamba can be used to model the state of the feature sequence. Visual Mamba introduces a selective state space mechanism to dynamically update the state of the input feature sequence, enabling the model to effectively capture long-distance dependencies while maintaining low computational complexity. During state modeling of the feature sequence, the feature vectors corresponding to each image patch can be sequentially input into the state space model. Through the state update process, sequence context information is gradually fused to obtain a feature representation containing global semantic information. This state modeling process enhances the model's ability to express the overall morphological structure of road cracks and cross-regional correlation features, thus providing more comprehensive semantic feature support for subsequent crack segmentation.

[0044] Step 130: The electronic device extracts local detail features from the image to be segmented.

[0045] In addition to extracting global semantic features from the image to be segmented through steps 110-120, local detail features can also be extracted from the image to be segmented. Since road cracks typically exhibit long, thin, and irregularly shaped structures, relying solely on global semantic information may not accurately depict the edge details and local morphology of the cracks. Therefore, electronic devices also perform local feature extraction on the image to be segmented to obtain detailed features containing edge information, texture information, or local structural information. This enhances the ability to express the fine-grained structure and boundary features of the cracks, providing richer feature information for subsequent accurate segmentation of the crack region.

[0046] Step 140: The electronic device fuses global semantic features with local detail features to obtain target fused features.

[0047] To enhance the identification of crack boundaries and fine cracks while maintaining the overall structural consistency of the cracks, electronic devices can fuse the aforementioned global semantic features and local detail features. For example, electronic devices can integrate feature information representing the overall semantic relationships of the image with feature information representing local edges, textures, and structural details through feature splicing, feature weighting, or other feature fusion methods, thereby forming a fused feature representation that simultaneously contains macroscopic semantic information and microscopic structural information. This fusion of the two features not only allows the global semantic information to depict the overall distribution of cracks in the image but also enhances the expression of crack boundaries and fine crack structures through local detail features, thus improving the precision of crack region identification.

[0048] Step 150: The electronic device outputs the crack segmentation result corresponding to the image to be segmented based on the target fusion features.

[0049] After obtaining the target fusion features, the electronic device can predict the probability that each pixel in the image belongs to a crack region based on these features, and generate a corresponding crack segmentation map based on the prediction results. Thus, the electronic device can automatically identify and locate road crack regions at the pixel level, thereby obtaining the final crack segmentation result.

[0050] In this embodiment, the electronic device first converts the image to be segmented into a block-level feature representation and introduces location information encoding to construct a feature sequence with spatial location information. Then, through state modeling, it establishes contextual relationships between different image regions, thereby extracting global semantic features that reflect the overall structure of the image. Simultaneously, it extracts local detail features from the image to enhance the expression of crack edges, textures, and fine structures. Based on this, it fuses the global semantic features and local detail features to form a fused feature representation that simultaneously contains macroscopic semantic information and microscopic structural information, and predicts the probability that each pixel in the image belongs to a crack region. Through this process, while maintaining the overall structural consistency of the crack, it can improve the recognition ability of fine cracks and boundary regions, thereby achieving accurate segmentation and pixel-level localization of road crack regions.

[0051] In some embodiments, in order to fully capture the overall morphological features of road cracks and the long-range semantic dependencies between different regions, state modeling is performed on the feature sequence to obtain global semantic features, including:

[0052] Step A1: The electronic device performs gated modulation and convolution fusion operations on the feature sequence to obtain gated convolution features.

[0053] The electronic device first performs a gating modulation operation on the input feature sequence. Through the gating mechanism, the feature channels or spatial positions are selectively adjusted so that the response related to the target structure is enhanced, while redundant or interfering information is suppressed. Then, combined with the convolution fusion operation, the local context information between adjacent feature units is aggregated to obtain gating convolution features containing related information.

[0054] This process can preserve key semantic information in the original features and enhance the correlation between different local regions within the global region.

[0055] For example, in a road crack scenario, gating mechanisms can enhance the response of the crack edge region, while convolution operations help capture the continuous texture structure around the crack, thus providing a more stable feature basis for subsequent feature modeling.

[0056] Step A2: The electronic device sequentially performs feature expansion mapping and nonlinear activation operations on the gated convolutional features to obtain the first intermediate features.

[0057] Electronic devices first perform feature expansion mapping operations, such as linear mapping or channel expansion, to map the original features to a higher-dimensional feature space to increase the feature representation capacity. Subsequently, nonlinear activation (e.g., SiLu) operations are used to introduce nonlinear expressive capabilities, enabling the expression of more complex semantic relationships. Thus, electronic devices can effectively improve the discriminative power of feature representations. For example, in crack detection tasks, expansion mapping can increase the dimension of expression for fine-grained structural features, while nonlinear activation functions can enhance the ability to characterize complex crack morphological changes, thereby obtaining the first intermediate feature.

[0058] Step A3: The electronic device performs a two-dimensional multi-directional scanning modeling operation on the first intermediate feature to obtain the multi-directional scanning modeling feature.

[0059] The electronic device performs a two-dimensional multi-directional scanning modeling operation on the first intermediate feature. By sequentially scanning the feature in multiple directions and updating its state, the model can capture long-distance dependencies in different spatial directions. Compared to modeling in only a single direction, multi-directional scanning can simultaneously consider contextual information in horizontal, vertical, or other directions, thus obtaining a more comprehensive spatial relational structure. For example, in a road crack scenario, cracks often extend in different directions. Multi-directional scanning modeling can better capture the continuous structure of the crack in different directions, thus obtaining multi-directional scanning modeling features.

[0060] For example, such as Figure 2As shown, two-dimensional multi-directional scanning can include two parallel serpentine scanning paths and two diagonal serpentine scanning paths. By performing sequential scanning modeling of features along different directions, the ability to model the structural relationships in different directions in the image is enhanced.

[0061] Step A4: The electronic device performs element-wise multiplication of the first intermediate feature and the multi-directional scanning modeling feature to obtain the gated fusion feature.

[0062] The electronic device performs element-wise multiplication of the first intermediate feature with the multi-directional scan modeling feature, allowing the contextual information obtained from the multi-directional scan modeling to selectively modulate the original feature. Through element-wise gated fusion, the electronic device can dynamically adjust the feature response according to the semantic importance of different positions, further enhancing regions related to the target structure while suppressing irrelevant regions, thus obtaining gated fused features.

[0063] Step A5: The electronic device performs pixel-level weighted fusion on the gated convolutional features and the scale-aligned gated fusion features to obtain attention-based fusion features.

[0064] Electronic devices employ pixel-level weighted fusion of gated convolutional features and scale-aligned gated fusion features, enabling fine spatial alignment and weighted integration of feature information from different sources. This allows for the simultaneous utilization of detailed information contained in local convolutional features and global contextual information contained in multi-directional modeling features, resulting in attention-based fusion features. For example, in crack segmentation tasks, the generation of attention-based fusion features can enhance the consistency of the overall crack structure while preserving fine crack boundary information.

[0065] Step A6: The electronic device performs a feature alignment transformation operation on the attention fusion features to obtain normalized features.

[0066] Electronic devices perform feature alignment transformation operations on attention fusion features, such as adjusting the feature distribution through normalization or scaling transformation, so that the feature values ​​in different channels or spatial locations are in a relatively stable distribution range, thereby reducing the instability caused by the difference in feature distribution and making the subsequent feature integration and prediction process more stable, thus obtaining normalized features.

[0067] Step A7: The electronic device concatenates the attention fusion features and the normalized features to obtain global semantic features.

[0068] Electronic devices concatenate attention fusion features with normalized features, enabling the model to simultaneously retain the rich semantic information in the original fusion features as well as the stable feature representation after alignment transformation, thereby improving the integrity of feature expression and obtaining global semantic features for subsequent task processing.

[0069] In this embodiment, the electronic device enhances the semantic representation capabilities of different localities through gated modulation and convolutional fusion, improves the feature representation dimension through feature expansion and nonlinear mapping, establishes long-distance spatial dependencies through two-dimensional multi-directional scanning modeling, and achieves dynamic fusion of multi-level features by combining gating mechanisms and attention guidance. Simultaneously, feature alignment and stitching further stabilize and enrich the feature representation, thereby forming a global semantic feature that simultaneously contains local detail information and global contextual information. Based on this feature representation, the overall structure and detailed boundaries of road cracks in images can be more accurately depicted, thereby improving the accuracy and robustness of subsequent crack segmentation tasks.

[0070] In some embodiments, the road crack segmentation method described above can be implemented using a pre-trained deep learning segmentation model. The segmentation model can be used to extract features, model semantics, and predict crack regions from the input road image.

[0071] In some embodiments, steps A1 to A7 can be executed N times on the feature sequence, where the input feature of the initial loop is the feature sequence, and the input feature of subsequent loops is the global semantic feature output from the previous loop. Through this progressive feature update method, each loop further expands the semantic perception range of the features based on the previous feature representation, thereby gradually obtaining global information at different semantic scales. Therefore, the global semantic feature output in each loop can correspond to a global semantic representation at one scale, and after multiple loops, a feature representation containing multi-scale global semantic information can be formed. Therefore, fusing global semantic features with local detail features yields the target fused feature, including:

[0072] Step B1: The electronic device sequentially performs linear transformation and dynamic upsampling operations on the semantic features of each scale to obtain the upsampled semantic features corresponding to each scale.

[0073] The electronic device first performs a linear transformation on the semantic features at each scale, and adjusts the feature dimensions through channel mapping or feature projection operations to make the semantic features at different scales have a consistent or compatible expression in the feature space. Then, it performs a dynamic upsampling operation on the linearly transformed features to gradually restore the low-resolution semantic features to a higher spatial resolution, thereby obtaining a spatial scale that matches the local detail features, so as to restore the spatial details of the features while maintaining high-level semantic information.

[0074] Dynamic upsampling refers to applying upsampling operations at corresponding magnifications to features at different scales based on their spatial resolution differences, gradually restoring them to a unified or target spatial scale. This approach allows for spatial alignment between features at different scales while preserving high-level semantic information, thus providing a consistent spatial foundation for subsequent multi-scale feature fusion.

[0075] For example, for high-level semantic features with low resolution, a larger upsampling rate can be used to restore their spatial resolution; while for semantic features with relatively high resolution, a smaller upsampling rate is used for scale adjustment. This on-demand upsampling method can reduce unnecessary interpolation errors while ensuring feature space alignment, thereby more effectively preserving multi-scale semantic information and improving the expressive power of subsequent fused features.

[0076] Step B2: The electronic device concatenates the upsampled semantic features at each scale with the local detail features to obtain cascaded concatenated features.

[0077] Electronic devices concatenate upsampled semantic features at various scales with local detail features, enabling the integration of information from different semantic levels within the same feature space. Upsampled semantic features primarily contain global semantic structural information of the image, while local detail features include fine-grained information such as edges, textures, and local morphology. Therefore, through feature concatenation, global semantic information and local structural information can be jointly expressed while maintaining the integrity of various types of information.

[0078] For example, in crack recognition tasks, global semantic features help identify the overall extension direction of cracks, while local detail features help characterize crack edges and fine branch structures. Combining the two can form a more complete feature description, thus obtaining cascaded spliced ​​features.

[0079] Step B3: The electronic device performs gated modulation and convolutional fusion operations on the cascaded splicing features to obtain the target fused features.

[0080] Electronic devices perform gated modulation and convolutional fusion operations on cascaded spliced ​​features. The gated modulation mechanism dynamically adjusts the weights of different channels or spatial regions based on feature importance, strengthening features relevant to the target structure while suppressing irrelevant or redundant information. The convolutional fusion operation locally aggregates features from adjacent regions, further enhancing the spatial correlation between features. In this way, stronger semantic connections can be formed between multi-source features, resulting in more stable and discriminative fused features.

[0081] For example, in crack segmentation tasks, this step can enhance the continuous response of crack regions while suppressing interference from road textures or noise, thereby obtaining target fusion features.

[0082] In this embodiment, the electronic device achieves spatial alignment of semantic information at different scales by linearly mapping and dynamically upsampling multi-scale semantic features. Subsequently, feature concatenation is used to jointly express multi-scale semantic information and local detail information. Furthermore, gated modulation and convolutional fusion are used to further optimize the correlation between multi-source features, thereby forming a target fusion feature that simultaneously contains global structural information and local detail information. Based on this fusion feature, the overall distribution and fine boundary structure of road cracks in the image can be more accurately depicted, thus providing more sufficient and stable feature support for subsequent accurate segmentation of crack regions.

[0083] In some embodiments, the gating mechanism provides dynamic features for each spatial location and channel, enhancing the model's ability to capture details. To further reduce the number of parameters and computational cost, a bottleneck convolution with a low-rank approximation is introduced in the gating modulation and convolution fusion operation performed on the feature sequence or concatenated features. This maps the matrix from a high-dimensional space to a low-dimensional space, significantly reducing computational complexity. Specifically, the gating modulation and convolution fusion operation is performed on any feature to be processed in the feature sequence or concatenated features, including:

[0084] Step C1: The electronic device performs feature transformation processing on the feature to be processed to obtain the first enhanced feature.

[0085] Electronic devices perform feature transformation operations on the features to be processed, such as bottleneck convolution, normalization, and linear activation, to perform low-rank mapping and distribution adjustment on the original features, thereby obtaining the first enhanced features. Among them, bottleneck convolution maps high-dimensional features to a lower-dimensional feature space before feature calculation, which can significantly reduce the number of parameters and computational cost while preserving the main semantic information.

[0086] For example, in road crack images, the original features may contain a lot of information related to the background texture. Bottleneck convolution can compress redundant feature dimensions, making key features related to crack edges or texture changes more prominent, thus providing a higher quality feature base for subsequent fusion.

[0087] Step C2: The electronic device performs feature transformation processing on the first enhanced feature to obtain the second enhanced feature.

[0088] The electronic device performs feature transformation processing on the first enhanced feature again to obtain the second enhanced feature. Through continuous feature transformation, semantic information can be reorganized in different feature subspaces, enabling the model to obtain multiple complementary feature representations.

[0089] For example, one set of features might focus more on describing the shape and contour of the crack, while another set might be more sensitive to the texture differences between the crack edge and the road background. Through successive feature transformations, richer candidate information can be provided for subsequent gating modulation.

[0090] Step C3: The electronic device dynamically gates and modulates the first enhancement feature and the second enhancement feature to obtain the initial fused feature.

[0091] The electronic device dynamically gates and modulates the first and second enhancement features, weighting the feature responses according to the importance of different spatial locations and channels to obtain the initial fused features. This gating mechanism can dynamically select more important feature responses in different regions, enabling the electronic device to focus on discriminative regions when processing complex images.

[0092] Step C4: The electronic device concatenates the feature to be processed with the initial fusion feature that has undergone feature transformation processing to obtain the fusion feature corresponding to the feature to be processed.

[0093] In the crack identification process, the original features can provide information on the overall road structure, while the gated fusion features highlight the important responses in the crack area. The electronic device splices the features to be processed with the initial fusion features after feature transformation, so that the original feature information and the enhanced features after gate modulation can be jointly expressed in the same feature representation. This allows the key features after gate screening to be introduced while retaining the complete semantic information of the original features, thus forming richer and more stable fusion features.

[0094] In this embodiment, the electronic device achieves low-rank feature mapping through bottleneck convolution to reduce computational complexity, and combines normalization and activation operations to improve the stability of feature representation. Subsequently, enhanced features with complementary semantic information are generated through multiple feature transformations, and a dynamic gating mechanism is used to adaptively modulate important features at different spatial locations and channels. Finally, the original features and the gated fusion features are integrated through feature concatenation, thereby obtaining a fused feature representation that combines rich semantic information with high discriminative power. This fusion process can enhance the ability to express fine-grained structural features while ensuring computational efficiency, enabling the electronic device to more accurately capture detailed changes in the image, thereby improving the accuracy and robustness of subsequent road crack segmentation.

[0095] In some embodiments, in order to obtain detailed features containing edge information, texture information, or local structural information, and to enhance the ability to express fine-grained structure and boundary features of cracks, the electronic device extracts local detailed features from the image to be segmented, including:

[0096] Step D1: The electronic device performs channel compression on the image to be segmented to obtain the second intermediate feature.

[0097] Electronic devices first perform channel compression on the image to be segmented, such as through convolutional mapping or linear transformation, to reduce the number of feature channels, thus mapping the feature representation from a high-dimensional space to a lower-dimensional space, thereby obtaining a second intermediate feature. Channel compression can reduce redundant information and computational overhead, and can enhance the expression of key features while preserving the main structural information. For example, in a road crack scene, the original image may contain a lot of road surface texture and background information. Channel compression can weaken irrelevant texture features to a certain extent, making features related to the crack structure more prominent.

[0098] Step D2: The electronic device performs multi-scale feature extraction and splicing operations on the second intermediate feature to obtain multi-scale intermediate features.

[0099] Electronic devices perform multi-scale feature extraction operations on the second intermediate features, such as using convolutions with different receptive fields or feature extraction units of different scales, to obtain feature representations at multiple scales. These scale features are then concatenated to form multi-scale intermediate features containing multi-scale information, enabling the simultaneous capture of structural information across different spatial ranges. For example, in crack detection tasks, small-scale features help capture fine cracks and edge details, while large-scale features reflect the overall extension morphology of the crack. Multi-scale concatenation can form a more complete feature description.

[0100] Step D3: The electronic device extracts edge features from the second intermediate features.

[0101] Electronic devices extract edge features from the second intermediate features, highlighting structural boundary information in the image through edge detection or gradient-sensitive feature extraction. Since road cracks typically appear as elongated structures with significant brightness or texture variations, extracting edge features can more accurately characterize the crack's boundary location and morphology. For example, in road images, crack edges often exhibit a clear grayscale difference from the surrounding road surface; edge feature extraction can effectively enhance this structural difference.

[0102] Step D4: The electronic device splices the edge features with the multi-scale intermediate features to obtain deep fusion features.

[0103] The electronic device concatenates extracted edge features with multi-scale intermediate features to obtain deep fusion features. This fusion method allows for the joint expression of edge features reflecting local boundary information with feature representations containing multi-scale semantic information. This enables the electronic device to utilize overall semantic information while maintaining sensitivity to subtle boundaries when identifying crack structures. For example, in crack identification, multi-scale features describe the overall crack direction, while edge features highlight the crack outline; combining the two improves the accuracy of crack region localization.

[0104] Step D5: The electronic device performs two residual optimization processes on the deep fusion features and performs channel expansion on the optimized deep fusion features to obtain local detail features.

[0105] Electronic devices perform two residual optimization processes on deeply fused features. The features are progressively updated through the residual structure, continuously introducing new semantic expressions while retaining the original information, thereby improving the stability and discriminative ability of the feature representation. Subsequently, channel expansion is performed on the optimized features, mapping them to a higher-dimensional feature space, thus enhancing the ability to express complex and detailed structures, ultimately yielding local detail features. In crack segmentation tasks, residual optimization can further enhance the response of crack boundary regions, while channel expansion can increase the expressive dimension of different crack morphological features.

[0106] In this embodiment, the electronic device reduces redundant information and improves computational efficiency through channel compression. Based on this, it utilizes multi-scale feature extraction to obtain structural information within different spatial ranges. Simultaneously, it enhances crack boundary representation through edge feature extraction and achieves deep fusion of multi-source structural information through feature stitching. Subsequently, residual optimization improves the stability of feature representation, and channel expansion enhances the representation capability of fine-grained structures, thereby obtaining local detail features containing rich local structural information. This process can more accurately characterize the fine structure and boundary morphology of road cracks, providing more sufficient detailed feature support for subsequent accurate segmentation of crack areas, thus improving the overall segmentation effect and robustness.

[0107] In some embodiments, in order to accurately extract edge features from the second intermediate features, the method includes:

[0108] Step E1: The electronic device performs a convolution operation on each channel of the second intermediate feature based on the convolution kernel of the preset four-neighbor Laplacian edge detection operator to obtain the edge response corresponding to each channel.

[0109] The electronic device performs a convolution operation on each channel of the second intermediate feature based on a pre-defined four-neighbor Laplacian edge detection operator kernel, thereby calculating the edge response of the corresponding channel. This operation can highlight regions where the feature shows significant changes in grayscale or activation values ​​in space, thus detecting potential boundaries or texture structures. Through the design of the Laplacian operator in the convolution kernel, it can effectively respond to rapidly changing local regions in the feature, such as the edge pixels of road cracks or subtle texture changes. That is, by directly capturing the edge information of the image at the feature level, rather than relying solely on the raw pixel gradients of the input image, the model's sensitivity to fine structures is enhanced, while avoiding the noise interference that may occur with simple pixel-level edge detection.

[0110] For example, a four-neighbor Laplacian convolution kernel is a two-dimensional convolution operator used to detect regions where pixel values ​​change rapidly in an image or feature map. This kernel is typically a 3×3 matrix, with its center element being a positive value, such as 4, and its four neighboring elements (top, bottom, left, and right) having equal negative values, such as - l (- l For specific weight values, l =1) ; The remaining corner elements are zero, thus forming a second derivative response in the horizontal and vertical directions.

[0111] In the convolution operation, the convolution kernel performs a weighted summation operation on each pixel of the input feature map and its neighborhood, highlighting the intensity change of the center pixel relative to its neighbors above, below, left, and right, thereby generating edge responses. Its advantage lies in its ability to quickly detect local boundaries and detailed structures at the feature level, capturing significant gradient changes without additional orientation information, such as the contours of road cracks or subtle texture variations.

[0112] Step E2: The electronic device combines the edge responses of each channel to obtain edge features.

[0113] Electronic devices can integrate the edge responses of various channels to form a unified edge feature. This can be achieved by combining the edge responses of each channel through methods such as channel concatenation, weighted summation, or max pooling, thus merging the responses of each channel to local boundaries into a unified edge feature. This operation maintains the independence of the feature responses of each channel while obtaining a comprehensive edge representation, thereby more accurately describing the spatial location and morphological features of fine-grained structures in the image.

[0114] For example, in road crack detection, different channels may be sensitive to the edge response of cracks in different directions or widths. By combining the responses of each channel, a more complete representation of the crack edge can be formed.

[0115] In this embodiment, the electronic device first captures rapidly changing local regions at the feature level through four-neighbor Laplacian convolution, and then integrates the edge responses of each channel into a unified edge feature. This process enhances the model's sensitivity to minute structures and boundary information in the image, providing accurate edge feature support for subsequent feature fusion or crack segmentation, thereby improving detail rendering capabilities and overall segmentation accuracy.

[0116] In some embodiments, the road crack segmentation method described above can be implemented using a pre-trained deep learning segmentation model. This segmentation model can perform detailed feature extraction, global semantic modeling, feature fusion, and segmentation of crack regions on the input image to be segmented.

[0117] In some embodiments, the road crack segmentation method described above can be implemented using a pre-trained segmentation model. For example, this segmentation model may include a semantic feature extraction branch, a detail feature extraction branch, and a dual-branch fusion segmentation head (DFSH) for fusing the features from the two branches to generate the segmentation result.

[0118] The semantic feature extraction branch is used to extract global semantic features from the image to be segmented that reflect the overall structural relationships of the image. For example, this branch may include a patch embedding module for converting the input image into a block-level representation, a position embedding module for introducing spatial location information into the block-level features, and a semantic modeling structure for contextual modeling of the feature sequence. The patch embedding module divides the image to be segmented into multiple image patches and maps each image patch to a corresponding feature vector, thus forming a feature sequence. The position embedding module introduces location information into the features of each image patch, enabling the model to perceive the spatial distribution relationships between image patches during sequence modeling. The semantic modeling structure can be built based on a state space model (SSM) or a visual Mamba architecture. Through the state modeling process, it establishes contextual dependencies between different image patches in the feature sequence, thereby capturing long-distance semantic associations between different regions of the image and obtaining feature representations containing global semantic information.

[0119] The detail feature extraction branch is used to extract local structural information from the image to be segmented, thereby enhancing the model's ability to perceive crack boundaries, fine cracks, and texture variations. For example, this branch can extract detailed features containing edge information, texture information, and local structural information from the image through multi-scale feature extraction structures, edge feature extraction structures, or convolutional feature extraction structures, thus providing a high-resolution feature foundation for subsequent fine segmentation of crack regions.

[0120] The dual-branch fusion segmentation head receives global semantic features from the semantic feature extraction branch and local detail features from the detail feature extraction branch, and fuses these two types of features to generate the final crack segmentation result. For example, the dual-branch fusion segmentation head can integrate global semantic information with local detail information through feature concatenation, weighted fusion, attention-guided fusion, or gated fusion, enabling the model to enhance its ability to identify crack boundaries and fine cracks while maintaining the overall structural consistency of the crack.

[0121] It should be noted that, in some implementations, the semantic feature extraction branch, the detail feature extraction branch, and the dual-branch fusion segmentation head can be used to implement the global semantic feature extraction process, the local detail feature extraction process, and the feature fusion and segmentation prediction process in the aforementioned method steps, respectively. However, this application does not limit the specific network structure of the segmentation model; any model structure that can implement the above feature extraction and fusion processing can be applied to the method of this application.

[0122] In some embodiments, to reduce parameter size and computational overhead while maintaining high semantic understanding capabilities, a lightweight state space model (Lightweight SSM) can be introduced into the semantic modeling structure. This structure can be built upon the Selective State Space Model (VSS) in Vision Mamba, and adaptively improved to incorporate the characteristics of slender structures, irregular shapes, and strong directional continuity in road crack segmentation tasks, thus forming a Generalized Adjacent Visual Mamba (GAVM) module. This structure allows the semantic modeling process to capture long-distance dependencies while better perceiving the spatial extension and directional continuity of crack structures, thereby enhancing the ability to express complex crack morphologies.

[0123] For example, see Figure 3 , Figure 3A GAVM module structure is illustrated. This module may include two lightweight gated bottleneck convolutional structures stacked together, parallel multi-directional scanning modeling paths and independent gated paths, a gated fusion layer, a feature compression mapping layer, a pixel-level weighted guided fusion layer (PAF), a normalization layer (e.g., a GN layer), a feature mapping layer, and a feature concatenation layer. These structural units can work together to complete the semantic modeling process of the input feature sequence.

[0124] The lightweight gated bottleneck convolutional structure can be used to perform gated modulation and convolutional fusion processing on input feature sequences. By compressing and mapping the feature dimensions through bottleneck convolution, the expressive power of key semantic information is enhanced while reducing computational complexity, thus obtaining gated convolutional features. Based on this, feature expansion mapping and nonlinear activation operations can be used to further transform the gated convolutional features to obtain first intermediate features, thereby improving the nonlinearity of feature representation.

[0125] Subsequently, the first intermediate feature can undergo two-dimensional multi-directional scanning modeling through parallel multi-directional scanning modeling paths to establish contextual dependencies between image regions in different spatial directions, thereby obtaining multi-directional scanning modeling features. Simultaneously, the first intermediate feature can also participate in subsequent feature modulation processes through independent gating paths. By performing element-wise multiplication of the first intermediate feature with the multi-directional scanning modeling features, feature modulation based on a gating mechanism can be achieved, enabling global contextual information to adaptively enhance the original features, thus obtaining gated fusion features.

[0126] After obtaining the gated fusion features, pixel-level weights can be used to guide the fusion layer to fuse the gated convolutional features with the scale-aligned gated fusion features. This fusion method can dynamically assign weights to different spatial locations, thereby adaptively adjusting the importance of different semantic information to obtain attention-based fusion features. Subsequently, a normalization layer can be used to perform feature alignment transformation on the attention-based fusion features to stabilize the feature distribution and obtain normalized features.

[0127] Finally, the attention fusion features and normalized features can be integrated through the feature mapping layer and the concatenation layer. By concatenating the features, a feature representation containing multi-layer semantic information is formed, thereby obtaining global semantic features for subsequent crack segmentation tasks.

[0128] Specifically, in the GAVM module, the state update process of the feature sequence can be represented as:

[0129]

[0130] in, Indicates the input feature sequence at the th The input vector corresponding to each time step; Represents the propagation coefficient of the hidden state in the spatial dimension, used to describe the propagation relationship of features between different spatial locations; This represents the constant connection matrix of the input, used for linear mapping of the input features; Indicates the first The hidden states corresponding to each time step; matrix and It can be generated through the SS2D selective scanning mechanism and used to establish spatial dimensions. With the time dimension The relationships between them, where the relevant parameters can be learned through the training process; This represents the state update result obtained at the current time step.

[0131] Through the aforementioned state update mechanism, contextual dependencies between different spatial locations can be gradually established in the feature sequence, enabling the model to capture long-distance semantic associations between image regions. Furthermore, by performing scan modeling along multiple directions in two-dimensional space, associations between features in different directions can be established, thereby enhancing the model's ability to express complex topological structures and spatially continuous information, and enabling the output features to more fully characterize the semantic extension characteristics of the crack structure in different directions.

[0132] Of course, the above formula is used to describe an optional state update method. In actual implementation, the above operation process can also be implemented through an equivalent neural network structure.

[0133] It is worth noting that the introduction of PAF enhances the fusion effect between the initial feature sequence and the features modeled by SS2D selective scanning. This structure can adaptively adjust the importance of different semantic information by assigning dynamic weights to different spatial locations, thereby strengthening the feature response capability of key regions. In this way, a more effective collaborative representation can be formed between the globally modeled features and the original features.

[0134] Furthermore, after selective scanning modeling, the residual connection structure can compensate for features, preserving local details while maintaining stable feature propagation. This promotes feature flow and alleviates information decay in deep networks. Further, by using a lightweight gated bottleneck convolutional structure to locally refine the output features of each layer, the expressive power for crack edge structures and fine-grained texture features can be enhanced, thus providing a more stable and discriminative semantic feature representation for subsequent crack region segmentation.

[0135] It should be noted that the above-described GAVM module structure is only one example implementation. Its structural units can be used to implement the aforementioned method steps, such as gating modulation and convolutional fusion, feature expansion and nonlinear mapping, multi-directional scanning modeling, gating fusion, and attention-guided fusion of the feature sequence. In other embodiments, the above functions can also be implemented using different forms of neural network structures or feature processing units, and this application does not limit this.

[0136] In some embodiments, to obtain semantic features at different scales while maintaining a lightweight overall network structure, multiple GAVM modules can be stacked to model the feature sequence layer by layer. For example, a four-layer stacked GAVM module can be used to process the input feature sequence, with the output of each layer gradually recovering the spatial resolution through upsampling, thereby progressively enhancing the semantic expressive power of the features at different levels. Through multi-layered, step-by-step modeling, the model can gradually expand the receptive range of features while maintaining low computational overhead, thus obtaining feature representations containing multi-scale semantic information.

[0137] In some embodiments, in order to achieve full fusion between the output features of the semantic feature extraction branch and the detail feature extraction branch, the dual-branch fusion structure may include structural units such as MLP layers, dynamic sampling layers, feature concatenation layers, and lightweight gated convolutional structures, which are used to align, fuse, and semantically enhance features from different branches.

[0138] The global semantic features output by the semantic feature extraction branch can be multi-scale feature representations, meaning that semantic features obtained at different network layers correspond to different receptive ranges. To facilitate fusion with local detail features, feature transformation and scale alignment can be performed on the semantic features at each scale first. Specifically, a linear transformation can be performed on the semantic features at each scale through an MLP layer to achieve feature dimension mapping; subsequently, a dynamic upsampling operation is performed on the semantic features at each scale through a dynamic sampling layer, so that the semantic features at different scales are consistent with the local detail features in terms of spatial resolution, thereby obtaining the upsampled semantic features corresponding to each scale.

[0139] After obtaining the upsampled semantic features, the upsampled semantic features at each scale can be concatenated with local detail features through a feature concatenation layer to form a concatenated feature. In this way, global semantic information and local structural information can be introduced into the same feature representation at the same time, so that the feature representation can reflect the overall structural relationship of the crack while preserving the crack edge and fine-grained texture information.

[0140] Subsequently, a lightweight gated convolutional structure can be used to perform gated modulation and convolutional fusion operations on the cascaded features. This structure can adaptively adjust feature information from different sources through a gating mechanism and achieve local interaction between features through convolutional operations, thereby obtaining the fused target features. Through the above fusion process, multi-scale semantic information and high-resolution detail information can be effectively integrated, thus providing richer and more discriminative feature representations for subsequent pixel-level prediction of crack regions.

[0141] It should be noted that the above-described dual-branch fusion structure is only one example implementation. Each structural unit can be used to implement the aforementioned method steps, such as linear mapping, dynamic upsampling, feature concatenation, and gated convolution fusion of multi-scale semantic features. In other implementations, other forms of feature alignment or fusion structures can also be used to achieve similar feature fusion functions, and this application does not limit this.

[0142] In some embodiments, the scale features extracted by the semantic feature extraction branch are respectively denoted as Considering the efficiency of MLP in feature mapping, each level of features is first linearly transformed by a lightweight MLP, and then restored to the original image resolution using dynamic upsampling, resulting in four levels of upsampled semantic features. :

[0143]

[0144] Among them, MLP is used to model semantic mapping within the scale, while DySample is responsible for flexibly restoring spatial dimensions while ensuring semantic consistency.

[0145] The detail feature extraction branch on the other side outputs local detail features. This feature contains clear structural boundaries and high-frequency detail information, which is used to compensate for the edge degradation and lack of detail problems commonly found in high-level semantic features. In the fusion stage, the fourth-level semantic features and the fine details are first combined to form a joint representation containing rich cross-scale semantics and detail cues:

[0146]

[0147] Since direct splicing makes it difficult to establish dependencies between features from different sources, a lightweight gated bottleneck convolutional machine structure is introduced to perform structural constraints and information selection on the fused features. The gating mechanism of this lightweight gated bottleneck convolutional structure can suppress background noise and highlight the main structure of the crack. Its output is as follows:

[0148]

[0149] Finally, channel compression is performed using 1×1 convolution, followed by pixel-by-pixel classification mapping using MLP to obtain the final segmentation result:

[0150]

[0151] The output This represents the final crack segmentation diagram.

[0152] DFSH enables the model to possess both strong contextual understanding capabilities and excellent boundary sensitivity through the dual-path collaboration of semantic branches and detail branches; while the introduction of lightweight gated bottleneck convolutional structures improves the utilization efficiency of the fusion stage, enabling the acquisition of structurally continuous and clearly defined crack segmentation results even in complex backgrounds.

[0153] In some embodiments, see Figure 4 , Figure 4 This paper presents a lightweight gated convolutional structure, which includes two convolutional branches, a fusion layer, a deep convolutional branch, and a concatenation layer. The main convolutional branch includes two feature transformation processing blocks, while the secondary convolutional branch includes one. The fusion layer merges the outputs of the two convolutional branches. The deep convolutional branch has one feature transformation processing block. The concatenation layer concatenates the output of the deep fusion branch and the features to be processed passed from the residual structure. The feature transformation processing block includes a lightweight bottleneck convolutional layer (LiteBottConv), a normalization layer (BN), and a linear activation layer (ReLU). To further reduce the parameter size and improve training stability, the bottleneck convolution and normalization methods have been significantly improved. While maintaining the overall gating mechanism, the channel compression ratio of the bottleneck layer has been redesigned, and the number of normalization groups in each stage has been unified, thus constructing a lighter and numerically stable gated bottleneck convolutional module. In the convolution operation, the features to be processed are... The kernel space size is p The number of input channels is d Convolution can be represented as:

[0154]

[0155] in The input features are vectorized. For size The linear transformation matrix, Number of output channels This is the bias term. If we assume the convolution response... Falling on rank Within the low-rank subspace, it can be Decomposed into ,in Responsible for mapping features from a low-rank space back to a high-dimensional space. Then a projection from high dimension to low dimension is performed. The convolution result can then be transformed into:

[0156]

[0157] in This is the corrected bias term. Because BottConv is used, the intermediate channels are uniformly compressed to... Compared to the original The design and computational workload are... Further reduced to This significantly reduces the computational burden of point convolution and depth convolution.

[0158] Based on the aforementioned low-rank concept, the improved BottConv retains the structure of "1x1 dimensionality reduction - depthwise convolution to extract spatial information - 1x1 dimensionality increase," but achieves a higher compression ratio through a smaller number of intermediate channels. Specifically, BottConv's first pointwise convolution layer converts the input from... Dimension mapping to The system first performs channel-by-channel spatial modeling using depthwise convolution within this compact subspace; finally, it restores the original number of channels using a second-layer pointwise convolution. Since all three parts are computed based on a smaller number of intermediate channels, the entire structure achieves a more lightweight effect without sacrificing spatial information extraction capabilities.

[0159] On the other hand, to avoid the normalization instability caused by the number of groups changing with the number of channels in the original structure, the number of groups in all GroupNorm modules is uniformly set to 16. When the number of input channels is less than 16, the maximum number of valid groups not exceeding the number of channels is automatically selected. This fixed grouping strategy not only improves the consistency of the training process but also makes the improved gated bottleneck convolutional structure more transferable across different network depths.

[0160] In the specific calculation process, the features to be processed are first retained as residual features. x The features to be processed are then fed into the main convolutional branch for feature extraction. The first stage of the main convolutional branch obtains the following: [Further details about the process are needed for accurate translation].

[0161]

[0162] in This represents the initially extracted local spatial features (i.e., the first enhanced features). Next, ... By re-inputting the same structure, we obtain further enhanced detailed features (second enhanced features):

[0163]

[0164] at the same time, It also obtains dynamically gated features (equivalent to the first enhanced feature) from the convolution branch through BottConv, normalization, and ReLU activation:

[0165]

[0166] Dynamic gating features are used to adjust which features should be preserved or suppressed in the main branch. Subsequently, detail features and gating features are fused using Hadamard multiplication:

[0167]

[0168] in This is used to characterize a fine-grained response that adaptively adjusts based on the input content. The fused features are then refined using a simplified BottConv algorithm to obtain:

[0169]

[0170] The final output recovers the original feature scale from the residual connections, forming the corresponding fused features:

[0171]

[0172] Through the above improvements, the gated bottleneck convolutional structure can significantly reduce the computational cost of the convolution process while maintaining the dynamic gating capability of the original model, and effectively enhance the stability of normalization. The more compact Bottleneck subspace enables more precise feature enhancement of fine-grained regions while ensuring the representation of the main crack structure, thereby obtaining higher-quality segmentation results in scenes with complex textures or blurred crack edges.

[0173] It is understandable that the features to be processed can be feature sequences or cascaded concatenated features, that is, the gated bottleneck convolutional structure is set in the semantic feature extraction branch and DFSH respectively.

[0174] In some embodiments, in semantic segmentation tasks, low-level features contain rich spatial details but lack high-level semantics, while high-level features possess powerful semantic expressive capabilities but lose fine spatial structure. To obtain local detail features, the detail feature extraction branch can employ edge-aware guidance and multi-scale feature extraction strategies, significantly improving boundary segmentation accuracy while maintaining computational efficiency.

[0175] For example, the detail feature extraction branch may include five key components: a feature projection layer, an edge-sensitive module, a multi-scale feature extractor, a lightweight residual block, and an output projection layer.

[0176] Image to be segmented Perform local detail feature extraction:

[0177] First, channel dimensionality reduction is performed using a feature projection layer, such as a 1×1 convolutional layer, to obtain the second intermediate feature. :

[0178]

[0179] in This represents the convolution operation, and BN represents batch normalization. It is the ReLU activation function. This represents the number of intermediate channels.

[0180] Then, edge features E are extracted from the second intermediate features using the edge-sensitive module;

[0181] Simultaneously, using a multi-scale feature extractor, such as a multi-scale depthwise separable convolutional module (MultiScaleDW), features of different scales are extracted from the second intermediate features and concatenated to obtain multi-scale intermediate features:

[0182]

[0183] Where DWConv represents depthwise convolution, d is the dilation rate, and [·,·,·] indicates the use of channel concatenation. This module captures detail information at different scales through three parallel branches: a standard 3×3 convolution branch, a 3×3 convolution branch with a dilation rate of 2, and a 5×5 convolution branch. These three branches each have different receptive fields, enabling them to capture various spatial patterns ranging from local details to larger-scale structures.

[0184] Next, the edge features are fused with the multi-scale intermediate features to obtain the deep fused features:

[0185]

[0186] This fusion operation maintains edge sharpness while preserving multi-scale contextual information. The fused features are then subjected to residual optimization using two lightweight, deeply separable residual blocks (DWResBlock). The computation process for each residual block is defined as follows:

[0187]

[0188] in For depthwise convolution kernels, For point-wise convolution, this structure effectively promotes gradient flow and prevents network degradation. It then processes the data through two consecutive residual blocks:

[0189] Finally, the deep fusion features after residual optimization are channel-expanded through the output projection layer, such as a 1×1 convolution, and projected onto the target channel dimension to obtain local detail features. :

[0190]

[0191] It is worth noting that all convolution operations employ a depthwise separable form, resulting in significantly lower computational complexity than standard convolution. For features with C input channels, the computational cost of depthwise separable convolution is only about one-third that of standard convolution. This design can significantly improve computational efficiency while maintaining performance (k is the kernel size).

[0192] In some embodiments, Figure 5 A schematic diagram of the overall structure of the road crack segmentation model provided in this application is shown. The segmentation model can generally include two feature extraction branches and a DFSH (Deep Detail Feature Extraction) branch. The two feature extraction branches are used to extract different types of image features: the semantic feature extraction branch performs global semantic modeling on the input image to obtain multi-scale semantic features reflecting the overall structural relationships of the image; the detail feature extraction branch extracts fine-grained features including edge information, texture information, and local structural information. The DFSH branch aligns and fuses the features output from the two branches, and generates the final crack segmentation result based on the fused features. Specific implementation methods of each key structure can be found in the relevant descriptions in the foregoing embodiments.

[0193] Through the aforementioned structural design, this segmentation model can effectively model elongated, irregularly shaped, and directionally continuous targets such as road cracks by simultaneously utilizing global semantic information and local detail information. Specifically, the semantic feature extraction branch enhances its ability to capture long-distance dependencies through a lightweight state-space modeling structure, enabling the model to accurately understand the overall topological structure of the crack; the detail feature extraction branch strengthens its ability to express crack boundaries and fine cracks through multi-scale convolution and edge enhancement structures; and the dual-branch fusion segmentation head effectively integrates the two types of features through multi-scale feature alignment and gating fusion mechanisms. This dual-branch collaborative modeling and fusion strategy significantly improves the accuracy of crack region identification and boundary localization while maintaining model computational efficiency, thereby enhancing overall segmentation performance.

[0194] In some embodiments, in road crack segmentation tasks, a single loss function is often insufficient to comprehensively optimize the model's performance under various complex scenarios. Road cracks typically have elongated, irregular geometric shapes and occupy a very small proportion of the entire image, leading to severe class imbalance. Furthermore, variations in lighting conditions, complex and diverse road surface textures, and blurred crack edges further exacerbate the segmentation difficulty.

[0195] To address the aforementioned challenges, this paper proposes a Triad Composite Loss (TCL) function, which linearly fuses three complementary loss terms—Binary Cross-Entropy (BCE), Generalized Dice Loss (GDL), and Focal Tversky Loss (FTL)—with preset weights. Through this multi-objective collaborative optimization strategy, TCL effectively enhances the model's ability to learn key structural features of cracks (such as edge accuracy, elongated connectivity, and topological integrity), significantly improving its segmentation accuracy and generalization performance in complex real-world scenarios.

[0196] The binary cross-entropy loss (BCE) term employs a pixel-level weighting strategy to effectively handle the extreme imbalance between cracks and the background.

[0197]

[0198] in, For binary cross-entropy loss, N The number of image samples for all road cracks. For the first i The true category of each image sample For the first i Predicted category for each image sample; For category C i Adaptive weights; adaptive weights are derived from learnable parameters. w Within the range of values ​​[ w 0 ,w 1] Dynamically adjust the weights internally, and ensure a reasonable weight distribution through softmax normalization:

[0199]

[0200] and These are trainable parameters; through weight distribution constraints, the model can automatically increase the attention given to pixels with cracks even if the cracks account for less than 1% of the image.

[0201] Generalized Dice loss Focusing on improving the overall coherence of the crack region is particularly important for slender and discontinuous crack structures. It is defined as:

[0202]

[0203] and These represent category c in N The true label and predicted probability on each sample; Category weights; This is a smoothing term. The design of the generalized Dice loss makes the loss function more sensitive to rare categories (cracks), effectively preventing the model from being biased towards predicting the background.

[0204] Focus Tversky loss The focus is on improving the segmentation accuracy of crack edges, which is defined as:

[0205]

[0206] in, , and These represent true positives, false positives, and false negatives, respectively. and Let represent the weights of the false positives and false negatives, respectively, and let their sum equal to 1. < γ represents the focusing parameter. For example... and To adjust the relative importance of false positives and false negatives, the model focuses more on reducing missed false negatives, which is crucial for road crack detection, as missed cracks can lead to serious safety hazards. (Focusing on parameters) This further enhances the focus on difficult-to-segment areas (such as fine cracks and blurred edges).

[0207] final, The total loss function incorporates three complementary loss terms, expressed as follows:

[0208]

[0209] , as well as These are the weight coefficients corresponding to the binary cross-entropy loss, generalized Dice loss, and focal Tversky loss, respectively. , as well as The sum of these weights is 1. These weights can be dynamically adjusted through parameter configuration, allowing the loss function to adapt to the characteristics of different road scenarios. For example, each weight is set to... , and This demonstrates superior performance on a variety of road datasets.

[0210] In some embodiments, this application selects three representative crack image datasets to verify the adaptability and robustness of the model in different scenes and materials.

[0211] The Crack500 dataset consists of images of asphalt pavement cracks taken with a mobile phone. The original dataset contained 500 images, which were then expanded to 3368 images through data augmentation. Each image has a precise pixel-level binary label, providing a reliable training foundation for supervised segmentation tasks.

[0212] The DeepCrack dataset contains 537 RGB images, covering various materials such as cement, brick, and asphalt. Crack types include fine cracks, wide cracks, cracks with stain interference, and cracks with blurred edges, effectively reflecting the complex and diverse characteristics of real-world environments. Compared to the previous two,

[0213] The TUT dataset features more complex backgrounds and richer scene variations, containing 1408 RGB images covering eight different scenes including asphalt, cement, brick surfaces, runways, tiles, metal, knives, and pipes. Among them, the cracks have more intricate morphology and complex structures, posing a greater challenge.

[0214] Through comprehensive experiments on the above three datasets, the generalization ability of the model in cracks of multiple scenarios, materials, and forms can be fully evaluated.

[0215] In some embodiments, to comprehensively evaluate model performance, this application employs six commonly used metrics, including precision (P), recall (R), F1 score (F1), optimal dataset scale (ODS), optimal image scale (OIS), and mean intersection over union (mIoU). The F1 score, used to comprehensively measure the model's recall and precision, is defined as:

[0216]

[0217] ODS is used at a fixed threshold m The evaluation method assesses the model's overall performance on datasets of different scales, reflecting its adaptability to cross-scale data; while OIS searches for the optimal threshold on each image. n This was used to examine the model's generalization ability across different image scales. The calculation methods are as follows:

[0218]

[0219] Furthermore, to further measure the model's accuracy in pixel-level segmentation tasks, mIoU is used as the core performance metric, defined as follows:

[0220]

[0221] in, Indicates the number of categories (set to in this task). (That is, cracks and background, which are two categories). Indicates the true label, Indicates the prediction result. Indicates the true category is And it was predicted to be The number of pixels, Indicates the true category is And it was predicted to be The number of pixels.

[0222] In addition to segmentation accuracy, the model is also evaluated from the perspective of computational complexity. Floating-point operations (FLOPs), number of parameters (Params), and model size (Model Size) are used as additional metrics to comprehensively demonstrate the model's efficiency and resource consumption in real-world deployment scenarios.

[0223] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0224] Corresponding to the deep learning-based road crack segmentation method in the above embodiment, Figure 6 The diagram shows a structural block diagram of a road crack segmentation device 6 based on deep learning provided in an embodiment of this application. For ease of explanation, only the parts related to the embodiment of this application are shown.

[0225] Reference Figure 6 The deep learning-based road crack segmentation device 6 includes:

[0226] Encoding module 61 is used to convert the acquired image to be segmented containing road cracks into a block-level representation and introduce location information to obtain a feature sequence;

[0227] The first extraction module 62 is used to perform state modeling on the feature sequence to obtain global semantic features;

[0228] The second extraction module 63 is used to extract local detail features from the image to be segmented;

[0229] The fusion module 64 is used to fuse global semantic features with local detail features to obtain the target fused features;

[0230] The segmentation module 65 is used to output the crack segmentation result corresponding to the image to be segmented based on the fusion features.

[0231] Optionally, the first extraction module 62 is specifically used for:

[0232] Gated modulation and convolution fusion operations are performed on the feature sequence to obtain gated convolution features;

[0233] The first intermediate feature is obtained by sequentially performing feature expansion mapping and nonlinear activation operations on the gated convolutional features.

[0234] Perform a two-dimensional multi-directional scanning modeling operation on the first intermediate feature to obtain the multi-directional scanning modeling feature;

[0235] The first intermediate feature is multiplied element-wise with the multi-directional scanning modeling feature to obtain the gated fusion feature;

[0236] Pixel-level weighted fusion is performed on the gated convolutional features and the scale-aligned gated fusion features to obtain attention-based fusion features;

[0237] Perform a feature alignment transformation operation on the attention fusion features to obtain normalized features;

[0238] The attention fusion features and normalized features are concatenated to obtain global semantic features.

[0239] Optionally, the global semantic features are multi-scale features; the fusion module 64 is specifically used for:

[0240] For the semantic features at each scale, linear transformation and dynamic upsampling operations are performed sequentially to obtain the upsampled semantic features corresponding to each scale.

[0241] The upsampled semantic features at each scale are concatenated with local detail features to obtain cascaded concatenated features;

[0242] The concatenated spliced ​​features are subjected to gating modulation and convolutional fusion operations to obtain the target fused features.

[0243] Optionally, the first extraction module 62 or the fusion module 64 is provided with a sub-module for gating modulation and convolution fusion, which is used for:

[0244] Perform feature transformation processing on the features to be processed to obtain the first enhanced feature;

[0245] Perform feature transformation processing on the first enhanced feature to obtain the second enhanced feature;

[0246] The first enhancement feature and the second enhancement feature are dynamically gated and modulated to obtain the initial fused feature;

[0247] The feature to be processed is concatenated with the initial fusion feature after feature transformation to obtain the fusion feature corresponding to the feature to be processed.

[0248] The feature transformation processing operations include bottleneck convolution transformation, normalization, and linear activation.

[0249] Optionally, the second extraction module 63 is specifically used for:

[0250] Channel compression is performed on the image to be segmented to obtain the second intermediate feature;

[0251] Perform multi-scale feature extraction and concatenation operations on the second intermediate feature to obtain multi-scale intermediate features;

[0252] Extract edge features from the second intermediate features;

[0253] Edge features are concatenated with multi-scale intermediate features to obtain deep fusion features;

[0254] Two residual optimization processes are performed on the deep fusion features, and channel expansion is performed on the optimized deep fusion features to obtain local detail features.

[0255] Optionally, the second extraction module 63 includes an edge feature extraction submodule, which is used for:

[0256] The convolution operation is performed on each channel of the second intermediate feature based on the convolution kernel of the preset four-neighbor Laplacian edge detection operator to obtain the edge response corresponding to each channel;

[0257] The edge responses of each channel are combined to obtain the edge features.

[0258] Optionally, the road crack segmentation method is implemented based on a pre-trained road crack segmentation model, and the total loss function for training the road crack segmentation model includes:

[0259]

[0260]

[0261]

[0262]

[0263]

[0264] in, For the total loss function, , as well as These are the binary cross-entropy loss, the generalized Dice loss, and the focal Tversky loss, respectively. , as well as These are the weight coefficients corresponding to the binary cross-entropy loss, generalized Dice loss, and focal Tversky loss, respectively. , as well as The sum of is 1; N The number of image samples for all road cracks. For the first i The true category of each image sample For the first i Predicted category for each image sample; For category C i Adaptive weights; adaptive weights are derived from learnable parameters. w Within the range of values ​​[ w 0 ,w 1] Internal dynamic adjustment; and These are trainable parameters; and These represent category c in N The true label and predicted probability on each sample; Category weights; For smoothing terms; , and These represent true positives, false positives, and false negatives, respectively. and Let represent the weights of the false positives and false negatives, respectively, and let their sum equal to 1. < γ represents the focusing parameter.

[0265] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, and they will not be repeated here.

[0266] Figure 7 This is a schematic diagram of the physical layer structure of an electronic device provided in an embodiment of this application. Figure 7 As shown, the electronic device 7 of this embodiment includes: at least one processor 70 ( Figure 7 Only one processor is shown in the diagram. A memory 71 and a computer program 72 stored in the memory 71 and executable on at least one processor 70 are also shown. When the processor 70 executes the computer program 72, it implements the steps in any of the above embodiments of the deep learning-based road crack segmentation method. For example... Figure 1 Steps 110-150 are shown.

[0267] The processor 70 can be a central processing unit (CPU), or it can be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.

[0268] In some embodiments, memory 71 may be an internal storage unit of electronic device 7, such as a hard disk or memory of electronic device 7. In other embodiments, memory 71 may also be an external storage device of electronic device 7, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc. equipped on electronic device 7.

[0269] Furthermore, the memory 71 may include both internal storage units and external storage devices of the electronic device 7. The memory 71 is used to store operating devices, application programs, bootloaders, data, and other programs, such as program code for computer programs. The memory 71 can also be used to temporarily store data that has been output or will be output.

[0270] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the above device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0271] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.

[0272] This application provides a computer program product that, when run on an electronic device, enables the electronic device to perform the steps described in the various method embodiments above.

[0273] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a photographic device / electronic device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, such as a USB flash drive, a portable hard drive, a magnetic disk, or an optical disk.

[0274] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0275] 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 in 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. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0276] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units described above is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0277] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, 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 according to actual needs.

[0278] The above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.

Claims

1. A road crack segmentation method based on deep learning, characterized in that, include: The acquired image containing road cracks is converted into a block-level representation, and location information is introduced to obtain a feature sequence. State modeling is performed on the feature sequence to obtain global semantic features; Extract local detail features from the image to be segmented; The global semantic features and the local detail features are fused to obtain the target fusion features; Based on the target fusion features, output the crack segmentation result corresponding to the image to be segmented; The step of extracting local detail features from the image to be segmented includes: Channel compression is performed on the image to be segmented to obtain the second intermediate feature; Based on the standard 3×3 convolution branch, the 3×3 convolution branch with a dilation rate of 2, and the 5×5 convolution branch set in parallel, feature extraction operations at different receptive field scales are performed on the second intermediate feature and channel concatenation is performed to obtain multi-scale intermediate features. The convolution operation is performed on each channel of the second intermediate feature based on the convolution kernel of the preset four-neighbor Laplacian edge detection operator to obtain the edge response corresponding to each channel, and the edge responses of each channel are combined to obtain the edge feature. The edge features are concatenated with the multi-scale intermediate features to obtain deep fusion features; The deep fusion features are subjected to two residual optimization processes, and the optimized deep fusion features are subjected to channel expansion to obtain the local detail features; The global semantic features are multi-scale features; the fusion of the global semantic features and the local detail features to obtain the target fusion features includes: For the semantic features at each scale, linear transformation and dynamic upsampling operations are performed sequentially to obtain the upsampled semantic features corresponding to each scale. The upsampled semantic features at each scale are concatenated with the local detail features to obtain cascaded concatenated features; The concatenated spliced ​​features are subjected to gating modulation and convolutional fusion operations to obtain the target fused features; The gated modulation and convolution fusion operation includes: Perform feature transformation processing on the features to be processed to obtain the first enhanced feature; Perform feature transformation processing on the first enhanced feature to obtain the second enhanced feature; The first enhancement feature and the second enhancement feature are dynamically gated and modulated to obtain the initial fused feature; The feature to be processed is concatenated with the initial fusion feature after feature transformation processing to obtain the fusion feature corresponding to the feature to be processed; The feature transformation processing operations include bottleneck convolution transformation, normalization, and linear activation.

2. The road crack segmentation method as described in claim 1, characterized in that, The process of performing state modeling on the feature sequence to obtain global semantic features includes: The gated modulation and convolution fusion operation is performed on the feature sequence to obtain gated convolution features; The gated convolutional features are sequentially subjected to feature expansion mapping and nonlinear activation operations to obtain the first intermediate features; Perform a two-dimensional multi-directional scanning modeling operation on the first intermediate feature to obtain the multi-directional scanning modeling feature; The first intermediate feature is multiplied element-wise with the multi-directional scanning modeling feature to obtain the gated fusion feature; Pixel-level weighted fusion is performed on the gated convolutional features and the scale-aligned gated fusion features to obtain attention-based fusion features; Perform a feature alignment transformation operation on the attention fusion features to obtain normalized features; The attention fusion feature is concatenated with the normalized feature to obtain the global semantic feature.

3. The road crack segmentation method as described in claim 1 or 2, characterized in that, The road crack segmentation method is based on a pre-trained road crack segmentation model. The total loss function for training the road crack segmentation model is a ternary composite loss function, which is obtained by linearly fusing the binary cross-entropy loss, the generalized Dice loss, and the focal Tversky loss according to preset weights.

4. A road crack segmentation device based on deep learning, characterized in that, include: The encoding module is used to convert the acquired image containing road cracks into a block-level representation and incorporate location information to obtain a feature sequence; The first extraction module is used to perform state modeling on the feature sequence to obtain global semantic features; The second extraction module is used to extract local detail features from the image to be segmented; The fusion module is used to fuse the global semantic features with the local detail features to obtain the target fused features; The segmentation module is used to output the crack segmentation result corresponding to the image to be segmented based on the target fusion features; The second extraction module is specifically used for: Channel compression is performed on the image to be segmented to obtain the second intermediate feature; Based on the standard 3×3 convolution branch, the 3×3 convolution branch with a dilation rate of 2, and the 5×5 convolution branch set in parallel, feature extraction operations at different receptive field scales are performed on the second intermediate feature and channel concatenation is performed to obtain multi-scale intermediate features. The convolution operation is performed on each channel of the second intermediate feature based on the convolution kernel of the preset four-neighbor Laplacian edge detection operator to obtain the edge response corresponding to each channel, and the edge responses of each channel are combined to obtain the edge feature. The edge features are concatenated with the multi-scale intermediate features to obtain deep fusion features; The deep fusion features are subjected to two residual optimization processes, and the optimized deep fusion features are subjected to channel expansion to obtain the local detail features; The global semantic features are multi-scale features; the fusion module is specifically used for: For the semantic features at each scale, linear transformation and dynamic upsampling operations are performed sequentially to obtain the upsampled semantic features corresponding to each scale. The upsampled semantic features at each scale are concatenated with the local detail features to obtain cascaded concatenated features; The concatenated spliced ​​features are subjected to gating modulation and convolutional fusion operations to obtain the target fused features; The fusion module includes a sub-module for gating modulation and convolution fusion, which is used for: Perform feature transformation processing on the features to be processed to obtain the first enhanced feature; Perform feature transformation processing on the first enhanced feature to obtain the second enhanced feature; The first enhancement feature and the second enhancement feature are dynamically gated and modulated to obtain the initial fused feature; The feature to be processed is concatenated with the initial fusion feature after feature transformation processing to obtain the fusion feature corresponding to the feature to be processed; The feature transformation processing operations include bottleneck convolution transformation, normalization, and linear activation.

5. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the deep learning-based road crack segmentation method as described in any one of claims 1 to 3.

6. A computer program product, said computer program product comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the deep learning-based road crack segmentation method as described in any one of claims 1 to 3.

Citation Information

Patent Citations

  • Pavement crack accurate segmentation method based on histogram interaction attention

    CN121564336A