Photovoltaic cell defect segmentation method based on edge perception

By constructing a lightweight LDSN network and combining an efficient segmentation module and a dual-focus attention module in the encoder and decoder, the shortcomings of photovoltaic cell defect segmentation models in terms of accuracy and speed are solved, achieving efficient defect segmentation and low-cost deployment.

CN116645338BActive Publication Date: 2026-03-17HEBEI UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-15
Publication Date
2026-03-17

AI Technical Summary

Technical Problem

Existing photovoltaic cell defect segmentation models are insufficient in terms of accuracy and speed, making them difficult to deploy on a large scale in production lines, and the deployment cost is high.

Method used

We adopt an edge-aware defect segmentation method and construct a lightweight defect segmentation network (LDSN network). By utilizing the efficient segmentation module and dual-focus attention module of the encoder and decoder, we can improve feature extraction and segmentation accuracy and reduce computational complexity.

Benefits of technology

It achieves high-precision defect segmentation, significantly reduces deployment costs and computational complexity, improves segmentation speed, and is suitable for large-scale deployment on production lines.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116645338B_ABST
    Figure CN116645338B_ABST
Patent Text Reader

Abstract

This invention presents an edge-aware-based defect segmentation method for photovoltaic cells, including the construction and training of a defect segmentation model. The defect segmentation model comprises an encoder and a decoder. The encoder consists of four stages: the first stage includes a convolutional layer and three efficient segmentation modules, while the remaining three stages each include four efficient segmentation modules. Adjacent stages are downsampled through a patch merging operation. The encoder of the defect segmentation network is composed of multiple efficient segmentation modules, which use a multi-channel fusion approach to improve segmentation accuracy. Channel splitting operations further increase the network's receptive field, enriching the expressive power of the feature maps and enhancing the model's feature extraction capabilities. This allows for finer-grained expression of multi-scale features and enhanced information interaction between split features. The decoder consists of four branches, each capturing long-distance spatial and channel information through a dual-focus attention module. This method balances segmentation accuracy and speed, making it suitable for large-scale deployment on production lines.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of photovoltaic cell defect segmentation technology, and particularly relates to a photovoltaic cell defect segmentation method based on edge perception. Background Technology

[0002] Due to the fragility of the crystal structure of photovoltaic cells, defects such as broken grids and cracks are unavoidable during the manufacturing process. These defects can cause partial or complete failure of the photovoltaic cells, severely weakening the power generation capacity of the photovoltaic power generation system. The hazards caused by photovoltaic cell defects are diverse. Tiny cracks expand under mechanical loads, potentially leading to open circuits inside the cell; cracks accelerate power decay, significantly shortening the normal lifespan of the cell; severe cracks can cause localized overheating, resulting in hot spot defects, which are one of the root causes of serious fire accidents. Therefore, defect segmentation is a necessary condition for ensuring the safe operation of photovoltaic power plants. For manufacturers to accurately optimize processes such as acid washing, diffusion, etching, and cleaning during production, they play a crucial role in tracing the root causes of photovoltaic cell quality problems.

[0003] To improve defect segmentation accuracy, researchers have conducted in-depth studies on model performance. For example, FCN-based semantic segmentation, including U-Net and DeepLabv3, uses continuous upsampling in the deep stages of the encoder to obtain the final output. The features extracted in the deep stages of the encoder have the richest semantic representation but relatively poor spatial resolution. At the same time, continuous upsampling operations lose more spatial feature information, resulting in lower accuracy. In addition to segmentation accuracy, computational complexity is also an important consideration for large-scale deployment of models in production. Lightweight models can significantly reduce energy consumption and hardware costs, such as CPUs, GPUs, and memory. However, U-Net and DeepLabv3 have complex encoding and decoding structures, leading to high deployment costs and slow segmentation speeds.

[0004] In summary, this invention proposes a defect segmentation method for photovoltaic cells based on edge perception, which balances segmentation accuracy and speed, and is conducive to large-scale deployment on production lines. Summary of the Invention

[0005] To address the shortcomings of existing technologies, the technical problem this invention aims to solve is to provide a method for defect segmentation of photovoltaic cells based on edge perception.

[0006] The technical solution adopted by the present invention to solve the aforementioned technical problem is as follows:

[0007] A method for defect segmentation of photovoltaic cells based on edge perception, characterized in that the method includes the construction and training of a defect segmentation model, and the application of the trained defect segmentation model to defect segmentation of photovoltaic cells.

[0008] The defect segmentation model includes an encoder and a decoder. The encoder consists of four stages. The first stage includes one convolutional layer and three efficient segmentation modules, while the remaining three stages each include four efficient segmentation modules. Adjacent stages are downsampled through a patch merging operation. The input of the efficient segmentation modules passes through a convolutional layer and then undergoes channel splitting to obtain three feature maps X1, X2, and X3. Feature map X1 directly generates feature map Y1. Feature map X2 passes through a depthwise separable convolutional layer and an activation layer to obtain feature map Y2. Feature maps X3 and Y2 are added together and then passed through a depthwise separable convolutional layer and an activation layer to obtain feature map Y3. Feature maps Y1, Y2, and Y3 undergo channel transformation and then pass through a convolutional layer. They are then added to the input of the efficient segmentation modules to obtain the output of the efficient segmentation modules.

[0009] The decoder is divided into four branches. The output of each stage of the encoder serves as the input of the corresponding branch. Each branch refines redundant information and captures long-distance spatial and channel information through a dual-focus attention module. The output of the dual-focus attention module is interpolated to obtain intermediate feature maps. All intermediate feature maps are added together and then passed through convolutional and activation layers to obtain the output of the defect segmentation model.

[0010] Furthermore, the input of each branch of the decoder passes through multiple convolutional layers and one activation layer before entering the dual-focus attention module. The dual-focus attention module includes a spatial focus module and a channel enhancement module. The spatial focus module undergoes two strip convolutions, followed by max pooling and activation operations, and is multiplied by the input of the spatial focus module to obtain the output of the spatial focus module. The output of the spatial focus module enters the channel enhancement module, undergoes global max pooling, convolution, and activation operations, and is multiplied by the input of the channel enhancement module, followed by multiple convolutions to obtain the output of the dual-focus attention module.

[0011] Furthermore, the number of channels in the output feature maps of the four stages in the encoder are C, 2C, 4C and 4C, respectively, where C is a positive integer.

[0012] Furthermore, the defects include cracks, finger-like defects, broken grids, and black spots.

[0013] Compared with the prior art, the beneficial effects of the present invention are:

[0014] (1) This invention proposes a lightweight and efficient defect segmentation network (LDSN network), which effectively improves defect segmentation accuracy while maintaining segmentation efficiency. The encoder of the defect segmentation network consists of multiple efficient segmentation modules. The efficient segmentation modules use a multi-channel fusion method to improve segmentation accuracy. Through channel splitting operations, the receptive field of the network is further increased, enriching the expressive power of the feature maps and enhancing the feature extraction capability of the model. This allows for the expression of multi-scale features at a finer granularity and enhances the information interaction between split features. The input and output feature maps of the efficient segmentation modules are of the same size, which greatly reduces the number of network parameters, ensures the overall lightweight nature of the network, and reduces deployment costs.

[0015] (2) The decoder of the defect segmentation network is mainly composed of a dual-focus attention module. This module can effectively capture long-range spatial and channel information, improve the expression of important information in spatial and channel information, and effectively suppress background noise. The dual-focus attention module uses strip convolution. On the one hand, strip convolution is lightweight, which can realize the lightweighting of the network; on the other hand, strip convolution helps to extract linear defects better, thereby obtaining better edge segmentation results.

[0016] (3) Experimental results show that the LDSN network achieves the best performance in terms of segmentation accuracy and speed on the PSCED public dataset. Compared with the existing defect segmentation model, the segmentation accuracy of the LDSN network of this invention is slightly improved, the number of parameters is about one-tenth of the existing model, and the segmentation speed is significantly improved. Therefore, it takes into account both segmentation accuracy and speed. Attached Figure Description

[0017] Figure 1 This is a structural diagram of the defect segmentation model;

[0018] Figure 2 A structural diagram for efficient module segmentation;

[0019] Figure 3 This is a structural diagram of the bifocal attention module;

[0020] Figure 4 An EL image of a photovoltaic cell to be segmented;

[0021] Figure 5 For another type of photovoltaic cell EL image to be segmented;

[0022] Figure 6 The images show the segmentation results obtained from different models. Detailed Implementation

[0023] Specific embodiments are given below with reference to the accompanying drawings. These specific embodiments are only used to describe the technical solutions of the present invention in detail, and are not intended to limit the scope of protection of this application.

[0024] This invention relates to a defect segmentation method for photovoltaic cells based on edge perception, comprising the following steps:

[0025] Step 1: Obtain the dataset

[0026] The dataset used in this embodiment is the PSCDE public dataset. The training set of this dataset has 280 images, the validation set has 140 images, and the test set has 280 images. All three sets contain various defects. Data augmentation of the training set is performed by means of rotation, flipping, etc., to expand the number of training images.

[0027] Step 2: Construct a defect segmentation model, which includes an encoder and a decoder;

[0028] See Figure 1 The encoder consists of four stages. The first stage includes a 3×3 convolutional layer and three efficient split blocks (ES blocks). The remaining three stages each include four efficient split blocks. Patch merging is used between adjacent stages to downsample, which is more conducive to generating hierarchical feature representations and retaining more information. At the same time, it reduces the height and width of the input feature map in the next stage and increases the number of channels in the input feature map to further improve the receptive field of the convolutional layer, thereby better performing hierarchical feature representation. The number of channels in the output feature maps of the four stages are C, 2C, 4C, and 4C, respectively, to avoid a large model size. C represents the number of channels.

[0029] See Figure 2 The input feature map X of the efficient segmentation module is passed through a convolutional layer with a kernel size of 1×1, and then subjected to channel splitting to divide the convolutional feature map into three feature maps X1, X2, and X3 according to 1 / 2, 1 / 4, and 1 / 4 of the number of channels; where X1∈R 1 / 2×C×H×W X2∈R 1 / 4×C×H×W X3∈R 1 / 4×C×H×WR represents the feature space, and H and W represent the height and width of the feature map, respectively. Feature map X1 directly generates feature map Y1. Feature map X2 is passed through a depthwise separable convolutional layer with a kernel size of 3×3 and an activation layer (GELU activation function) to obtain feature map Y2. Feature maps X3 and Y2 are added together and then passed through a depthwise separable convolutional layer and an activation layer to obtain feature map Y3. Feature maps Y1, Y2, and Y3 are subjected to channel shuffle and then passed through a convolutional layer with a kernel size of 1×1. They are then added to the input feature map X of the efficient segmentation module to obtain the output of the efficient segmentation module. The efficient segmentation module significantly improves the network capacity without increasing computational complexity by using channel splitting and depthwise separable convolution. The purpose of channel shuffle is to overcome the side effects of channel splitting, that is, the integrity of the feature map is destroyed after channel splitting, and the information communication ability between different channels is reduced. Therefore, channel shuffle is used to realize information communication between different channels, enhance the interaction between information, and improve the accuracy of defect edge segmentation.

[0030] The decoder is divided into four branches, corresponding to the four stages of the encoder. The output feature maps of each stage of the encoder are input into the corresponding branch, pass through multiple 1×1 convolutional layers and one activation layer, and then enter the Dual Focus Attention (DFA) module. This module refines the redundant information in the input feature maps of its respective branch and captures long-range spatial and channel information. (See also...) Figure 3 The dual-focus attention module comprises a Spatial Focus Module (SF Module) and a Channel Enhancement Module (CE Module). The SF Module first captures anisotropic contextual information in the feature map using two strip convolutions with kernel sizes of 5×1 and 1×5. The feature map obtained from the second strip convolution is then multiplied by the input of the SF Module after max pooling and activation operations to obtain the output of the SF Module. Using strip convolutions serves two purposes: firstly, it is a lightweight structure that significantly reduces the model's computational complexity; secondly, the PSCDE dataset contains many strip-shaped defects, including cracks, finger defects, broken gates, and black spots, most of which exhibit linear structures. Therefore, using strip convolutions helps extract strip-shaped features, resulting in better edge segmentation. Furthermore, strip convolutions can more effectively capture anisotropic contextual information, improving the representation of strip features.

[0031] The expression for the spatial focusing module is:

[0032] Out1 = σ(MaxPool(Conv)1×5 (Conv 5×1 (F)))) (1)

[0033] Where F and Out1 are the input and output of the spatial focusing module, respectively, MaxPool(·) is the maximum pooling operation, and Conv 5×1 (·), Conv 1×5 These are strip convolutions with kernel sizes of 5×1 and 1×5, respectively; σ is the activation operation, using the Sigmoid function;

[0034] The channel enhancement module is designed to further enhance defect feature representation and suppress background noise. It refines the channel dimension through global max pooling, convolution, and activation operations (Sigmoid). After multiplying with the input of the channel enhancement module, the output is obtained through multiple convolutions with a kernel size of 1×1, which is the output of the channel enhancement module, i.e., the output of the dual-focus attention module. The channel enhancement module describes the global distribution of object features in the channel-level feature response. It uses a gating mechanism to control the activation of each channel to simulate long-distance dependencies between channels.

[0035] The expression for the channel enhancement module is:

[0036] Out2 = Conv 1×1-M (σ(Conv 1×1 (GMaxPool(Out1)))·Out1) (2)

[0037] Where Out2 is the output of the channel enhancement module, GMaxPool(·) is the global max pooling, and Conv 1×1 (·) represents a convolution with a kernel size of 1×1, Conv 1×1-M This represents a convolution with M kernels of size 1×1;

[0038] The output of the dual-focus attention module is interpolated to obtain intermediate feature maps. On one hand, after all intermediate feature maps are added together, they are subjected to a convolution and activation operation with a kernel size of 1×1 to obtain the output of the defect segmentation model, which is the final prediction result. On the other hand, each intermediate feature map is subjected to a convolution and activation operation with a kernel size of 1×1 to obtain an intermediate prediction result, which is used to calculate the model loss.

[0039] Step 3: Training and testing the defect segmentation model

[0040] Initialize model parameters, including but not limited to network weights, all biases, number of iterations (epochs), batch size (batch_size), learning rate, optimizer, etc.

[0041] The defect segmentation model is trained using the training set from the first step, and the model loss is calculated using the Annotator-Robust loss function. The model loss consists of five parts: the final prediction result and the deviation between each intermediate prediction map and the true label. In order to learn multi-scale and multi-level defect feature representations, a deep supervision strategy is adopted to supervise each stage. Deep supervision can alleviate the gradient vanishing problem, improve the model convergence speed and output accuracy, thereby optimizing the entire network.

[0042] The trained defect segmentation model is validated using a validation set and optimized through backpropagation. The photovoltaic cell images to be segmented from the test set are input into the trained defect segmentation model to segment the defects.

[0043] To verify the superior performance of the defect segmentation model of the present invention, it was tested using the PSCED public dataset and compared with common defect edge segmentation models. Figure 4 , 5 Two types of photovoltaic cell EL images to be segmented. Figure 6 The segmentation results of different models are presented. The model performance is evaluated using four metrics: global optimal threshold (Optimal Dataset Scale, ODS), single-image optimal threshold (Optimal Image Scale, OIS), number of parameters (Pararm), and number of images processed per second (Frames Per Second, FPS). The global optimal threshold and single-image optimal threshold are used to measure model accuracy, while the number of parameters and number of images processed per second are used to measure model speed. The statistical results of the metrics for different models are shown in Table 1.

[0044] Table 1 Statistical results of indicators for different models

[0045]

[0046] The defect segmentation model of this invention is a lightweight and efficient defect segmentation network (LDSN network). As shown in Table 1, the LDSN network surpasses common models in both accuracy and speed, achieving ODS and OIS of 84.8% and 86.8% respectively. While processing a comparable number of images per second, the number of parameters is approximately one-tenth that of existing models. Figure 6 It can be seen that LDSN networks can segment more fine-grained defect structures, specifically as follows: Figure 5In the image to be segmented, fine cracks extend from the lower side of the main crack. The LDSN network segmented these fine cracks, while other models failed to segment them. Therefore, the defect segmentation model of this invention can reduce the false negative rate and the false positive rate, achieving a balance between speed and accuracy while maintaining high accuracy.

[0047] Any aspects not covered in this invention are applicable to existing technologies.

Claims

1. A method for edge-aware photovoltaic cell defect segmentation, characterized in that, The method comprises construction and training of a defect segmentation model and application of the trained defect segmentation model to photovoltaic cell defect segmentation. The defect segmentation model comprises an encoder and a decoder; the encoder is divided into four stages, the first stage comprises one convolutional layer and three efficient segmentation modules, and the other three stages each comprise four efficient segmentation modules, and patch merging operations are performed between adjacent two stages for down-sampling; input of the efficient segmentation module is subjected to a convolutional layer and then to channel splitting to obtain three feature maps X1, X2 and X3; the feature map X1 directly generates a feature map Y1, the feature map X2 is subjected to a depth separable convolutional layer and an activation layer to obtain a feature map Y2; the feature map X3 and the feature map Y2 are added and then subjected to a depth separable convolutional layer and an activation layer to obtain a feature map Y3; the feature maps Y1, Y2 and Y3 are subjected to channel transformation and then a convolutional layer to obtain output of the efficient segmentation module. The decoder is divided into four branches, and outputs of the stages of the encoder are taken as input of the corresponding branches; each branch is subjected to a bifocal attention module for redundant information refinement and long-distance spatial and channel information capture; output of the bifocal attention module is subjected to interpolation to obtain an intermediate feature map, and all intermediate feature maps are added and then subjected to a convolutional layer and an activation layer to obtain output of the defect segmentation model.

2. The edge-aware based photovoltaic cell defect segmentation method according to claim 1, wherein, Input of each branch of the decoder is subjected to multiple convolutional layers and an activation layer and then enters the bifocal attention module; the bifocal attention module comprises a spatial focusing module and a channel enhancement module; the spatial focusing module is subjected to two strip convolutions, maximum pooling and an activation operation, and then multiplied by input of the spatial focusing module to obtain output of the spatial focusing module; output of the spatial focusing module enters the channel enhancement module, which is subjected to global maximum pooling, convolution and an activation operation, and then multiplied by input of the channel enhancement module, and then subjected to multiple convolutions to obtain output of the bifocal attention module.

3. The edge-aware based photovoltaic cell defect segmentation method according to claim 1 or 2, characterized in that, The channel numbers of the output feature maps of the four stages of the encoder are C, 2C, 4C and 4C respectively, and C is a positive integer.

4. The edge-aware based photovoltaic cell defect segmentation method according to claim 1, wherein, The defects include cracks, finger defects, broken grids and black spots.

Citation Information

Patent Citations

  • Semantic segmentation-based image composite defect detection method and system

    CN114820579A

  • Skin disease image segmentation method and system based on joint attention convolutional neural network

    CN115457021A