Fabric defect detection method, device and equipment based on ASE-YOLOv11 and medium
By improving the YOLOv11 network structure, the feature extraction and fusion capabilities of the fabric defect detection model are enhanced, solving the detection problem of the YOLOv11 algorithm in complex texture backgrounds and improving the detection accuracy and efficiency of small-sized defects.
Patent Information
- Application Number
- CN202511113139.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-08
- Publication Date
- 2025-11-25
AI Technical Summary
The existing YOLOv11 algorithm has low sensitivity to complex textures and diverse defects in fabric defect detection, high false detection rate, insufficient real-time detection, and difficulty in effectively detecting small-sized defects.
The ASE-YOLOv11 network is adopted. The C2PSA module enhances key features, the Zoom_cat module aligns and fuses features at different resolutions, the SDI module preserves spatial detail information, the EUCB module captures global and local contextual information, the attention model adjusts feature importance, and the ScalSeq module improves multi-scale contextual representation, thereby improving detection accuracy.
The fabric defect detection model has improved the detection accuracy of small-sized defects, enhanced its detection capability in complex scenes and dense targets, reduced information loss, and improved the accuracy and efficiency of detection.
Smart Images

Figure CN121010572A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of computer vision, and particularly relates to a fabric defect detection method and device based on ASE-YOLOv11, equipment and medium. BACKGROUND
[0002] In the research of target detection network, the target detection network taking classification as the main body has large overhead and is difficult to transplant, and thus is inconvenient to popularize, and the YOLOv11 network can use relatively few network parameters to achieve relatively considerable detection performance. However, in the field of fabric defect detection, when facing complex textures and various defects, the related YOLOv11 algorithm still has problems such as low sensitivity, high false detection rate under complex texture background, and insufficient detection real-time performance. SUMMARY
[0003] The purpose of the present application is to provide a fabric defect detection method and device based on ASE-YOLOv11, which can improve the detection accuracy of small size defects.
[0004] To achieve the above purpose, the present application provides the following solutions.
[0005] In a first aspect, the present application provides a fabric defect detection method based on ASE-YOLOv11, comprising:
[0006] obtaining a fabric image to be detected;
[0007] inputting the fabric image to be detected into a trained fabric defect detection model for fabric defect detection; wherein the fabric defect detection model is an ASE-YOLOv11 network, the ASE-YOLOv11 network comprises a backbone network, a neck network and a head network, the backbone network comprises a C2PSA module, a first convolutional module, a C3k2 module, a first module, a second module, a third module and a spatial pyramid pooling module, the neck network comprises a ScalSeq module, an EUCB module, a second convolutional module, a Zoom_cat combination module module, an SDI combination module module and an attention module; the fabric defects include yarn, broken yarn, cotton ball, hole, yarn shedding and stain.
[0008] In a second aspect, the present application provides a fabric defect detection device based on ASE-YOLOv11, comprising:
[0009] The acquisition module is configured to obtain a fabric image to be detected;
[0010] The detection module is configured to input the image of the fabric to be detected into the trained fabric defect detection model to detect fabric defects.
[0011] In a third aspect, the present application provides a computer device, comprising a memory, a processor, a computer program stored in the memory and executable on the processor, and the processor executes the computer program to implement the steps of the fabric defect detection method based on the ASE-YOLOv11 network.
[0012] In a fourth aspect, the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the steps of the fabric defect detection method based on the ASE-YOLOv11 network.
[0013] In a fifth aspect, the present application provides a computer program product, comprising a computer program, and the computer program is executed by a processor to implement the steps of the fabric defect detection method based on the ASE-YOLOv11 network.
[0014] According to the embodiments of the present application, the following technical effects are achieved:
[0015] The application provides a fabric defect detection method and device based on an ASE-YOLOv11, a fabric defect detection equipment and a medium. The ASE-YOLOv11 network is used as a fabric defect detection model, and the fabric defect detection model is used for fabric defect detection on a to-be-detected fabric image. A C2PSA module in the fabric defect detection model can enhance key features, a Zoom_cat combination module can align and fuse more fine and different resolution features, reduce information loss, an SDI combination module can more effectively retain and integrate spatial detail information, guarantee clear details of feature, and thus improve positioning accuracy. An EUCB module can capture and enhance global and local context information in a feature map, so that the fabric defect detection model can more comprehensively understand image content and improve detection capability on complex scenes and dense targets. An attention model dynamically adjusts importance of different feature channels or spatial regions, can more effectively highlight features related to target detection, and a ScalSeq module can improve global scale perception representation and provide rich multi-scale context information. Based on the above network model, detection accuracy of the fabric defect detection model on small size defects can be improved. BRIEF DESCRIPTION OF DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed in the embodiments will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0017] Figure 1 An application environment diagram of a fabric defect detection method based on an ASE-YOLOv11 in an embodiment of the present application;
[0018] Figure 2 A flowchart of a fabric defect detection method based on an ASE-YOLOv11 provided by an embodiment of the present application;
[0019] Figure 3 A structure diagram of an ASE-YOLOv11 network provided by an embodiment of the present application;
[0020] Figure 4 A structure diagram of a YOLOv11 network provided by an embodiment of the present application;
[0021] Figure 5 A structure diagram of a ScalSeq module provided by an embodiment of the present application;
[0022] Figure 6 A structure diagram of an EUCB module provided by an embodiment of the present application;
[0023] Figure 7 A structural schematic diagram of the Zoom_cat module provided by an embodiment of the present application is shown in the following figure.
[0024] Figure 8 A structural schematic diagram of the SDI module provided by an embodiment of the present application is shown in the following figure.
[0025] Figure 9 A functional module schematic diagram of an ASE-YOLOv11-based fabric defect detection device provided by an embodiment of the present application is shown in the following figure.
[0026] Figure 10 A structural schematic diagram of a computer device provided by an embodiment of the present application is shown in the following figure. DETAILED DESCRIPTION
[0027] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of protection of the present application.
[0028] The above purposes, features and advantages of the present application can be more obvious and easy to understand. The present application will be described in further detail below with reference to the drawings and specific embodiments.
[0029] The ASE-YOLOv11-based fabric defect detection method provided by the embodiments of the present application can be applied in an application environment as shown in the following figure. Figure 1 The terminal 102 communicates with the server 104 through a network. The data storage system can store data required to be processed by the server 104. The data storage system can be separately arranged, integrated on the server 104, placed on a cloud or other servers. The terminal 102 can send a fabric image to be detected to the server 104. The server 104 receives the fabric image to be detected. The server 104 inputs the fabric image to be detected into the trained fabric defect detection model to perform fabric defect detection. The server 104 can feed back the obtained fabric defect detection result to the terminal 102. In addition, in some embodiments, the ASE-YOLOv11-based fabric defect detection method can also be implemented by the server 104 or the terminal 102 alone, for example, the terminal 102 can directly perform fabric defect detection on the fabric image to be detected, or the server 104 can obtain the fabric image to be detected from the data storage system and input the fabric image to be detected into the trained fabric defect detection model to perform fabric defect detection.
[0030] The terminal 102 can be, but is not limited to, various desktop computers, notebook computers, smart phones, tablet computers, Internet of Things devices, and portable wearable devices. The Internet of Things device can be a smart speaker, a smart television, a smart air conditioner, a smart vehicle device, etc. The portable wearable device can be a smart watch, a smart bracelet, a head-mounted device, etc. The server 104 can be implemented by a stand-alone server or a server cluster composed of multiple servers, and can also be a cloud server.
[0031] In an exemplary embodiment, as shown in Figure 2 , an ASE-YOLOv11-based fabric defect detection method is provided, which is executed by a computer device, specifically, can be executed by a terminal or a server, or both. In the embodiments of the present application, the method is applied to the server 104 in Figure 1 , including the following steps 201 to 202. Wherein:
[0032] Step 201, obtaining a fabric image to be detected.
[0033] Step 202, inputting the fabric image to be detected into a trained fabric defect detection model for fabric defect detection; wherein the fabric defects include yarns, broken yarns, cotton balls, holes, yarns, and stains.
[0034] The fabric defect detection model is an ASE-YOLOv11 network, which includes a backbone network, a neck network, and a head network. As shown in Figure 3 , the backbone network includes a first convolutional module, a C3k2 module, a first module, a second module, a third module, a spatial pyramid pooling module, and a C2PSA module in sequence. The first module, the second module, and the third module each include a convolutional module and a C3k2 module.
[0035] The backbone network is a feature extractor, the core computing engine of the fabric defect detection model, responsible for extracting multi-scale feature maps with strong semantic information from the input image. Figure 4 The structure of the YOLOv11 network, the backbone network of the YOLOv11 network includes a C2PSA (Cross-Channel Position-aware Spatial Attention) module. The C2PSA module includes a channel attention layer, two convolutional layers, and a product fusion layer. Specifically, the feature map is input into the C2PSA module, the C2PSA module performs channel attention calculation to generate a channel weight vector; at the same time, a spatial attention subnet is used to extract the feature importance in the width-height direction, and the spatial attention subnet is composed of two groups of 1x1 convolution.
[0036] The neck network has the functions of feature fusion and enhancement, is connected between the backbone network and the head network, is responsible for receiving the multi-scale feature maps generated by the backbone network, performing fusion, enhancement and reprocessing on the multi-scale feature maps, and generating a feature map for multi-scale target detection of fabric defects to be transmitted to the head network. The neck network includes a ScalSeq module, an EUCB module, a second convolution module, a Zoom_cat combination module, an SDI combination module and an attention module.
[0037] In the neck network, an additional plurality of 1x1Conv convolution layers are added, which are a second convolution module, a third convolution module and a fourth convolution module. The third convolution module and the fourth convolution module belong to the Zoom_cat combination module. The additional plurality of 1x1Conv convolution layers are used for adjusting the channels and preliminarily processing the corresponding feature maps, so as to prepare for subsequent complex fusion.
[0038] As shown in Figure 5 The ScalSeq (Scale Sequence) module includes a 1x1 convolution layer, a pooling layer, a channel splicing layer and a 3x3 convolution layer. The ScalSeq module adopts a cascaded multi-scale fusion strategy to fuse the shallow details, the middle structure and the deep semantic features output by the backbone network. Specifically, the ScalSeq module receives feature maps of different sizes output by the first module, the second module and the third module in the backbone network, stacks the feature maps of different sizes together through a Stack operation, that is, splices the multi-scale features along the channel dimension, processes the stacked features through 3D convolution for cross-scale fusion, normalizes the output stacked features through a BN (Batch Normalization) module to stabilize the training process and accelerate model convergence, and finally activates the features output by the BN module through a SiLU module for adaptive activation mechanism to enhance the intensity of the normalized features. This design significantly improves the joint detection capability of the fabric defect detection model for small scratches (which rely on high resolution) and large depressions (which rely on semantic information) while maintaining computational efficiency.
[0039] As shown in Figure 6 The EUCB (Efficient Upsampling Convolution Block) module is composed of an upsampling module, a deep convolution enhancement module and a standard convolution module. The deep convolution enhancement module includes a DW (Depthwise Convolution) module, a BN (Batch Normalization) module and a ReLU (Rectified Linear Unit) module. The core operations of the EUCB module include the following three, specifically (1)-(3).
[0040] (1) Upsampling operation: The scale of the input feature map is increased by a factor of 2 to match the resolution of subsequent skip connections. For low-resolution input features... Figure X ∈R C×W×H First, perform 2× bilinear interpolation or learnable upsampling to expand the spatial size to 2W×2H, aligning it with the skip connection features in the spatial dimension, resulting in: X up ∈R C×2W×2H , where X up Here, C represents the feature map obtained from upsampling, W represents the width of the feature map, and H represents the height of the feature map.
[0041] (2) Depthwise Convolution Enhancement: A 3×3DW module is applied to the upsampling result. The feature map input to the DW module is the feature map obtained by the upsampling module, which is then passed through the BN module and the ReLU module in sequence. Finally, the output feature map is input to the standard convolution module. The expression is:
[0042] Y = ReLU(BN(DWConv) 3×3 (X up )));
[0043] Where Y is the feature map output by the ReLU module, and DWConv 3×3 It is a 3×3 depth-separable convolutional module.
[0044] (3) Channel compression: While maintaining the spatial size, the number of channels is compressed from C to C' (C' is set to C / 2) by 1×1 standard convolution, so that the number of channels of the feature map after channel compression matches the number of channels in the next stage, and the final enhanced features are generated.
[0045] In the YOLOv11 neck network, nearest neighbor upsampling (nn.Upsample) combined with simple channel concatenation (Concat) is typically used to fuse feature maps of different scales. This paper replaces the nearest neighbor upsampling and feature concatenation operations in the YOLOv11 neck network with the Zoom_cat module.
[0046] In an example embodiment, the Zoom_cat combination module module includes a first Zoom_cat combination module and a second Zoom_cat combination module, the SDI combination module module includes a first SDI combination module and a second SDI combination module, the first Zoom_cat combination module includes a third convolution module, a Zoom_cat module and a C3k2 module; the second Zoom_cat combination module includes a fourth convolution module, a Zoom_cat module and a C3k2 module; the first SDI combination module includes a fifth convolution module, an SDI module and a C3k2 module; and the second SDI combination module includes a sixth convolution module, an SDI module and a C3k2 module.
[0047] As shown in Figure 7 Zoom_cat module receives three feature maps of different scales (large, medium and small), adjusts the size of the large-scale feature map to be the same as the medium-scale feature map through adaptive max-pooling and average-pooling, and adjusts the size of the small-scale feature map to be the same as the medium-scale feature map using the nearest neighbor interpolation method. Then, the three adjusted feature maps are spliced along the channel dimension to fuse the information of different scales. The feature map output by the Zoom_cat module is subjected to nonlinear transformation by the C3k2 module to obtain the output feature map. The introduction of the Zoom_cat module aims to align and fuse features of different resolutions through a more fine mechanism (such as implicit feature transformation or weighting), thereby reducing information loss and improving fusion efficiency.
[0048] In the original YOLOv11 neck network, the features of different paths are usually fused through simple channel splicing (Concat) after downsampling. In the present embodiment, an SDI (Spatial Detail Integration) module is introduced to replace the original Concat operation. The SDI module is a key component in deep learning for enhancing the feature representation capability, and is mainly applied to multi-modal fusion, 3D vision tasks (such as point cloud processing, depth estimation) and cross-dimensional feature interaction scenarios; the core goal of the SDI module is to improve the model's understanding of complex scenes by modeling the interaction between spatial dimensions (2D plane information) and depth dimensions (3D geometric information).
[0049] The SDI module in the present embodiment improves the semantic understanding of fabric texture and structure by the fabric defect detection model, enhances the detection of fine details, reduces the number of false negatives and improves the overall detection accuracy.
[0050] As shown in Figure 8 The SDI module is composed of the following six parts, specifically 1-6:
[0051] 1. Upsampling: The SDI module uses upsampling to increase the resolution of lower-level feature maps to match the resolution of different feature maps. For lower-level features... Figure X low ∈R C×2W×2H First, perform a 2x upsampling to obtain a feature map with the same spatial size as the current layer: X up =Interp2x(X low )∈R C×2W×2H Where C is the number of channels, W is the width of the feature map, H is the height of the feature map, and Interp2x(·) is a 2x upsampling.
[0052] 2. Identity Mapping: The SDI module directly passes the mid-level feature map through identity mapping. Identity mapping ensures that the mid-level features do not undergo any transformation, avoiding the blurring effect caused by upsampling and the details caused by downsampling, thus maintaining the original details and semantic integrity. The feature images of identity mapping do not participate in attention weighting.
[0053] 3. Downsampling: The SDI module uses downsampling to reduce the resolution of higher-level feature maps to align with the current level. This applies to features from higher levels... Figure X high Perform a 2x downsampling to match the spatial dimensions of the current level: X down =Conv 3×3,s=2 (X high )∈R C×2W×2H Where s is the stride of the convolution.
[0054] 4. Attention Fusion: Spatial and channel attention mechanisms are applied to further refine features, ensuring that the fabric defect detection model focuses on the most relevant parts of the feature map for defect detection. Specifically, the upsampled detail features X are further refined. up and the downsampled semantic features X down Apply channel attention and spatial attention to highlight important features.
[0055]
[0056] Among them, f chan f spa These represent the channel attention and spatial attention subnetworks, respectively, where σ is the sigmoid activation. This indicates element-wise multiplication.
[0057] 5. Smoothing Convolution: Accepts the attention weights output by the attention fusion mechanism and outputs smoothed weights through smoothing convolution to eliminate noise in the weight map, while keeping the weight feature image size unchanged.
[0058] 6. Feature integration: the two attention weighted features are fused by Hadamard product. represents element-wise addition, the fused feature map F is compressed by 1x1 convolution to reduce the channel and output to the subsequent head network.
[0059]
[0060] The head network is used to predict the final detection result by directly converting the high-quality features provided by the neck network.
[0061] Before training the fabric defect detection model, steps 301-304 are further included:
[0062] Step 301, data screening.
[0063] The data comes from the public Tianchi platform and the fabric images collected on site in a certain textile workshop in a certain city. Invalid images with uneven and poor quality such as overall data blur, overexposure caused by shooting operation failure, different shooting environment or repeated collection are excluded, and valid sample images are retained.
[0064] Step 302, data labeling.
[0065] The LabelImg tool is used to label the defect area in the valid sample image with a rectangular frame. The labeling information includes fabric defect category, bounding box, center coordinates (x, y) of the bounding box, and width and height measurements.
[0066] Step 303, image data standardization.
[0067] The input labeled valid sample image is uniformly scaled to 640x640 resolution, and normalization processing is performed to make the image features similar.
[0068] Step 304, data augmentation.
[0069] Random horizontal flipping, rotation, brightness adjustment, color change and their combination are used to expand the number of valid sample images.
[0070] The expanded data set is divided into training set, validation set and test set in a given proportion, and the proportion of the training set, validation set and test set is 8:1:1.
[0071] The paths of the training set and the validation set and the path of the initial training weight file are input into the parameters required for training the ASE-YOLOv11 model to obtain the trained ASE-YOLOv11 model, and the trained ASE-YOLOv11 model is exported for deployment to an industrial detection device.
[0072] The sample data in the test set is taken as input, the fabric defect detection is performed on the ASE-YOLOv11 model after training, the fabric defect detection result is output, and the performance of the ASE-YOLOv11 model is evaluated. The precision (P), recall (R), average precision (AP), average precision (mAP), and weighted harmonic mean are used as the ASE-YOLOv11 model effect evaluation indexes.
[0073] The calculation formula of the precision P is as follows:
[0074]
[0075] Among them, TP represents that the positive class target is correctly predicted as positive; and FP represents that the negative class target is incorrectly predicted as positive.
[0076] The calculation formula of the recall R is as follows:
[0077]
[0078] Among them, FN represents that the negative class target is correctly determined as negative.
[0079] For each detected fabric defect category, the area under the precision-recall curve is calculated, that is, the average precision AP; the average value of the AP values of all categories is obtained, that is, the average precision mean mAP, and the calculation formula of the mAP value is as follows:
[0080]
[0081] Among them, Q is the total number of categories, AP q is the average precision of category q.
[0082] In an example embodiment, step 202 specifically includes steps 401-403:
[0083] Step 401, input the fabric image to be detected into the backbone network for feature extraction to obtain feature maps of different scales.
[0084] Step 402, the feature maps of different scales are extracted and fused by the neck network to obtain triple-scale features.
[0085] Step 403, the triple-scale features are input into the head network for fabric defect detection.
[0086] In an example embodiment, the feature maps of different scales include feature map P1, feature map P2, feature map P3, feature map P4, feature map P5, and feature map P6; and step 401 specifically includes steps 501-504:
[0087] Step 501, input the fabric image to be detected into a convolution module for feature extraction to obtain a feature map P1.
[0088] Step 502, input the feature map P1 into the C3k2 module, the first module, the second module and the third module in sequence for feature extraction to obtain a feature map P2, a feature map P3, a feature map P4 and a feature map P5 respectively.
[0089] Step 503, input the feature map P5 into a spatial pyramid pooling module for feature extraction to obtain a spatial fusion feature map.
[0090] Step 504, input the spatial fusion feature map into a C2PSA module for feature extraction to obtain a feature map P6.
[0091] In an example embodiment, the triple-scale features include first, second and third scale features; and step 402 specifically includes steps 601-608.
[0092] Step 601, input the feature map P6 into the second convolution module for feature extraction to obtain a feature map P7.
[0093] Step 602, input the feature map P1, the feature map P3, the feature map P4 and the feature map P7 into a first Zoom_cat combination module for feature fusion and feature extraction to obtain a feature map P8.
[0094] Step 603, input the feature map P8 into an EUCB module for feature extraction to obtain a feature map P9.
[0095] Step 604, input the feature map P2, the feature map P3 and the feature map P8 into a second Zoom_cat combination module for feature fusion and feature extraction to obtain a feature map P10.
[0096] Step 605, input the feature map P9 and the feature map P10 into a first SDI combination module for feature splicing and feature extraction to obtain the first scale feature.
[0097] Step 606, input the feature map P3, the feature map P4 and the feature map P5 into a ScalSeq module for feature fusion to obtain a feature map P11.
[0098] Step 607, input the feature map P11 and the feature map P9 into an attention module for adaptive weighting of features to obtain the second scale feature.
[0099] Step 608, input the feature map P7 and the first scale feature into a second SDI combination module for feature splicing and feature extraction to obtain the third scale feature.
[0100] The trained ASE-YOLOv11 network is used as a fabric defect detection model, and the fabric defect detection model is used for fabric defect detection of the to-be-detected fabric image, so as to improve the detection accuracy of the fabric defect detection model for small-size defects.
[0101] Based on the same inventive concept, the embodiments of the present application also provide a device for implementing the above-mentioned fabric defect detection method based on ASE-YOLOv11. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme described in the above method, so the specific limitations in one or more fabric defect detection device embodiments based on ASE-YOLOv11 provided below can refer to the limitations of the fabric defect detection method based on ASE-YOLOv11 described above, which will not be repeated here.
[0102] In one exemplary embodiment, as shown in Figure 9 A fabric defect detection device based on ASE-YOLOv11 is provided, which includes:
[0103] The acquisition module 91 is configured to acquire a to-be-detected fabric image.
[0104] The detection module 92 is configured to input the to-be-detected fabric image into the trained fabric defect detection model for fabric defect detection. The fabric defect detection model is an ASE-YOLOv11 network, which includes a backbone network, a neck network, and a head network. The neck network includes a ScalSeq module, an EUCB module, a second convolution module, a Zoom_cat combination module module, an SDI combination module module, and an attention module. The fabric defects include yarns, broken yarns, cotton balls, holes, yarns, and stains.
[0105] In an exemplary embodiment, a computer device is provided, which can be a server or a terminal, and its internal structure diagram can be as shown in Figure 10As shown in the figure. The computer device includes a processor, a memory, an input / output interface (I / O for short) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through the system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capability. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used for the fabric image to be detected. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with the terminal outside through the network connection. The computer program is executed by the processor to realize the fabric defect detection method based on ASE-YOLOv11.
[0106] Those skilled in the art can understand that, Figure 10 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.
[0107] In one exemplary embodiment, a computer device is also provided, including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to realize the steps in each of the above method embodiments.
[0108] In one exemplary embodiment, a computer readable storage medium is provided, storing a computer program, which is executed by a processor to realize the steps in each of the above method embodiments.
[0109] In one exemplary embodiment, a computer program product is provided, including a computer program, which is executed by a processor to realize the steps in each of the above method embodiments.
[0110] It should be noted that the user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant regulations.
[0111] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when the computer program is executed, the processes of the above-mentioned embodiments of the methods can be included. Any reference to memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (Read-Only Memory, ROM), magnetic tape, floppy disk, flash memory, optical storage, high-density embedded non-volatile memory, resistive memory (ReRAM), magnetoresistive random access memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric memory (Ferroelectric Random Access Memory, FRAM), phase change memory (Phase Change Memory, PCM), graphene memory, etc. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, etc. As an illustration but not limitation, RAM can be in various forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), etc.
[0112] The database involved in the embodiments provided in the present application can include at least one of a relational database and a non-relational database. The non-relational database can include a distributed database based on a blockchain, etc., without being limited thereto. The processor involved in the embodiments provided in the present application can be a general-purpose processor, a central processing unit, a graphics processing unit, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., without being limited thereto.
[0113] The technical features of the above embodiments can be combined arbitrarily. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described, but as long as the combinations of the technical features do not exist contradictory, they should be considered as the scope of the present application.
[0114] The principles and implementation modes of the present application are described by applying specific examples in the present application. The above embodiment description is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, the specific implementation mode and application range will be changed. In conclusion, the content of the present application should not be understood as a limitation.
Claims
1. A fabric defect detection method based on ASE-YOLOv11, characterized in that, include: Acquire an image of the fabric to be inspected; The fabric image to be detected is input into the trained fabric defect detection model for fabric defect detection; wherein, the fabric defect detection model is an ASE-YOLOv11 network, which includes a backbone network, a neck network, and a head network. The neck network includes a ScalSeq module, an EUCB module, a second convolution module, a Zoom_cat combined module module, an SDI combined module module, and an attention module; fabric defects include yarn residue, broken yarn, cotton balls, holes, detached yarn, and stains.
2. The fabric defect detection method based on ASE-YOLOv11 according to claim 1, characterized in that, The fabric image to be detected is input into the trained fabric defect detection model for fabric defect detection, specifically including: The image of the fabric to be detected is input into the backbone network for feature extraction to obtain feature maps at different scales. The neck network is used to extract and fuse features from feature maps of different scales to obtain triple-scale features. The triple-scale features are input into the head network for fabric defect detection.
3. The fabric defect detection method based on ASE-YOLOv11 according to claim 1, characterized in that, The feature maps of different scales include feature map P1, feature map P2, feature map P3, feature map P4, feature map P5 and feature map P6; the backbone network includes a C2PSA module, a first convolutional module, a C3k2 module, a first module, a second module, a third module and a spatial pyramid pooling module; The image of the fabric to be detected is input into the backbone network for feature extraction, resulting in feature maps at different scales, including: The image of the fabric to be detected is input into the first convolution module for feature extraction to obtain feature map P1; The feature map P1 is sequentially input into the C3k2 module, the first module, the second module, and the third module for feature extraction, resulting in feature maps P2, P3, P4, and P5, respectively. The feature map P5 is input into the spatial pyramid pooling module for feature extraction to obtain a spatial fusion feature map. The spatial fusion feature map is input into the C2PSA module for feature extraction to obtain feature map P6.
4. The fabric defect detection method based on ASE-YOLOv11 according to claim 3, characterized in that, The Zoom_cat combination module includes a first Zoom_cat combination module and a second Zoom_cat combination module. The SDI combination module includes a first SDI combination module and a second SDI combination module. The first Zoom_cat combination module includes a third convolution module, a Zoom_cat module, and a C3k2 module. The second Zoom_cat combination module includes a fourth convolution module, a Zoom_cat module, and a C3k2 module. The first SDI combination module includes a fifth convolution module, an SDI module, and a C3k2 module. The second SDI combination module includes a sixth convolution module, an SDI module, and a C3k2 module.
5. The fabric defect detection method based on ASE-YOLOv11 according to claim 4, characterized in that, The triple-scale feature includes a first-scale feature, a second-scale feature, and a third-scale feature; Specifically, the neck network is used to extract and fuse features from feature maps of different scales to obtain three-scale features, including: The feature map P6 is input into the second convolution module for feature extraction to obtain the feature map P7; The feature maps P1, P3, P4, and P7 are input into the first Zoom_cat combination module for feature fusion and feature extraction to obtain feature map P8; Input feature map P8 into the EUCB module to extract features and obtain feature map P9; Feature maps P2, P3, and P8 are input into the second Zoom_cat combination module for feature fusion and feature extraction to obtain feature map P10. Feature maps P9 and P10 are input into the first SDI combination module for feature splicing and feature extraction to obtain the first scale feature. Feature maps P3, P4, and P5 are input into the ScalSeq module for feature fusion to obtain feature map P11. The feature maps P11 and P9 are input into the attention module to perform adaptive weighting of the features to obtain the second-scale features. The feature map P7 and the first scale feature are input into the second SDI combination module for feature splicing and feature extraction to obtain the third scale feature.
6. The fabric defect detection method based on ASE-YOLOv11 according to claim 1, characterized in that, The ScalSeq module includes a 1×1 convolutional layer, a pooling layer, a channel splicing layer, and a 3×3 convolutional layer; the C2PSA module includes a channel attention layer, two convolutional layers, and a product fusion layer; the EUCB module includes an upsampling layer, a depthwise convolutional layer, a batch normalization layer, a corrected linear layer, and a convolutional layer.
7. A fabric defect detection device based on ASE-YOLOv11, characterized in that, include: The acquisition module is used to acquire images of the fabric to be detected. The detection module is used to input the image of the fabric to be detected into the trained fabric defect detection model for fabric defect detection; wherein, the fabric defect detection model is an ASE-YOLOv11 network, which includes a backbone network, a neck network, and a head network. The neck network includes a ScalSeq module, an EUCB module, a first convolution module, a Zoom_cat combined module module, an SDI combined module module, and an attention module; fabric defects include yarn residue, broken yarn, cotton balls, holes, detached yarn, and stains.
8. A computer device, comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the fabric defect detection method based on ASE-YOLOv11 as described in any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the fabric defect detection method based on ASE-YOLOv11 as described in any one of claims 1-6.
10. A computer program product, comprising a computer program, characterized in that, When executed by a processor, the computer program implements the fabric defect detection method based on ASE-YOLOv11 as described in any one of claims 1-6.
Citation Information
Cited By
Unmanned aerial vehicle bridge crack detection method based on structure perception cross-modal fusion, electronic equipment, computer readable storage medium and program
CN122134725A
An unmanned aerial vehicle bridge crack detection method based on structure perception cross-modal fusion, electronic equipment, computer readable storage medium and program
CN122134725B