Real-time detection method and system for micro-defects of breathable film based on multi-scale feature enhancement

By employing a multi-scale feature enhancement detection method, utilizing backlight imaging and an improved Retinex algorithm for image preprocessing, and combining the YOLOv10 architecture and MCEA module, the problem of high-precision real-time detection of micro-defects in breathable membranes under low-contrast environments was solved, improving the robustness and speed of detection.

CN121962096APending Publication Date: 2026-05-01XIDIAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
XIDIAN UNIV
Filing Date
2026-01-20
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing detection methods struggle to perform high-precision, real-time detection of micro-defects in breathable membranes under high-speed, low-contrast industrial conditions, especially given the challenges of random defect distribution, small size, low contrast, and poor signal-to-noise ratio.

Method used

A detection method based on multi-scale feature enhancement is adopted, including backlight imaging to acquire images, improved multi-scale Retinex algorithm for preprocessing, feature extraction network based on YOLOv10 architecture and multi-scale channel enhanced attention module (MCEA), and the ProbIoU loss function is introduced for end-to-end training.

Benefits of technology

It achieves high-precision identification of micro-defects in low-contrast environments, meets the needs of real-time detection, improves the robustness and speed of detection, and reduces the dependence on human experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121962096A_ABST
    Figure CN121962096A_ABST
Patent Text Reader

Abstract

The invention provides a real-time detection method and system for micro-defects of a breathable film based on multi-scale feature enhancement, and the method comprises the steps: carrying out the preprocessing of a breathable film image through an improved multi-scale Retinex algorithm, so as to enhance the contrast and visibility of the micro-defects; extracting multi-scale features by using a hierarchical feature enhancement network, and introducing a multi-scale channel enhanced attention module MCEA to perform cross-scale fusion and optimization on the features; and the ProbIoU loss function is adopted to synchronously optimize the detection precision and the bounding box regression efficiency, so that high-precision real-time micro-defect detection is realized, and the defect identification robustness and the reasoning speed in an industrial scene are effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of industrial defect detection technology, specifically relating to a real-time detection method and system for micro-defects in breathable membranes based on multi-scale feature enhancement. Background Technology

[0002] Breathable membranes, as an important functional material, are typically made from thermoplastic polymers filled with high concentrations of solid particles (such as calcium carbonate and silica), and fabricated into microporous structures through a casting-stretching process. They are widely used in medical, hygiene, and construction fields. However, during the production process, fluctuations in process parameters, changes in thermodynamic parameters due to equipment precision and environmental factors, and uneven dispersion of fillers can easily lead to micron-sized gel defects (gel particles). These defects can cause localized stress concentrations, significantly reducing the mechanical strength of the material.

[0003] Existing detection methods mainly rely on manual visual inspection or contact sensors, which suffer from problems such as response delay and insufficient spatial resolution, making it difficult to meet the real-time detection requirements of micro-defects in high-speed production lines. Especially in industrial scenarios with randomly distributed defects, small scale, low contrast, and poor signal-to-noise ratio, traditional methods have significant limitations in both detection efficiency and accuracy. Therefore, developing a high-precision, real-time micro-defect detection technology that can adapt to complex working conditions is of great significance. Summary of the Invention

[0004] In view of this, the main objective of the present invention is to provide a real-time detection method and system for micro-defects in breathable membranes based on multi-scale feature enhancement, so as to solve the problems of low accuracy, poor real-time performance and insufficient robustness of existing detection technologies in high-speed, low-contrast industrial scenarios for micro-defect identification.

[0005] To achieve the above objectives, the technical solution of the present invention is as follows: A real-time detection method for micro-defects in breathable membranes based on multi-scale feature enhancement includes the following steps: Step 1: Construct an image acquisition system and use methods such as backlight imaging to acquire the original image of the breathable membrane to be inspected. For example, the method for acquiring the original image of the breathable membrane using backlight imaging is as follows: The breathable membrane sample is placed between a uniform surface light source and an industrial camera. The distance between the sample and the surface light source is adjusted to 30-50 cm, and the sample is kept parallel to the lens of the industrial camera. The brightness of the uniform surface light source is adjustable and is maintained within the range of 3000-5000 lm to ensure uniform and stable transmitted light intensity. The industrial camera is a global shutter color camera with a resolution of 5 million to 12 million pixels, which acquires images with a high signal-to-noise ratio through transmission imaging.

[0006] Step 2: Perform illumination normalization and detail enhancement processing on the original image to obtain a preprocessed image. For example, this invention utilizes an improved multi-scale Retinex algorithm to implement the above preprocessing, specifically including: (1) Perform multi-scale Gaussian filtering on the input original image to extract the illumination components at different spatial scales; (2) Perform a difference operation between the original image and the illumination components at each scale in the logarithmic domain to separate the reflection components and enhance image details; (3) Use the SSE instruction set to accelerate the pixel-level operations in steps (1) and (2) in parallel (e.g., batch processing in 4-pixel increments) to achieve vectorization of single-scale Retinex operations. (4) Weighted fusion of the enhanced reflection components at each scale is performed to balance the enhancement of details and the global illumination effect, and the color restoration process is performed on the fused result to ensure that the enhanced image maintains natural color fidelity.

[0007] Step 3: Input the preprocessed image into a feature extraction network built on the YOLOv10 architecture, and extract multi-scale features of the image through the backbone network of the network.

[0008] Step 4: Input the preliminary multi-scale features into the Multi-Scale Channel Enhancement Attention (MCEA) module to perform channel dimension fusion and weighted enhancement on feature maps from different scales to obtain enhanced multi-scale fused features.

[0009] The MCEA module is integrated into the neck network of the feature extraction network. After cross-scale fusion is completed in feature layers of three different scales with downsampling factors of 8 (P3 layer), 16 (P4 layer), and 32 (P5 layer), an MCEA module is inserted to enhance the multi-scale feature fusion capability. This module contains multiple parallel multi-scale branches, a feature fusion layer, and a channel attention layer. Each branch performs feature extraction through a 1×1 convolutional expansion layer, a depthwise separable convolutional layer, and a 1×1 convolutional compression layer connected in sequence, with a residual connection between the output of the depthwise separable convolutional layer and the output of the 1×1 convolutional expansion layer. The feature fusion layer performs global average pooling on the outputs of multiple multi-scale branches and concatenates them along the channel dimension, then compresses the number of channels through a 1×1 convolution. The channel attention layer consists of two 1×1 convolutional layers with a ReLU activation function between them. The second 1×1 convolutional layer is followed by a Sigmoid activation function. Weights are generated through a fully connected layer and activation function. The output of the channel attention layer is finally multiplied element-wise with the input feature map of the module.

[0010] Step 5: Input the enhanced multi-scale fusion features into the detection head to generate preliminary prediction results of defect categories and bounding boxes.

[0011] The detection head uses an improved YOLOv10 detection head, which includes parallel one-to-many branches and one-to-one branches. The one-to-many branches inherit from the standard YOLOv10 detection head structure, and the one-to-one branches contain convolutional modules with the same structure as the one-to-many branches but with independent parameters. During the training phase, both branches output detection results simultaneously, while during the inference phase, only the output of the one-to-one branches is used. The final bounding box coordinates, confidence scores, and class labels are generated through post-processing operations.

[0012] Step 6: Perform end-to-end training on the overall network, which includes the feature extraction network, the multi-scale channel enhanced attention module, and the detection head, until convergence is achieved, and obtain the trained optimized micro-defect detection model. Use this model to perform real-time detection of micro-defects in the breathable membrane.

[0013] The training process utilizes ProbIoU, a probability distribution-based loss function. The ProbIoU loss function converts the bounding box into a Gaussian distribution representation, calculates the Bhattacharyya probability distance, and converts it into a loss value according to the L1 or L2 mode to improve localization accuracy and robustness.

[0014] Meanwhile, the present invention also provides a real-time detection system for micro-defects in breathable membranes based on multi-scale feature enhancement, for implementing the aforementioned detection method, comprising: Image acquisition system: used to acquire raw images of the breathable membrane using backlight imaging; Image preprocessing module: used to perform illumination normalization and detail enhancement on the original image using an improved multi-scale Retinex algorithm to obtain a preprocessed image; Feature extraction module: used to input the preprocessed image into a feature extraction network built on the YOLOv10 architecture to extract multi-scale features; The feature enhancement module is used to fuse and enhance the multi-scale features through the multi-scale channel enhancement attention module to obtain enhanced multi-scale fused features; The detection module is used to input the enhanced multi-scale fusion features into the detection head, generate the prediction results of defect categories and bounding boxes, and output the micro-defect categories and bounding box coordinates. The training module is used to perform end-to-end optimization of the feature extraction network, the multi-scale channel enhanced attention module, and the detection head by minimizing the probability distribution-based ProbIoU loss function, so as to obtain the trained real-time detection model.

[0015] Compared with the prior art, the beneficial effects of the present invention are: 1. High-precision detection: Through multi-scale feature enhancement and attention mechanism, the recognition accuracy of micro-defects in low-contrast and high-noise environments is significantly improved.

[0016] 2. Strong real-time performance: Adopting SSE parallel acceleration and lightweight network structure, the inference time of a single frame is only 60.3ms, which meets the real-time requirements of high-speed production lines.

[0017] 3. Excellent robustness: The ProbIoU loss function is introduced to model the uncertainty of the bounding box, effectively addressing the challenges of variable defect shapes and blurred boundaries.

[0018] 4. High system integration: The entire process from image acquisition to detection result output is optimized, which facilitates industrial deployment and reduces reliance on human experience. Attached Figure Description

[0019] Figure 1 This is a flowchart illustrating the overall process of the method of the present invention.

[0020] Figure 2 A schematic diagram of the improved multi-scale Retinex algorithm.

[0021] Figure 3 This is a schematic diagram of a multi-scale feature enhancement network structure.

[0022] Figure 4 A schematic diagram of the multi-scale channel enhanced MCEA attention module. Detailed Implementation

[0023] To make the objectives, technical solutions, and advantages of this invention clearer, the following detailed description of a real-time detection method and system for micro-defects in breathable membranes based on multi-scale feature enhancement, in conjunction with the accompanying drawings and embodiments, is provided. It should be understood that the embodiments described herein are for illustrative purposes only and are not intended to limit the scope of the invention.

[0024] like Figure 1 As shown, the method of the present invention mainly includes the following steps: Step 1: Construction of the breathable membrane image acquisition system and image acquisition.

[0025] In this step, a dedicated backlit imaging system was constructed to acquire raw images of the breathable membrane samples. High signal-to-noise ratio sample images were obtained through transmission imaging principles, providing high-quality input data for subsequent micro-defect detection. It is worth noting that the acquisition of raw images in this invention does not necessarily rely on this dedicated backlit imaging system; conventional acquisition methods can also obtain sample images. The use of this dedicated backlit imaging system in this invention improves both the signal-to-noise ratio of the sample images and the integration of the entire detection system.

[0026] The specific implementation method for acquiring images of the breathable membrane using a backlit imaging system in this step is as follows: Step 1.1: Build a backlight imaging platform.

[0027] A uniform surface light source is fixed to the bottom of an aluminum alloy platform. A 12-megapixel industrial color camera is mounted directly above the light source using a bracket. The camera lens is adjusted to be parallel to the light source plane, ensuring the light path is perpendicular. The sample placement area is 40cm away from the light source surface.

[0028] Step 1.2: Synchronously trigger data acquisition.

[0029] The permeable membrane sample is driven at a constant speed through the middle of the camera and the light source by the roll structure of the casting machine. The camera captures the image at a resolution of 4024 × 3036 pixels and transmits the image to the computer in real time via USB 3.0 interface and stores it in PNG format.

[0030] Step 1.3: Image preprocessing preparation.

[0031] The acquired raw images are directly input into the subsequent processing module without additional format conversion, preserving their high signal-to-noise ratio characteristics for algorithm processing.

[0032] Step 2: Image preprocessing.

[0033] In this step, the image acquired in step 1 undergoes light normalization and detail enhancement processing to provide high-quality input for subsequent feature extraction. (Refer to...) Figure 2 As shown, a modified multi-scale Retinex algorithm is specifically used to perform multi-scale Gaussian filtering on the original image, extracting the illumination components at different spatial scales. The original image and the illumination components at each scale are then subtracted in the logarithmic domain to separate the reflection components and enhance image details. The process then proceeds to the following steps: Step 2.1: Single-scale Retinex operation accelerated by SSE instructions.

[0034] After separating the illumination and reflectance components of the input image, the illuminance component is modeled as a Gaussian function, and the reflectance component is modeled as a nonlinear function of illuminance. in, These are the pixel values ​​of the image's illumination components. These are the original image pixel values. Using standard deviation as σ Gaussian convolution kernel, Pixel values ​​representing the image's reflectance component. Three different values ​​are selected. σ This allows us to obtain reflection components at three different scales. The present invention takes... σ= 1, 3, 5.

[0035] The above steps utilize the SSE instruction set for pixel-level parallel acceleration, achieving vectorized processing of single-scale Retinex operations. The specific method is as follows: Step 2.1.1: Convert the Gaussian-filtered image and the original image into 32-bit floating-point format respectively; Step 2.1.2: Traverse the image line by line, and load the image data into the SSE register in batches of 4 pixels. Step 2.1.3: Use SSE internal instructions to perform a logarithmic transformation operation on a batch of pixels in parallel. The calculation formula is: log(x+1.0), where x is the pixel brightness value; Step 2.1.4: In the logarithmic domain, use the SSE subtraction instruction to calculate the difference between the original image and the Gaussian filtered image in parallel. Step 2.1.5: Store the calculation results in batches to the corresponding positions in the target image matrix; Step 2.1.6: Repeat steps 2.1.2 to 2.1.5 until the entire image is processed.

[0036] Step 2.2: Multi-scale feature fusion.

[0037] A weighted fusion strategy is adopted to weight and fuse the enhanced reflection components at each scale, thereby fusing features from different scales into a unified representation, as follows: in, This represents the pixel values ​​of the enhanced image. For the first k The weights of the scale, σ k For the first k The standard deviation of the Gaussian kernel. In this invention... .

[0038] Step 2.3: After multi-scale feature fusion, the color information of the image is lost, therefore, a color restoration operation needs to be performed on the fused result. The specific implementation method for restoring color information is as follows: in, yes The pixel value of the color channel. It enhances the image. The pixel value of the color channel. It is a gain constant used to control the intensity of saturation enhancement. It is a channel balance factor used to adjust the relative weight of each color channel. It is a global gain factor used to control the overall brightness of the output image, and It is a global offset used to control the overall contrast of the output image. This is the final output image.

[0039] Step 3: Multi-scale feature extraction.

[0040] In this step, the preprocessed image is input into a feature extraction network built on the YOLOv10 architecture. Multi-scale features of the image are extracted through the backbone network of this network. These multi-scale features are then used for feature enhancement through a neck network with an MCEA module, thereby constructing a new multi-scale feature-enhanced object detection network. (Refer to...) Figure 3 As shown. The specific implementation method is as follows: The backbone network processes the input image sequentially using a sequential structure. The backbone network comprises three convolutional modules, four C2f modules, two SCDown downsampling modules, one SPPF module, and one PSA attention module. The processing steps are as follows: First, preliminary feature extraction and downsampling are performed using two 3×3 convolutional modules with a stride of 2, resulting in feature maps downsampled by a factor of 2 (P1 layer) and by a factor of 4 (P2 layer). These are then input to the first C2f module, which enhances feature representation while maintaining the number of channels. The short-circuit connection structure effectively alleviates the gradient vanishing problem. The output of the first C2f module is processed through a convolutional module for channel adjustment before being input to the second C2f module. The output of the second C2f module is fed into the neck network and into the first SCDown downsampling module. The SCDown downsampling module employs a spatial-channel collaborative downsampling mechanism, reducing computation while preserving more detailed information, achieving spatial compression and channel expansion. Subsequently, the output of the first SCDown downsampling module passes sequentially through the third C2f module, the second SCDown downsampling module, the fourth C2f module, the SPPF module, and the PSA attention module. The output of the third C2f module is also fed into the neck network. The PSA attention module is introduced at the end of the backbone network to dynamically focus on key region features through multi-scale spatial attention weights.

[0041] The neck network receives multi-scale features from the backbone network (corresponding to feature layers downsampled by 8x, 16x, and 32x, i.e., the outputs of the second and third C2f modules and the PSA attention module), and then performs cross-scale feature fusion using a feature pyramid structure: First, the 32x downsampled feature output from the backbone network (PSA attention module output, P5) is upsampled by 2x and concatenated with the 16x downsampled feature from the backbone network (third C2f module output, P4) along the channel dimension. Then, the C2f module performs feature reshaping to generate fused mesoscale features. Next, this mesoscale feature is upsampled by 2x again and concatenated with the 8x downsampled feature from the backbone network (second C2f module output) along the channel dimension. This is then processed by the C2f module to obtain shallow high-resolution features. After this shallow feature processing, the first MCEA module is embedded to adaptively weight and enhance the P3-scale features along the channel dimension, highlighting local details of micro-defects. Subsequently, the aforementioned shallow features are downsampled using a convolution with a stride of 2, concatenated with the aforementioned mesoscale features, and fused through a C2f module. The fused features are then embedded into a second MCEA module to enhance the multi-scale context awareness capability of the P4-scale features. Further, this feature is downsampled using the SCDown module and concatenated with features downsampled by 32 times from the backbone network, then processed by the C2fCIB module. Then, a third MCEA module is embedded to optimize the global semantic features at the P5 scale, improving robustness to low-contrast defects. Finally, the features enhanced by the three MCEA modules (corresponding to P3, P4, and P5 scales) are input into the detection head (v10Detect) to generate the detection results. This hierarchical design of the entire feature extraction and enhancement process achieves feature capture and adaptive enhancement from local details to global semantics, providing robust feature representations for micro-defect detection.

[0042] Step 4: Multi-scale feature enhancement This step inputs the preliminary multi-scale features extracted in step 3 into the Multi-Scale Channel Enhanced Attention (MCEA) module. Through cross-scale feature fusion and dynamic weight adjustment, the network's ability to perceive micro-defect features is significantly improved. (Refer to...) Figure 4 As shown. The specific implementation process is as follows: Step 4.1 MCEA Module Integration Architecture The MCEA module is embedded into the P3, P4, and P5 feature layers of the feature pyramid network. The MCEA module is immediately connected after feature fusion at each scale, forming a cascaded processing flow of "feature extraction - cross-scale fusion - feature enhancement". Specifically, the first MCEA module is inserted after the P3 / 8 scale feature map, the second module after the P4 / 16 scale feature map, and the third module after the P5 / 32 scale feature map, achieving multi-granularity feature enhancement from local details to global semantics.

[0043] Step 4.2 Multi-scale parallel feature extraction Each MCEA module contains three parallel branches, employing 3×3 and 5×7×7 convolutional kernels for multi-scale feature extraction, respectively. Each branch first expands the input feature channels to twice the original number using a 1×1 convolution, then uses a depthwise separable convolution to extract spatial features while maintaining parameter efficiency, and finally compresses the number of channels to half the original number using a 1×1 convolution. Residual connections are introduced between branches, adding the output of the depthwise convolution to the output of the 1×1 convolution expansion layer, effectively mitigating the vanishing gradient problem.

[0044] Step 4.3 Feature Fusion and Attention Weighting The feature maps output from the three branches are each subjected to global average pooling, concatenated along the channel dimension, and then compressed to the original number of channels via a 1×1 convolution. Subsequently, the channel attention layer generates channel attention weights through two fully connected layers, which are then normalized using a sigmoid activation function and multiplied element-wise with the original input feature map. This process enables the network to adaptively enhance feature channels related to micro-defects while suppressing background interference.

[0045] Step 4.4 Multi-scale collaborative enhancement mechanism The three-scale MCEA modules employ a parameter-sharing attention mechanism, but each processes feature maps at different resolutions: the P3-scale module primarily enhances local features such as edges and textures; the P4-scale module balances details and semantic information; and the P5-scale module focuses on global contextual information. Through this hierarchical enhancement mechanism, the network can capture diverse representations of micro-defects at different scales, significantly improving its robustness to multi-scale defect detection.

[0046] This step, through the aforementioned multi-scale feature enhancement processing, enables the network to maintain high feature discrimination even when faced with low-contrast, small-sized gel defects, laying the foundation for subsequent accurate detection.

[0047] Step 5: Detection Head Design and Predictive Output This step inputs the enhanced multi-scale fusion features into the improved YOLOv10 detection head, achieving high-precision micro-defect detection through a dual-branch structure. The specific implementation method is as follows: The detection head employs a dual-branch parallel architecture, encompassing both one-to-many and one-to-one approaches. The one-to-many branch inherits the standard YOLOv10 detection head structure, comprising three detection layers corresponding to the P3, P4, and P5 feature scales. Each detection layer consists of two 3×3 convolutional layers and a 1×1 convolution, resulting in a final output channel count of (4+1+nc), where 4 represents the bounding box coordinates, 1 represents the object confidence score, and nc represents the number of defect categories.

[0048] The one-to-one branch structure is the same as the one-to-many branch structure, but the parameters are independent, and parameter separation is achieved through deep replication. During the training phase, both branches participate in forward propagation simultaneously: the one-to-many branch generates a large number of candidate boxes, which are matched with the ground truth boxes through a label assignment strategy; the one-to-one branch adopts a simplified optimal transport assignment strategy, directly assigning the optimal label to each anchor point.

[0049] During the inference phase, only the output of one-to-one branches is used for post-processing. The specific process is as follows: First, the predicted bounding boxes are decoded, and the relative coordinates are converted into absolute coordinates; then, the non-maximum suppression (NMS) algorithm is applied, with a confidence threshold of 0.5 and an intersection-over-union (IoU) threshold of 0.7, to remove redundant detection boxes; finally, the output is structured data containing bounding box coordinates, confidence scores, and defect categories.

[0050] Step 6: ProbIoU Loss Function and Model Optimization This step employs the ProbIoU loss function based on probability distribution to perform end-to-end optimization of the entire network. Its core lies in transforming the bounding box regression problem into a similarity metric between Gaussian distributions. The specific implementation is as follows: Step 6.1: Gaussian Bounding Box (GBB) A two-dimensional Gaussian distribution models the probability space range of an object. This distribution is represented by an average vector. =( 0, 0) The covariance matrix Σ is used to characterize the shape, and together they result in the desired elliptical geometry.

[0051] in , , and These are the standard deviations of the x-axis and y-axis, respectively. It is the covariance coefficient. It is the rotation angle. It is a rotation matrix.

[0052] Step 6.2: Probable Intersection over Union (ProbIoU) based on Hellinger distance The ProbIoU metric is based on the Hellinger distance between the predicted and ground-based GBBs. This distance measures the similarity between two probability distributions and is defined as the square root of the sum of the squared differences between their means: in P and Q It is the predicted GBB and the actual ground GBB. It is the Bhattacharyya coefficient between their marginal distributions.

[0053] Step 6.3: ProbIoU Loss Convert the Bhattacharyya distance into the final loss value, supporting two modes: In actual training, L2 mode was used as the default setting, combined with the AdamW optimizer, with an initial learning rate of 0.01, a cosine annealing strategy for learning rate decay, a batch size of 16, and a training cycle of 300 rounds.

[0054] The ProbIoU loss function effectively solves the instability problem of traditional IoU loss in cases of blurred boundaries and extreme aspect ratios by modeling with probability distribution, and significantly improves the accuracy of micro-defect localization.

[0055] In summary, this invention preprocesses breathable membrane images using an improved multi-scale Retinex algorithm to enhance the contrast and visibility of micro-defects; it extracts multi-scale features using a hierarchical feature enhancement network and introduces a multi-scale channel enhanced attention module (MCEA) to perform cross-scale fusion and optimization of features; and it employs the ProbIoU loss function to simultaneously optimize detection accuracy and bounding box regression efficiency, achieving high-precision real-time micro-defect detection and effectively improving the robustness of defect recognition and inference speed in industrial scenarios.

Claims

1. A real-time detection method for micro-defects in breathable membranes based on multi-scale feature enhancement, characterized in that, Includes the following steps: Step 1: Acquire the original image of the breathable membrane to be tested; Step 2: The original image undergoes illumination normalization and detail enhancement processing to obtain a preprocessed image; Step 3: Input the preprocessed image into a feature extraction network built on the YOLOv10 architecture, and extract multi-scale features of the image through the backbone network of the network; Step 4: Input the multi-scale features into the multi-scale channel enhancement attention module to perform channel dimension fusion and weighted enhancement on the feature maps from different scales to obtain the enhanced multi-scale fused features; Step 5: Input the enhanced multi-scale fusion features into the detection head to generate preliminary prediction results of defect categories and bounding boxes; Step 6: Perform end-to-end training on the overall network, which includes the feature extraction network, the multi-scale channel enhanced attention module, and the detection head, until convergence is achieved, and obtain the trained micro-defect detection model. Use this model to perform real-time detection of micro-defects in the breathable membrane.

2. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement as described in claim 1, characterized in that, Step 1 involves acquiring the original image of the breathable membrane using a backlight imaging method, as follows: The breathable membrane sample is placed between a uniform surface light source and an industrial camera. The distance between the sample and the surface light source is adjusted to 30-50 cm, and the sample is kept parallel to the lens of the industrial camera. The brightness of the uniform surface light source is adjustable and is maintained within the range of 3000-5000 lm to ensure uniform and stable transmitted light intensity. The industrial camera is a global shutter color camera with a resolution of 5 million to 12 million pixels, which acquires images with a high signal-to-noise ratio through transmission imaging.

3. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 1, characterized in that, Step 2 involves using an improved multi-scale Retinex algorithm to perform illumination normalization and detail enhancement on the original image. The implementation method is as follows: Step 2.1: Perform multi-scale Gaussian filtering on the original image to extract the illumination components at different spatial scales; Step 2.2: Perform a difference operation between the original image and the illumination components at each scale in the logarithmic domain to separate the reflection components and enhance image details; Step 2.3: Use the SSE instruction set to accelerate the pixel-level operations in steps 2.1 and 2.2 in parallel, and realize the vectorization processing of single-scale Retinex operations; Step 2.4: Weighted fusion of the enhanced reflection components at each scale to balance detail enhancement and global illumination effects; Step 2.5: Perform a color restoration process on the fused result to ensure that the enhanced image retains natural color fidelity.

4. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 3, characterized in that, The implementation method of parallel acceleration using the SSE instruction set in step 2.3 is as follows: Step 2.3.1: Convert the Gaussian-filtered image and the original image into 32-bit floating-point format respectively; Step 2.3.2: Traverse the image line by line, and load the image data into the SSE register in batches of 4 pixels. Step 2.3.3: Use SSE internal instructions to perform a logarithmic transformation operation on a batch of pixels in parallel. The calculation formula is: log(x+1.0), where x is the pixel brightness value; Step 2.3.4: In the logarithmic domain, use the SSE subtraction instruction to calculate the difference between the original image and the Gaussian filtered image in parallel. Step 2.3.5: Store the calculation results in batches to the corresponding positions in the target image matrix; Step 2.3.6: Repeat steps 2.3.2 to 2.3.5 until the entire image is processed.

5. The real-time detection method and system for micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 1, wherein the feature extraction network constructed based on the YOLOv10 architecture in step 3 has a backbone network comprising multiple convolutional modules, C2f modules, SCDown downsampling modules and PSA attention modules, used to extract multi-scale features from the input image.

6. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 1, characterized in that, In step 4, the multi-scale channel enhancement attention module is integrated into the neck network of the feature pyramid network. Specifically, after cross-scale fusion is completed in the feature layers of three different scales with downsampling factors of 8, 16, and 32, a multi-scale channel enhancement attention module is inserted in each of them to adaptively enhance the features under different receptive fields.

7. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 6, characterized in that, The multi-scale channel-enhanced attention module includes multiple parallel multi-scale branches, a feature fusion layer, and a channel attention layer. Each multi-scale branch includes a 1×1 convolutional expansion layer, a depthwise separable convolutional layer, and a 1×1 convolutional compression layer connected in sequence, with a residual connection between the output of the depthwise separable convolutional layer and the output of the 1×1 convolutional expansion layer. The feature fusion layer performs global average pooling on the outputs of the multiple multi-scale branches and concatenates them along the channel dimension, then compresses the number of channels through a 1×1 convolution. The channel attention layer includes two 1×1 convolutional layers with a ReLU activation function between them. The second 1×1 convolutional layer is followed by a Sigmoid activation function. The output of the channel attention layer is multiplied element-wise with the input feature map of the module.

8. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 1, characterized in that, The detection head in step 5 uses an improved YOLOv10 detection head, which includes a parallel one-to-many branch and a one-to-one branch. The one-to-many branch inherits from the standard YOLOv10 detection head structure, and the one-to-one branch contains convolutional modules with the same structure as the one-to-many branch but with independent parameters. During the training phase, both branches output detection results simultaneously. During the inference phase, only the output of the one-to-one branch is used to generate the final bounding box coordinates, confidence scores, and class labels through post-processing operations.

9. The method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement according to claim 1, characterized in that, In step 6, the ProbIoU based on the probability distribution is used as the loss function during training. The calculation method of the loss function includes the following steps: Step 6.1: Convert the predicted bounding boxes and the ground truth bounding boxes into Gaussian distribution representations respectively, and calculate the covariance matrix parameters for each bounding box; Step 6.2: Calculate the probabilistic distance between bounding boxes based on the Bhattacharyya distances of the two Gaussian distributions; Step 6.3: Based on the set distance calculation mode, convert the probability distance into the final loss value, where the L1 mode uses square root transformation and the L2 mode uses logarithmic transformation.

10. A method and system for real-time detection of micro-defects in breathable membranes based on multi-scale feature enhancement, used to implement the real-time detection method for micro-defects in breathable membranes based on multi-scale feature enhancement as described in any one of claims 1 to 9, characterized in that, include: An image acquisition system is used to acquire raw images of the breathable membrane using a backlight imaging method; The image preprocessing module is used to perform illumination normalization and detail enhancement on the original image using an improved multi-scale Retinex algorithm to obtain a preprocessed image. The feature extraction module is used to input the preprocessed image into a feature extraction network built on the YOLOv10 architecture to extract multi-scale features; The feature enhancement module is used to fuse and enhance the multi-scale features through the multi-scale channel enhancement attention module to obtain enhanced multi-scale fused features; The detection module is used to input the enhanced multi-scale fusion features into the detection head, generate the prediction results of defect categories and bounding boxes, and output the micro-defect categories and bounding box coordinates. The training module is used to perform end-to-end optimization of the feature extraction network, the multi-scale channel enhanced attention module, and the detection head by minimizing the probability distribution-based ProbIoU loss function, so as to obtain the trained real-time detection model.