Improved YOLO11s-based insulator defect detection method in snowy day weak light environment
By improving the brightness adjustment, adaptive Gamma correction and feature extraction methods of the YOLO11s model, the accuracy and stability of insulator defect detection in low-light environments in snowy days are solved, and are suitable for insulator detection of drone platforms.
Patent Information
- Application Number
- CN202511008247.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-22
- Publication Date
- 2025-08-22
- Estimated Expiration
- 2045-07-22
AI Technical Summary
The traditional YOLO11s model cannot effectively capture image detail features in low-light environments on snowy days, resulting in poor insulator defect detection accuracy and stability.
The image brightness is adjusted through the camera exposure formula, combined with the adaptive Gamma correction network, the SPD convolution module and the MPDIOU loss function, and the YOLO11s model is improved to form the SPD-YOLO11s object detection network for training and verification.
It improves the accuracy and stability of insulator defect detection in low-light conditions in snowy days, is suitable for drone platform deployment, reduces computing resource requirements, and improves detection efficiency.
Smart Images

Figure CN120525869A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the technical field of insulator defect detection, and in particular relates to an insulator defect detection method in a snowy and weak light environment based on an improved YOLO11s. Background Art
[0002] With the continuous development of power systems, the reliability and safety of power equipment have become increasingly important. Insulators are a crucial component of power systems, and their condition is directly related to the stability of power transmission. Traditional insulator inspection methods rely primarily on manual inspections and traditional image processing techniques. These methods are not only labor-intensive but also subject to environmental factors (such as weather and lighting) and the limitations of manual operation, resulting in high rates of missed detections and false detections. Therefore, the development of automated, intelligent insulator defect detection methods is crucial. In recent years, with the advancement of drone and computer vision technologies, drone-based insulator inspection has garnered widespread attention. Drone inspections not only enable rapid coverage of large power line areas but also enable inspections in snowy conditions. However, in snowy conditions, poor lighting and complex backgrounds often result in dark images, posing significant challenges for defect detection.
[0003] In related technologies, when the traditional YOLO11s model processes images in low-light environments on snowy days, its feature extraction capability is limited and it cannot fully capture the detailed features in the image, resulting in poor detection accuracy and stability. Summary of the Invention
[0004] The embodiments of the present application provide a method, apparatus, terminal device, and storage medium for detecting insulator defects in a low-light environment on snowy days based on an improved YOLO11s. This method can solve the problem that when a traditional YOLO11s model processes images in a low-light environment on snowy days, its feature extraction capability is limited and it cannot fully capture the detailed features in the image, resulting in poor detection accuracy and stability.
[0005] In a first aspect, an embodiment of the present application provides an insulator defect detection method in a snowy and weak-light environment based on an improved YOLO11s, comprising: adjusting the brightness of a first insulator image dataset collected using a camera exposure formula to form a second insulator image dataset, wherein the first insulator image dataset is an insulator image dataset collected by a drone; performing brightness processing on the second insulator image dataset using an adaptive Gamma correction network to obtain a third insulator image dataset; introducing an SPD convolution module and an MPDIOU loss function into a YOLO11 network to obtain an SPD-YOLO11s target detection network model; training the SPD-YOLO11s target detection network model using the third insulator image dataset to obtain an optimal weight pt; and detecting insulator defects using the SPD-YOLO11s target detection network model with the optimal weight pt.
[0006] In a possible implementation of the first aspect, performing brightness processing on the second insulator image dataset using an adaptive gamma correction network to obtain a third insulator image dataset includes: Calculate the average brightness of the image based on the total number of image pixels and the pixel value of each grayscale image in the second insulator image dataset :
[0007] in, is the value of each pixel in the grayscale image, and N is the total number of pixels in the image; Dynamically adjust the Gamma value based on the average brightness :
[0008] in, is the minimum value of Gamma, is the maximum value of Gamma, is the target brightness value; The pixel value I(i) of each image is corrected using the Gamma value to obtain the third insulator image dataset; wherein, The pixel value I(i) of each image is corrected using the Gamma value, specifically:
[0009] in, It is the pixel value after Gamma correction.
[0010] Optionally, in another possible implementation of the first aspect, the SPD convolution module and the MPDIOU loss function are introduced into the YOLO11 network to obtain the SPD-YOLO11s target detection network model, including: In the backbone feature extraction module of the YOLO11 network, all the original convolution downsampling structures are replaced with SPD convolution modules; In the loss function module of the YOLO11 network, the original CIoU loss function is replaced by the MPDIoU loss function to obtain the SPD-YOLO11s target detection network model.
[0011] Optionally, in another possible implementation of the first aspect, the calculation process of the MPDIoU loss function is as follows:
[0012]
[0013]
[0014]
[0015]
[0016] in, and Respectively represent the upper left corner coordinates and lower right corner coordinates of the real box, and Respectively represent the coordinates of the upper left corner and lower right corner of the prediction box, Indicates the distance between the upper left corner of the real box and the upper left corner of the predicted box, Represents the distance between the lower right corner of the real box and the lower right corner of the predicted box, h and w represent the width and height of the image respectively, and IoU represents the intersection-over-union loss. A is the area of the prediction box, is the area of the real box, is the objective function used to minimize the MPDIoU loss.
[0017] Optionally, in another possible implementation of the first aspect, after the SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt, the method further includes: The optimal weight pt is used to verify the SPD-YOLO11s target detection network model.
[0018] Optionally, in another possible implementation of the first aspect, the verification of the SPD-YOLO11s target detection network model using the optimal weight pt includes: A preset part of the third insulator image dataset is used as a validation set, and the validation set is input into the SPD-YOLO11s model, and the optimal weight pt is used for inference; Calculate multiple evaluation metrics on the validation set to assess the performance of the model.
[0019] In a second aspect, an embodiment of the present application provides an insulator defect detection device in a snowy and weak-light environment based on an improved YOLO11s, including: an adjustment module for adjusting the brightness of a first insulator image data set collected using a camera exposure formula to form a second insulator image data set, wherein the first insulator image data set is an insulator image data set collected by a drone; a correction module for performing brightness processing on the second insulator image data set using an adaptive Gamma correction network to obtain a third insulator image data set; an acquisition module for introducing an SPD convolution module and an MPDIOU loss function into the YOLO11 network to obtain an SPD-YOLO11s target detection network model; a training module for training the SPD-YOLO11s target detection network model using the third insulator image data set to obtain an optimal weight pt; and a detection module for detecting insulator defects using the SPD-YOLO11s target detection network model with the optimal weight pt.
[0020] In a third aspect, an embodiment of the present application provides a terminal device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the insulator defect detection method in a snowy and weak-light environment based on the improved YOLO11s as described above is implemented.
[0021] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the insulator defect detection method in a snowy and weak light environment based on the improved YOLO11s as described above is implemented.
[0022] Beneficial effects: The solution of the present application first uses the camera exposure formula to adjust the brightness of the first collected insulator image dataset to form a second insulator image dataset. The first insulator dataset is the insulator image dataset collected by the drone. The second insulator image dataset is then brightness-processed using the adaptive gamma correction network to obtain a third insulator image dataset. The SPD convolution module and MPDIOU loss function are introduced into the YOLO11 network to obtain the SPD-YOLO11s target detection network model. The SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt. The SPD-YOLO11s target detection network model of pt is then used to detect insulator defects. The present application effectively improves the accuracy and stability of insulator defect detection under weak light conditions on snowy days, providing reliable technical support for the safe operation of the power system. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the embodiments or descriptions of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0024] Figure 1 This is a flow chart of an insulator defect detection method in a snowy and weak light environment based on improved YOLO11s provided in one embodiment of the present application; Figure 2 1 is a schematic diagram of the structure of the YOLO11 model provided in one embodiment of the present application; Figure 3 This is a schematic diagram of the structure of the SPD-YOLO11s target detection network model provided in one embodiment of the present application; Figure 4 Schematic diagram of the structure of the SPD convolution module provided in one embodiment of the present application; Figure 5 2 is a schematic diagram of calculating the MPDIoU loss function provided in one embodiment of the present application; Figure 6 1 is a schematic structural diagram of an insulator defect detection device in a snowy and weak light environment based on an improved YOLO11s according to an embodiment of the present application; Figure 7 It is a structural diagram of the terminal device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0025] In the following description, specific details such as specific system structures and techniques are provided for purposes of illustration rather than limitation to facilitate a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to avoid obscuring the description of the present application with unnecessary detail.
[0026] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or collections thereof.
[0027] It will also be understood that the term "and / or" used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0028] As used in this specification and the appended claims, the term "if" can be interpreted as "when" or "upon" or "in response to determining" or "in response to detecting," depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "upon determination" or "in response to determining" or "upon detection of [described condition or event]" or "in response to detecting [described condition or event]," depending on the context.
[0029] In addition, in the description of this application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0030] References to "one embodiment" or "some embodiments" in this specification mean that a particular feature, structure, or characteristic described in conjunction with that embodiment is included in one or more embodiments of the present application. Thus, phrases such as "in one embodiment," "in some embodiments," "in other embodiments," and "in yet other embodiments" that appear in various places throughout this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically stated. The terms "including," "comprising," "having," and variations thereof mean "including but not limited to," unless otherwise specifically stated.
[0031] The following describes in detail an insulator defect detection method, apparatus, terminal equipment, and storage medium in a snowy and weak light environment based on an improved YOLO11s provided in this application with reference to the accompanying drawings.
[0032] Figure 1 A flow chart of an insulator defect detection method in a snowy and weak light environment based on improved YOLO11s according to an embodiment of the present application is shown.
[0033] like Figure 1 As shown in FIG, the insulator defect detection method based on the improved YOLO11s in a snowy and weak light environment specifically includes the following steps: S1. Using a camera exposure formula, adjust the brightness of a first insulator image dataset to form a second insulator image dataset, where the first insulator image dataset is an insulator image dataset collected by a drone. In one embodiment, an insulator image dataset from the dataset website Roboflow is screened, and insulator images taken by a drone are selected to form a first insulator dataset. Then, a camera exposure formula is used to adjust the brightness of the first insulator dataset to simulate insulator images taken by a drone in a low-light environment on a snowy day to form a second insulator image dataset.
[0034] S2. Perform brightness processing on the second insulator image dataset using an adaptive gamma correction network to obtain a third insulator image dataset; It should be noted that the adaptive gamma correction network primarily enhances image clarity and detail in low-light environments like snow and snow by dynamically adjusting image brightness and contrast. This network calculates the image's average brightness and adaptively adjusts the gamma value based on the target brightness, effectively mitigating the effects of low light and noise. This network enhances visual information and restores subtle features, providing clearer and more accurate input images for the subsequent SPD-YOLO11s object detection network model, thereby improving object detection performance and stability.
[0035] The original Gamma brightness correction formula is described as follows:
[0036] in is the input image which is pixel values (range 0 to 255), is the pixel value of the output image after Gamma correction. Gamma value is used to control the brightness adjustment of the image. It will darken the image. Gamma correction brightens the image. Gamma correction adjusts the pixel values of an image nonlinearly to enhance or suppress details within a specific brightness range.
[0037] Original gamma correction suffers from shortcomings such as fixed gamma values, inability to adapt to complex scenes, global adjustments, and sensitivity to noise. Because it uses a fixed gamma value and global brightness adjustment, it cannot flexibly address brightness differences across image regions. This can lead to loss of image detail or increased noise, especially in low-light or high-noise environments. Therefore, the adaptive gamma correction network was developed. By dynamically adjusting the gamma value and optimizing based on changes in image brightness and contrast, it more effectively enhances image quality and provides clearer and more stable input for subsequent object detection tasks.
[0038] Furthermore, in the embodiment of the present application, the above step S2 includes: Calculate the average brightness of the image based on the total number of image pixels and the pixel value of each grayscale image in the second insulator image dataset :
[0039] in, is the value of each pixel in the grayscale image, and N is the total number of pixels in the image; Dynamically adjust the Gamma value based on the average brightness :
[0040] in, is the minimum value of Gamma, is the maximum value of Gamma, is the target brightness value; The pixel value I(i) of each image is corrected using the Gamma value to obtain the third insulator image dataset; wherein, The pixel value I(i) of each image is corrected using the Gamma value, specifically:
[0041] in, It is the pixel value after gamma correction.
[0042] Through the above formula, the image brightness can be dynamically adjusted according to the original brightness of each image.
[0043] S3. Introduce the SPD convolution module and MPDIOU loss function into the YOLO11 network to obtain the SPD-YOLO11s target detection network model; YOLO11 is a single-stage target detection algorithm. YOLO11 introduces the C3k2 mechanism and replaces the original C2f module with the C3k2 module to enhance the feature extraction capability. In addition, the C2PSA module is added after the SPPF (Spatial Pyramid Pooling Fast) module to further enhance the expressiveness of the model. In the decoupling head design, YOLO11 replaces the convolution operations inside the classification and detection heads with depthwise separable convolutions, effectively reducing the number of parameters and computational complexity while maintaining the high performance of the model. According to the number of parameters and complexity, YOLO11 has five versions: n, s, m, l, and x, which can adapt to application hardware with different performance. Figure 2 As shown in the figure, it is the model structure diagram of YOLO11.
[0044] Furthermore, in the embodiment of the present application, the above step S3 includes: S31. In the backbone feature extraction module of the YOLO11 network, all the original convolution downsampling structures are replaced with SPD convolution modules. Lightweight is crucial for computing tasks deployed on drones, as drone platforms typically have limited computing resources, storage space, and energy supply. Complex deep learning models require a lot of computing resources, and overly large models can cause delays, affecting real-time processing capabilities. At the same time, with limited storage space, traditional models may not be fully deployed, and high energy consumption will accelerate battery depletion, affecting flight time and mission completion efficiency. Lightweight design can improve system performance and resource utilization efficiency by reducing the amount of computation, lowering storage requirements, and optimizing energy consumption, thereby ensuring efficient and accurate task execution on drone platforms. To this end, this application introduces the SPD convolution module to replace the convolution module of the original YOLO11 network backbone. As Figure 3 As shown in Figure 1, it is a structural diagram of the SPD-YOLO11s target detection network model.
[0045] like Figure 4 The figure shows the schematic diagram of the SPD convolution module. SPD convolution abandons the stride convolution and pooling operations widely used in traditional convolution. Consider any size The intermediate feature map X is cut out into a series of sub-maps. When the scale is 2, the four sub-mapping formulas are as follows:
[0046] The size of each subgraph is , by downsampling the feature map X by a factor of 2, convolving these downsampled sub-maps with a non-strided convolution layer, and finally recombining the convolved sub-maps into a new feature map. The SPD convolution module does not lose learnable information during the downsampling process, while also avoiding strided convolution and pooling operations, improving the model's detection performance for low-resolution images and small objects.
[0047] S32. In the loss function module of the YOLO11 network, the original CIoU loss function is replaced by the MPDIoU loss function to obtain the SPD-YOLO11s target detection network model.
[0048] The SPD-YOLO11s target detection network abandons the CIoU loss function used by the original YOLO11 model and introduces the MPDIoU loss function. Figure 5 The figure shows the calculation diagram of MPDIoU.
[0049] MPDIoU is a novel bounding box similarity comparison metric based on minimum point distance, which directly minimizes the top-left and bottom-right point distances between the predicted bounding box and the ground-truth bounding box. MPDIoU incorporates all relevant factors considered in existing loss functions, namely overlapping or non-overlapping areas, center point distance, and width-height deviation, while simplifying the calculation process.
[0050] Specifically, the calculation process of the MPDIoU loss function in step S32 is as follows:
[0051]
[0052]
[0053]
[0054]
[0055] in, and Respectively represent the upper left corner coordinates and lower right corner coordinates of the real box, and Respectively represent the coordinates of the upper left corner and lower right corner of the prediction box, Indicates the distance between the upper left corner of the real box and the upper left corner of the predicted box, Represents the distance between the lower right corner of the real box and the lower right corner of the predicted box, h and w represent the width and height of the image respectively, and IoU represents the intersection-over-union loss. A is the area of the prediction box, is the area of the real box, is the objective function used to minimize the MPDIoU loss.
[0056] S4. Use the third insulator image dataset to train the SPD-YOLO11s target detection network model to obtain the optimal weight pt; Furthermore, in the embodiment of the present application, after the above step S4, the following steps are further included: S41. Use the optimal weight pt to verify the SPD-YOLO11s target detection network model.
[0057] Furthermore, in the embodiment of the present application, the above step S41 includes: A preset part of the third insulator image dataset is used as a validation set, and the validation set is input into the SPD-YOLO11s model, and the optimal weight pt is used for inference; Calculate multiple evaluation metrics on the validation set to assess the performance of the model.
[0058] S5. Use the SPD-YOLO11s target detection network model with the optimal weight pt to detect insulator defects.
[0059] This application provides an improved YOLO11s-based insulator defect detection method for snowy and weak-light environments. The method first uses a camera exposure formula to adjust the brightness of a first insulator image dataset to form a second insulator image dataset. The first insulator image dataset is collected by a drone. An adaptive gamma correction network is then used to perform brightness processing on the second insulator image dataset to obtain a third insulator image dataset. The SPD convolution module and MPDIOU loss function are introduced into the YOLO11 network to obtain an SPD-YOLO11s target detection network model. The SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt. The SPD-YOLO11s target detection network model based on pt is then used to detect insulator defects. This application effectively improves the accuracy and stability of insulator defect detection under snowy and weak-light conditions, providing reliable technical support for the safe operation of power systems.
[0060] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean 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.
[0061] Corresponding to the insulator defect detection method in a snowy and weak light environment based on the improved YOLO11s embodiment above, Figure 6A structural block diagram of an insulator defect detection device in a snowy and weak light environment based on improved YOLO11s provided in an embodiment of the present application is shown. For ease of explanation, only the parts related to the embodiment of the present application are shown.
[0062] Reference Figure 6 , the apparatus 600 comprises: An adjustment module 601 is configured to adjust the brightness of a first insulator image dataset collected using a camera exposure formula to form a second insulator image dataset, where the first insulator image dataset is an insulator image dataset collected by a drone. Correction module 602, configured to perform brightness processing on the second insulator image dataset using an adaptive gamma correction network to obtain a third insulator image dataset; An acquisition module 603 is used to introduce the SPD convolution module and the MPDIOU loss function into the YOLO11 network to obtain an SPD-YOLO11s target detection network model; A training module 604 is configured to train the SPD-YOLO11s target detection network model using the third insulator image dataset to obtain an optimal weight pt; The detection module 605 is used to detect insulator defects using the SPD-YOLO11s target detection network model with the optimal weight pt.
[0063] In actual use, the insulator defect detection device based on improved YOLO11s in a snowy and weak-light environment provided in the embodiment of the present application can be configured in any terminal device to execute the aforementioned insulator defect detection method based on improved YOLO11s in a snowy and weak-light environment.
[0064] This application provides an insulator defect detection device based on an improved YOLO11s in a snowy, low-light environment. The device first uses a camera exposure formula to adjust the brightness of a first insulator image dataset collected by a drone to form a second insulator image dataset. The first insulator image dataset is then brightness-processed using an adaptive gamma correction network to obtain a third insulator image dataset. The SPD convolution module and MPDIOU loss function are introduced into the YOLO11 network to obtain an SPD-YOLO11s target detection network model. The SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt. The SPD-YOLO11s target detection network model based on pt is then used to detect insulator defects. This application effectively improves the accuracy and stability of insulator defect detection in snowy, low-light conditions, providing reliable technical support for the safe operation of power systems.
[0065] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of this application. Their specific functions and technical effects can be found in the method embodiment section and will not be repeated here.
[0066] Those skilled in the art can clearly understand that, for the convenience and brevity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the 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 embodiment can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0067] In order to implement the above embodiments, the present application also proposes a terminal device.
[0068] Figure 7 This is a schematic diagram of the structure of a terminal device according to an embodiment of the present application.
[0069] like Figure 7 As shown, the terminal device 200 includes: A memory 210 and at least one processor 220, a bus 230 connecting different components (including the memory 210 and the processor 220), the memory 210 storing a computer program, and when the processor 220 executes the program, the insulator defect detection method in a snowy and weak light environment based on the improved YOLO11s described in an embodiment of the present application is implemented.
[0070] Bus 230 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor, or a local bus using any of a variety of bus architectures. Examples of these architectures include, but are not limited to, an Industry Standard Architecture (ISA) bus, a Micro Channel Architecture (MAC) bus, an Enhanced ISA bus, a Video Electronics Standards Association (VESA) local bus, and a Peripheral Component Interconnect (PCI) bus.
[0071] The terminal device 200 typically includes a variety of electronic device readable media. These media can be any available media that can be accessed by the terminal device 200, including volatile and non-volatile media, removable and non-removable media.
[0072] The memory 210 may also include computer system readable media in the form of volatile memory, such as random access memory (RAM) 240 and / or cache memory 250. The terminal device 200 may further include other removable / non-removable, volatile / non-volatile computer system storage media. For example only, the storage system 260 may be used to read and write non-removable, non-volatile magnetic media ( Figure 7 Not shown, usually called a "hard drive"). Although Figure 7 Although not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), as well as an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 230 via one or more data media interfaces. Memory 210 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of various embodiments of the present application.
[0073] A program / utility 280 having a set (at least one) of program modules 270 may be stored, for example, in memory 210. Such program modules 270 include, but are not limited to, an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may include an implementation of a network environment. Program modules 270 generally implement the functions and / or methods of the embodiments described herein.
[0074] The terminal device 200 can also communicate with one or more external devices 290 (e.g., a keyboard, a pointing device, a display 291, etc.), one or more devices that enable a user to interact with the terminal device 200, and / or any device that enables the terminal device 200 to communicate with one or more other computing devices (e.g., a network card, a modem, etc.). This communication can be performed via an input / output (I / O) interface 292. Furthermore, the terminal device 200 can also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 293. As shown, the network adapter 293 communicates with other modules of the terminal device 200 via a bus 230. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the terminal device 200, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0075] The processor 220 executes various functional applications and data processing by running programs stored in the memory 210 .
[0076] It should be noted that the implementation process and technical principles of the terminal equipment of this embodiment can be found in the aforementioned explanation of the insulator defect detection method in a snowy and weak light environment based on the improved YOLO11s in the embodiment of the present application, which will not be repeated here.
[0077] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned various method embodiments can be implemented.
[0078] An embodiment of the present application provides a computer program product. When the computer program product is run on a terminal device, the terminal device can implement the steps in the above-mentioned method embodiments when executing the computer program product.
[0079] If the integrated unit is implemented as a software functional unit and sold or used as a standalone product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application can implement all or part of the process steps in the above-mentioned method embodiments by using a computer program to instruct the relevant hardware. The computer program can be stored in a computer-readable storage medium. When executed by a processor, the computer program can implement the steps of each of the above-mentioned method embodiments. The computer program includes computer program code, which can be in source code form, object code form, executable file, or some intermediate form. The computer-readable medium can include at least: any entity or device capable of carrying computer program code to a camera / terminal device, recording medium, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signals, telecommunication signals, and software distribution media. Examples include USB flash drives, removable hard drives, magnetic disks, or optical disks. In some jurisdictions, based on legislation and patent practice, computer-readable media cannot be electric carrier signals or telecommunication signals.
[0080] The advancement of the present application solution is described below based on an embodiment.
[0081] 1. Experimental Environment The experimental environment configuration is shown in Table 1.
[0082] Table 1
[0083] 2. Evaluation Indicators In order to objectively evaluate the experimental results, this paper selects four evaluation indicators commonly used in the field of target detection, namely precision, recall, map@0.5 and map@0.5:0.95. The calculation formula is as follows:
[0084]
[0085]
[0086]
[0087] In the object detection task, TP (True Positive), FP (False Positive) and FN (False Negative) represent the correct detection box, incorrect detection box and missed detection box, respectively.
[0088] TP: The true label value is True and the model prediction value is Positive; FP: The true label value is False, and the model prediction value is Positive; FN: The true label value is False, and the model prediction value is Negative.
[0089] AP (mean average precision) is calculated by integrating the Precision-Recall curve and measures the model's detection performance. N represents the total number of categories. mAP@0.5 represents the average AP across categories when the Intersection over Union (IoU) threshold is set to 0.5. Higher mAP@0.5 values indicate better detection performance.
[0090] 3. Experimental Results The model was trained and validated using the dataset Gamma. The experimental results are shown in Table 2. Table 2
[0091] The experimental results above demonstrate that the SPD-YOLO11s object detection network improves accuracy by 1.3% and mAP@0.5 by 1.1% compared to the original YOLO11s model. Compared to the original YOLO11s model, SPD-YOLO11s achieves a 31.5% improvement in FPS, while reducing parameters by 1.1M and GFLOPS by 3.1GB, respectively, significantly lowering computational overhead. Considering both computational overhead and detection accuracy, the SPD-YOLO11s model is suitable for deployment on resource-constrained platforms such as drones.
[0092] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant description of other embodiments.
[0093] Those skilled in the art will appreciate that the units and algorithm steps of each example 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 performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel 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.
[0094] In the embodiments provided in this application, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are merely illustrative. For example, the division of the modules or units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0095] The units described as separate components may or may not be physically separate, and 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 these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0096] The above-described embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present application, and should all be included in the scope of protection of the present application.
Claims
1. An insulator defect detection method based on improved YOLO11s in a snowy and weak light environment, characterized in that: include: Adjusting the brightness of a first insulator image dataset collected by a drone using a camera exposure formula to form a second insulator image dataset; Performing brightness processing on the second insulator image dataset using an adaptive Gamma correction network to obtain a third insulator image dataset; The SPD convolution module and MPDIOU loss function are introduced into the YOLO11 network to obtain the SPD-YOLO11s target detection network model; The SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt; The SPD-YOLO11s target detection network model with the optimal weight pt is used to detect insulator defects.
2. The method according to claim 1, wherein The step of performing brightness processing on the second insulator image dataset using an adaptive gamma correction network to obtain a third insulator image dataset includes: Calculate the average brightness of the image based on the total number of image pixels and the pixel value of each grayscale image in the second insulator image dataset : in, is the value of each pixel in the grayscale image, and N is the total number of pixels in the image; Dynamically adjust the Gamma value based on the average brightness : in, is the minimum value of Gamma, is the maximum value of Gamma, is the target brightness value; The pixel value I(i) of each image is corrected using the Gamma value to obtain the third insulator image dataset; wherein, The pixel value I(i) of each image is corrected using the Gamma value, specifically: in, It is the pixel value after gamma correction.
3. The method according to claim 1, wherein The SPD convolution module and MPDIOU loss function are introduced into the YOLO11 network to obtain the SPD-YOLO11s target detection network model, including: In the backbone feature extraction module of the YOLO11 network, all the original convolution downsampling structures are replaced with SPD convolution modules; In the loss function module of the YOLO11 network, the original CIoU loss function is replaced by the MPDIoU loss function to obtain the SPD-YOLO11s target detection network model.
4. The method according to claim 3, wherein The calculation process of the MPDIoU loss function is as follows: in, and Respectively represent the upper left corner coordinates and lower right corner coordinates of the real box, and Respectively represent the coordinates of the upper left corner and lower right corner of the prediction box, Indicates the distance between the upper left corner of the real box and the upper left corner of the predicted box, Represents the distance between the lower right corner of the real box and the lower right corner of the predicted box, h and w represent the width and height of the image respectively, and IoU represents the intersection-over-union loss. A is the area of the prediction box, is the area of the real box, is the objective function used to minimize the MPDIoU loss.
5. The method according to claim 1, wherein After the SPD-YOLO11s target detection network model is trained using the third insulator image dataset to obtain the optimal weight pt, the method further includes: The optimal weight pt is used to verify the SPD-YOLO11s target detection network model.
6. The method according to claim 5, wherein The SPD-YOLO11s target detection network model is verified using the optimal weight pt, including: A preset part of the third insulator image dataset is used as a validation set, and the validation set is input into the SPD-YOLO11s model, and the optimal weight pt is used for inference; Calculate multiple evaluation metrics on the validation set to assess the performance of the model.
7. An insulator defect detection device based on improved YOLO11s in a snowy and weak light environment, characterized in that: include: an adjustment module, configured to adjust the brightness of a first insulator image dataset collected by a drone using a camera exposure formula to form a second insulator image dataset; a correction module, configured to perform brightness processing on the second insulator image dataset using an adaptive gamma correction network to obtain a third insulator image dataset; Obtain a module for introducing the SPD convolution module and MPDIOU loss function into the YOLO11 network to obtain the SPD-YOLO11s target detection network model; A training module is used to train the SPD-YOLO11s target detection network model using the third insulator image dataset to obtain the optimal weight pt; The detection module is used to detect insulator defects using the SPD-YOLO11s target detection network model with the optimal weight pt.
8. A terminal device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method according to any one of claims 1 to 6 is implemented.
9. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Rainy day insulator defect detection method based on improved MS-PReNet and GAM-YOLOv7
CN117422689A
Power transmission line insulator detection method based on lightweight improved YOLO algorithm
CN118351420A
Improved YOLOV7-tiny fabric image flaw detection method and system based on SPD-SE
CN119831957A
Multi-scale feature enhancement fusion insulator small target defect detection network
CN120163776A