Photovoltaic el image preprocessing method, device and computer readable medium

CN117152437BActive Publication Date: 2026-08-07TRINA SOLAR CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
TRINA SOLAR CO LTD
Filing Date
2023-09-13
Publication Date
2026-08-07

AI Technical Summary

Technical Problem

[0004]本发明要解决的技术问题是提供一种光伏EL图像预处理方法、装置及计算机可读介质,解决现有的光伏EL图像预处理方法泛化性差的问题

Benefits of technology

[0019]本发明的光伏EL图像预处理方法、装置及计算机可读介质,一方面,通过自适应阈值二值化处理和连通区域处理,可以对任意电池规格的光伏EL图像进行黑色无效区域切除,泛化性高;另一方面,通过对光伏EL图像进行尺寸缩小处理,可以减少自适应阈值二值化处理的计算量。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117152437B_ABST
    Figure CN117152437B_ABST
Patent Text Reader

Abstract

The application provides a photovoltaic EL image preprocessing method and device and a computer readable medium. The method comprises the following steps: obtaining a photovoltaic EL image to be processed; reducing the size of the photovoltaic EL image, and the reduced image is recorded as a first image; performing binaryzation processing on the first image by using an adaptive threshold value, and adjacent and same-value pixel points are classified into the same connected region to obtain a plurality of connected regions; calculating the areas of the plurality of connected regions, and taking the connected region with the largest area as a target connected region; calculating the position of the target connected region on the first image in the photovoltaic EL image, cutting off the black invalid region in the photovoltaic EL image according to the position, and obtaining a second image. By means of the adaptive threshold binaryzation processing and the connected region processing, the black invalid region of the photovoltaic EL image of any battery specification can be cut off, and the generalization is high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates primarily to the field of image processing technology, and more particularly to a photovoltaic EL image preprocessing method, apparatus, and computer-readable medium. Background Technology

[0002] Because solar panel substrates are fragile and manufacturing processes are complex, minute and difficult-to-detect defects such as cracks, fissures, and poor soldering can easily appear on the surface of solar cells due to process defects or human error. These defects will severely reduce the photoelectric conversion efficiency and lifespan of the solar panel, making solar panel defect detection technology extremely important. Currently, some manufacturers use photovoltaic EL (Electroluminescence) images for photovoltaic module defect detection. First, the photovoltaic EL image is preprocessed, and then the preprocessed photovoltaic EL image is input into an artificial intelligence model. The model outputs the location and type of defects in the photovoltaic module.

[0003] Existing photovoltaic EL image preprocessing methods typically only perform basic image operations such as grayscale conversion, image binarization, and size adjustment, which are not conducive to subsequent model processing and seriously affect the accuracy of defect detection. On the other hand, existing photovoltaic EL image preprocessing methods can only process EL images of specific specifications in specific processes, and cannot be applied to the preprocessing of photovoltaic EL images of different specifications in multiple processes, resulting in poor generalization. Summary of the Invention

[0004] The technical problem to be solved by the present invention is to provide a photovoltaic EL image preprocessing method, apparatus and computer-readable medium, which solves the problem of poor generalization of existing photovoltaic EL image preprocessing methods.

[0005] To address the aforementioned technical problems, this invention provides a photovoltaic EL image preprocessing method, comprising: acquiring a photovoltaic EL image to be processed; reducing the size of the photovoltaic EL image, with the reduced image designated as a first image; performing binarization processing on the first image using an adaptive threshold, grouping adjacent pixels with the same value into the same connected region to obtain multiple connected regions; calculating the area of ​​the multiple connected regions, and selecting the connected region with the largest area as the target connected region; calculating the position of the target connected region on the first image in the photovoltaic EL image, and removing the black invalid region in the photovoltaic EL image according to the position to obtain a second image.

[0006] Optionally, reducing the size of the photovoltaic EL image includes reducing the width and height of the photovoltaic EL image to one-Kth of their original values, where K is a positive integer.

[0007] Optionally, calculating the position of the target connected region on the first image in the photovoltaic EL image includes: obtaining the upper left and lower right corner coordinates of the target connected region in the first image; and multiplying the values ​​of the upper left and lower right corner coordinates by K times to obtain the positions of the upper left and lower right corner coordinates in the photovoltaic EL image.

[0008] Optionally, it also includes: performing an opening operation on the binarized first image and then a closing operation to remove noise black spots on the image.

[0009] Optionally, the method further includes: acquiring relevant parameters of the photovoltaic EL image, the relevant parameters including cell specifications, horizontal offset, and vertical offset, wherein the cell specifications are M*N, and M and N are positive integers; and cutting the second image into M*N cell images according to the relevant parameters.

[0010] Optionally, the second image is segmented into M*N battery cell images according to the relevant parameters. This includes: calculating the size of a single battery cell image based on the relevant parameters and the second image; calculating the coordinates of each battery cell image based on the size of the single battery cell image, the horizontal offset, and the vertical offset; and traversing the second image and segmenting the second image according to the coordinates.

[0011] Optionally, calculating the size of a single battery cell image based on the relevant parameters and the second image includes: obtaining the width and height of the second image; subtracting the horizontal offset width from the width of the second image, and then dividing it evenly according to the battery specifications to obtain the width of a single battery cell image; subtracting the vertical offset width from the height of the second image, and then dividing it evenly according to the battery specifications to obtain the height of a single battery cell image; wherein the horizontal offset includes a horizontal offset coordinate and the horizontal offset width, and the vertical offset includes a vertical offset coordinate and the vertical offset width.

[0012] Optionally, calculating the coordinates of each battery cell image based on the size of the individual battery cell image, the horizontal offset, and the vertical offset includes: dividing the horizontal offset coordinate by the width of the individual battery cell image to calculate the column value to which the horizontal offset width needs to be added; dividing the vertical offset coordinate by the height of the individual battery cell image to calculate the row value to which the vertical offset width needs to be added; and calculating the coordinates of each battery cell image based on the size of the individual battery cell image, the column value, the row value, the horizontal offset width, and the vertical offset width.

[0013] Optionally, it further includes: adjusting the size of the battery cell image to a target size, wherein the width and height of the target size are equal.

[0014] Optionally, it further includes: converting the battery cell image into an RGB format image, and normalizing the pixel values ​​in the RGB format image.

[0015] Optionally, it further includes: before the reduction processing, determining whether the photovoltaic EL image is a grayscale image; if so, converting the photovoltaic EL image into a BGR format image.

[0016] To address the aforementioned technical problems, the present invention provides a photovoltaic EL image preprocessing apparatus, comprising: a memory for storing instructions executable by a processor; and a processor for executing the instructions to implement the method described above.

[0017] To address the aforementioned technical problems, the present invention provides a computer-readable medium storing computer program code, which, when executed by a processor, implements the method described above.

[0018] Compared with the prior art, the present invention has the following advantages:

[0019] The photovoltaic EL image preprocessing method, apparatus, and computer-readable medium of the present invention, on the one hand, can remove black invalid regions from photovoltaic EL images of any battery specification through adaptive threshold binarization and connected component processing, exhibiting high generalization ability; on the other hand, by reducing the size of the photovoltaic EL image, the computational load of adaptive threshold binarization can be reduced. Attached Figure Description

[0020] The accompanying drawings are included to provide a further understanding of this application; they are incorporated into and constitute a part of this application. The drawings illustrate embodiments of this application and, together with this specification, serve to explain the principles of the invention. In the drawings:

[0021] Figure 1 This is a photovoltaic EL image according to an embodiment of the present invention.

[0022] Figure 2 This is a flowchart of a photovoltaic EL image preprocessing method according to an embodiment of the present invention.

[0023] Figure 3 yes Figure 2 A flowchart of an embodiment of step S25.

[0024] Figure 4 This is a mapping diagram between the first image and the photovoltaic EL image.

[0025] Figure 5 It corresponds Figure 1 The second image with the black invalid area removed.

[0026] Figure 6 yes Figure 2 A flowchart of the photovoltaic EL image preprocessing method in an optimized embodiment.

[0027] Figure 7 yes Figure 6 A flowchart of an embodiment of step S27.

[0028] Figure 8 yes Figure 7 A flowchart of an embodiment of step S271.

[0029] Figure 9 yes Figure 7 A flowchart of an embodiment of step S272.

[0030] Figure 10 This is a system block diagram of a photovoltaic EL image preprocessing apparatus according to an embodiment of this application. Detailed Implementation

[0031] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are merely some examples or embodiments of this application. For those skilled in the art, these drawings can be applied to other similar scenarios without creative effort. Unless obvious from the context or otherwise specified, the same reference numerals in the drawings represent the same structures or operations.

[0032] Flowcharts are used in this application to illustrate the operations performed by the system according to embodiments of this application. It should be understood that the preceding or following operations are not necessarily performed in exact order. Instead, various steps can be processed in reverse order or simultaneously. Furthermore, other operations may be added to these processes, or one or more steps may be removed from these processes.

[0033] Photovoltaic EL images are photographs taken in dark environments by applying a reverse voltage to photovoltaic modules. Human or artificial intelligence models can identify internal defects such as microcracks, broken grids, screen cracks, and black spots from these EL images. Figure 1 This is a photovoltaic EL image according to an embodiment of the present invention. Figure 1As shown, the photovoltaic EL image 100 includes multiple cell images A, redundant black invalid areas B, a first grid line C, and a second grid line D. The cell specifications of the photovoltaic EL image differ depending on the process, denoted as M*N, where M and N are positive integers. In this embodiment, the cell specification is 5*22, meaning the photovoltaic EL image 100 includes 5*22 cell images A. The first grid line C and the second grid line D are generated when multiple cameras stitch together images to form the photovoltaic EL image 100. The first grid line C is often represented by a horizontal offset, which includes a horizontal offset coordinate x1 and a horizontal offset width w1. The horizontal offset coordinate x1 represents the position of the first grid line C, and the horizontal offset width w1 represents the width of the first grid line C. Similarly, the second grid line D is often represented by a vertical offset, which includes a vertical offset coordinate y1 and a vertical offset width w2. The vertical offset coordinate y1 represents the position of the second grid line D, and the vertical offset width w2 represents the width of the second grid line D. The artificial intelligence model receives a solar cell image A and needs to segment the photovoltaic EL image 100 into multiple solar cell images A. Before segmenting the photovoltaic EL image 100 into multiple solar cell images A, it is necessary to remove the black invalid region B of the photovoltaic EL image 100. The width of the black invalid region B varies in different processes. Therefore, an adaptive method for removing the black invalid region is needed.

[0034] Figure 2 This is a flowchart of a photovoltaic EL image preprocessing method according to an embodiment of the present invention. Figure 2 As shown, the photovoltaic EL image preprocessing method 200 includes the following steps:

[0035] Step S21: Obtain the photovoltaic EL image to be processed.

[0036] Optionally, an image acquisition algorithm is written based on the Flask framework and the Python language to obtain the photovoltaic EL image to be processed from the front-end interface. In some embodiments, the image acquisition algorithm also decodes the received base64 encoded image data to facilitate subsequent image operations.

[0037] Step S22: Reduce the size of the photovoltaic EL image, and the reduced image is recorded as the first image.

[0038] To reduce the computational load of image preprocessing, the size of the photovoltaic EL image to be processed is reduced. Optionally, the width and height of the photovoltaic EL image are each reduced to one-Kth of their original size, where K is a positive integer. Preferably, the width and height of the photovoltaic EL image are each reduced to one-quarter of their original size, that is, the size of the photovoltaic EL image to be processed is reduced to one-sixteenth of its original size. The reduced image is denoted as the first image. In other words, the size of the first image is one-sixteenth of the size of the photovoltaic EL image to be processed.

[0039] Step S23: Use an adaptive threshold to binarize the first image, grouping adjacent pixels with the same value into the same connected region to obtain multiple connected regions.

[0040] Binarization refers to setting the grayscale value of pixels in an image to 0 or 1, thus presenting the entire image with a clear black and white visual effect. Optionally, a common method is to set a threshold T, which divides the image data into two parts: a group of pixels with values ​​greater than T and a group of pixels with values ​​less than T. Adaptive thresholding, unlike fixed thresholding, does not use a fixed threshold for each pixel; instead, it is determined by the distribution of its surrounding neighboring pixels. The grayscale value difference is greatest at the boundary between the black invalid region B and the battery cell image A, so the grayscale value of the pixels at the boundary is set to 1, while pixels in other areas are set to 0. Adjacent pixels with the same value are grouped into the same connected region. For example, connecting adjacent pixels with a grayscale value of 1 into the same connected region can detect the boundary of a pure battery cell image. Preferably, the binarization threshold is set to 0.85 times the adaptive threshold.

[0041] Of course, due to the existence of the first grid line C and the second grid line D, the difference in gray values ​​at the intersection of the first grid line C and the second grid line D with the battery cell image A is also the greatest. By grouping adjacent pixels with the same value into the same connected region, some connected regions will also be obtained.

[0042] Step S24: Calculate the area of ​​multiple connected regions and select the connected region with the largest area as the target connected region.

[0043] Alternatively, the area of ​​a connected component can be calculated using the `connectedComponentsWithStats` function in OpenCV, and then the areas of multiple connected components can be sorted, with the connected component with the largest area being selected as the target connected component. (See reference) Figure 1 As shown, the M*N cell images A in the photovoltaic EL image occupy the largest portion of the image area. Therefore, the largest connected region is the boundary of the M*N cell images, which is the region after removing the black invalid region B from the photovoltaic EL image.

[0044] Step S25: Calculate the position of the target connected region on the first image in the photovoltaic EL image, and remove the black invalid region in the photovoltaic EL image according to the position to obtain the second image.

[0045] Figure 3 yes Figure 2 A flowchart of an embodiment of step S25. Figure 4 This is a mapping diagram between the first image and the photovoltaic EL image. For example... Figures 3-4 As shown, calculating the location of the target connected region on the first image in the photovoltaic EL image includes:

[0046] Step S251: Obtain the coordinates of the top left corner (x0, y0) and the bottom right corner (x0+w, y0+h) of the target connected region in the first image, where w is the width of the first image and h is the height of the first image.

[0047] Step S252: Multiply the values ​​of the top left corner coordinates and the bottom right corner coordinates by K times respectively to obtain the positions of the top left corner coordinates and the bottom right corner coordinates in the photovoltaic EL image.

[0048] like Figure 4 As shown, the coordinates of the upper left corner (x0, y0) in the photovoltaic EL image are (K*x0, K*y0), and the coordinates of the lower right corner (x0+w, y0+h) in the photovoltaic EL image are (K*(x0+w), K*(y0+h)).

[0049] Figure 5 It corresponds Figure 1 The second image after removing the black, invalid areas. (Example) Figure 5 As shown, the black invalid area in the photovoltaic EL image can be removed based on the coordinates of the upper left corner (K*x0, K*y0) and the lower right corner (K*(x0+w), K*(y0+h)).

[0050] Optionally, the photovoltaic EL image preprocessing method 200 further includes the steps of: performing an opening operation on the binarized first image, followed by a closing operation to remove noise black spots on the image. After removing noise black spots, adjacent pixels with the same value are grouped into the same connected region. Preferably, the filter size is set to 8*8 pixels. An opening operation is performed first, i.e., erosion followed by dilation, to remove image noise while maintaining the original shape; then a closing operation is performed, i.e., dilation followed by erosion, to remove small black spots in the target and background.

[0051] Optionally, the photovoltaic EL image preprocessing method 200 further includes the step of: before the reduction processing, determining whether the photovoltaic EL image is a grayscale image; if so, converting the photovoltaic EL image into a BGR format image. When the image to be processed is determined to be a grayscale image, it needs to be converted into BGR format to standardize the input image for easier subsequent operations.

[0052] The photovoltaic EL image preprocessing method of the present invention, on the one hand, can remove black invalid regions from photovoltaic EL images of any battery specification through adaptive threshold binarization and connected component processing, and has high generalization ability; on the other hand, by reducing the size of the photovoltaic EL image, the computational load of adaptive threshold binarization can be reduced.

[0053] Figure 6 yes Figure 2 A flowchart of the photovoltaic EL image preprocessing method in an optimized embodiment. (See attached flowchart.) Figure 6 As shown, compared to photovoltaic EL image preprocessing method 200, photovoltaic EL image preprocessing method 600 further includes the following steps:

[0054] Step S26: Obtain relevant parameters of the photovoltaic EL image, including cell specifications, horizontal offset, and vertical offset, where the cell specifications are M*N, and M and N are positive integers.

[0055] by Figure 1 Taking a photovoltaic EL image 100 as an example, the cell specifications, horizontal offset, and vertical offset of the photovoltaic EL image 100 are obtained. (Reference) Figure 5 As shown, the battery specification is 5*22. The lateral offset includes the lateral offset coordinate x1 and the lateral offset width d1, and the vertical offset includes the vertical offset coordinate y1 and the vertical offset width d2.

[0056] Step S27: Cut the second image into M*N battery cell images according to the relevant parameters.

[0057] Figure 7 yes Figure 6 A flowchart of an embodiment of step S27. Figure 8 yes Figure 7 A flowchart of an embodiment of step S271. Figure 9 yes Figure 7 A flowchart of an embodiment of step S272. (See attached flowchart.) Figure 7 As shown, step S27 includes:

[0058] Step S271: Calculate the size of a single battery cell image based on relevant parameters and the second image.

[0059] like Figure 8 As shown, step S271 includes:

[0060] Step S2711: Obtain the width and height of the second image;

[0061] Step S2712: Subtract the horizontal offset width from the width of the second image, and then divide the width of the individual battery cell image evenly according to the battery specifications.

[0062] Step S2713: Subtract the vertical offset width from the height of the second image, and then divide the height of the individual battery cell image evenly according to the battery specifications.

[0063] refer to Figure 5 As shown, by obtaining the width W and height H of the second image, the width W1 and height H1 of a single battery cell image are respectively:

[0064]

[0065]

[0066] Where W and H are the width and height of the second image, d1 is the horizontal offset width, d2 is the vertical offset width, M and N are the battery specifications, and n is the number of vertical offsets. Figure 5 In the given information, n = 2, M = 5, and N = 22.

[0067] Step S272: Calculate the coordinates of each battery cell image based on the size, horizontal offset, and vertical offset of the individual battery cell image, and traverse the second image according to the coordinates and cut the second image.

[0068] like Figure 9 As shown, step S272 includes:

[0069] Step S2721: Divide the horizontal offset coordinate by the width of a single cell image to calculate the column value that needs to be added to the horizontal offset width.

[0070] Step S2722: Divide the vertical offset coordinate by the height of a single battery cell image to calculate the row value that needs to be added to the vertical offset width.

[0071] Step S2723: Calculate the coordinates of each battery cell image based on its size, column value, row value, horizontal offset width, and vertical offset width.

[0072] Continue to refer to Figure 5 As shown, dividing the horizontal offset coordinate x1 by the width W1 of a single battery cell image yields the column number of the battery cell image that needs the horizontal offset width added. In this embodiment, the 12th battery cell image needs the horizontal offset width added. Therefore, the top-left corner coordinates of the battery cell image in the first row and first column are (K*x0, K*y0), and the bottom-right corner coordinates are (K*x0+W1, K*y0+H1). The top-left corner coordinates of the battery cell image in the first row and 12th column are (K*x0+W1*11+d1, K*y0), and the bottom-right corner coordinates are (K*x0+W1*12+d1, K*y0+H1*12).

[0073] Dividing the horizontal offset coordinate y1 by the width H1 of a single cell image will give you the row number of the cell image that needs to have the vertical offset width added. For example... Figure 5 As shown, in this embodiment, due to the presence of two second grid lines, it can be calculated that the battery cell images in the third and fourth rows need to have a horizontal offset width added. The coordinates of the top left corner of the battery cell image in the first column of the third row are (K*x0, K*y0+H1*2+d2), and the coordinates of the bottom right corner are (K*x0+W1, K*y0+K*y0+H1*3+d2). By traversing the second image according to the coordinates of each battery cell image and cutting the second image, M*N battery cell images are obtained.

[0074] In some embodiments, the method further includes uniformly resizing the cut individual battery cell images to facilitate subsequent image stitching. Optionally, the battery cell images are resized to a target size, wherein the width and height of the target size are equal. The target size is determined by hardware, model, and accuracy requirements. Preferably, the target size is 512*512. During adjustment, the longer side is first extended to the target size, the magnification or reduction factor is calculated, the shorter side is scaled by this factor, and the remaining space is filled with a fixed value, ultimately resulting in a relatively undistorted target-size image.

[0075] In some embodiments, the method further includes converting the battery cell image into an RGB format image and normalizing the pixel values ​​in the RGB format image. A single battery image is in BGR format; the image is converted from BGR format to an RGB format image that is operable by the PyTorch deep learning framework. Normalizing the pixel values ​​in the RGB format image involves transforming each pixel value to 1 / 255 of its original value, changing the range from (0, 255) to (0.0, 1.0), which accelerates convergence while ensuring that large and small pixel values ​​can be used equally.

[0076] In some embodiments, the method further includes stitching together multiple battery cell images. Depending on the hardware and model, the resulting battery cell images are stitched together in batches and then fed into the model for inference to maximize resource utilization.

[0077] This application also includes a photovoltaic EL image preprocessing apparatus, comprising a memory and a processor. The memory stores instructions executable by the processor; the processor executes these instructions to implement the photovoltaic EL image preprocessing method described above.

[0078] Figure 10 This is a system block diagram of a photovoltaic EL image preprocessing apparatus according to an embodiment of this application. (Reference) Figure 10As shown, the photovoltaic EL image preprocessing device 1000 may include an internal communication bus 1001, a processor 1002, a read-only memory (ROM) 1003, a random access memory (RAM) 1004, and a communication port 1005. When applied to a personal computer, the photovoltaic EL image preprocessing device 1000 may also include a hard disk 1006. The internal communication bus 1001 enables data communication between the components of the photovoltaic EL image preprocessing device 1000. The processor 1002 can perform judgments and issue prompts. In some embodiments, the processor 1002 may consist of one or more processors. The communication port 1005 enables data communication between the photovoltaic EL image preprocessing device 1000 and external devices. In some embodiments, the photovoltaic EL image preprocessing device 1000 can send and receive information and data from a network through the communication port 1005. The photovoltaic EL image preprocessing device 1000 may also include different types of program storage units and data storage units, such as a hard disk 1006, a read-only memory (ROM) 1003, and a random access memory (RAM) 1004, capable of storing various data files used for computer processing and / or communication, as well as possible program instructions executed by the processor 1002. The processor executes these instructions to implement the main part of the method. The results of the processor processing are transmitted to the user equipment via a communication port and displayed on the user interface.

[0079] The above-described operation method can be implemented as a computer program, stored in the hard disk 1006, and loaded into the processor 1002 for execution to implement the photovoltaic EL image preprocessing method of this application.

[0080] This application also includes a computer-readable medium storing computer program code that, when executed by a processor, implements the photovoltaic EL image preprocessing method described above.

[0081] When a photovoltaic EL image preprocessing method is implemented as a computer program, it can also be stored as an article of manufacture in a computer-readable storage medium. For example, computer-readable storage media can include, but are not limited to, magnetic storage devices (e.g., hard disks, floppy disks, magnetic stripes), optical discs (e.g., compact discs (CDs), digital multifunction discs (DVDs)), smart cards, and flash memory devices (e.g., electrically erasable programmable read-only memory (EPROM), cards, sticks, key drives). Furthermore, the various storage media described herein can represent one or more devices and / or other machine-readable media used for storing information. The term "machine-readable medium" can include, but is not limited to, wireless channels and various other media (and / or storage media) capable of storing, containing, and / or carrying code and / or instructions and / or data.

[0082] It should be understood that the embodiments described above are merely illustrative. The embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or any combination thereof. For hardware implementation, the processor may be implemented within one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), processors, controllers, microcontrollers, microprocessors, and / or other electronic units designed to perform the functions described herein, or combinations thereof.

[0083] Some aspects of this application can be executed entirely by hardware, entirely by software (including firmware, resident software, microcode, etc.), or by a combination of hardware and software. The aforementioned hardware or software may be referred to as a "data block," "module," "engine," "unit," "component," or "system." The processor may be one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DAPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), processors, controllers, microcontrollers, microprocessors, or combinations thereof. Furthermore, aspects of this application may manifest as computer products residing in one or more computer-readable media, including computer-readable program code. For example, computer-readable media may include, but are not limited to, magnetic storage devices (e.g., hard disks, floppy disks, magnetic tapes, etc.), optical discs (e.g., compressed CDs, digital multifunction DVDs, etc.), smart cards, and flash memory devices (e.g., cards, sticks, key drives, etc.).

[0084] A computer-readable medium may contain a propagated data signal containing computer program code, for example, on baseband or as part of a carrier wave. This propagated signal may take various forms, including electromagnetic, optical, and so on, or suitable combinations thereof. A computer-readable medium can be any computer-readable medium other than a computer-readable storage medium, which can be connected to an instruction execution system, apparatus, or device to enable communication, propagation, or transmission of a program for use. The program code located on the computer-readable medium can be propagated through any suitable medium, including radio, cable, fiber optic cable, radio frequency signals, or similar media, or any combination of the above media.

[0085] The basic concepts have been described above. Obviously, for those skilled in the art, the above disclosure is merely illustrative and does not constitute a limitation of this application. Although not explicitly stated herein, those skilled in the art may make various modifications, improvements, and corrections to this application. Such modifications, improvements, and corrections are suggested in this application, and therefore remain within the spirit and scope of the exemplary embodiments of this application.

Claims

1. A photovoltaic EL image preprocessing method, characterized in that, include: Acquire the photovoltaic EL image to be processed; The size of the photovoltaic EL image is reduced, and the reduced image is denoted as the first image; The first image is binarized using an adaptive threshold. The binarized first image is first opened and then closed to remove noise black spots on the image. Adjacent pixels with the same value are grouped into the same connected region to obtain multiple connected regions. Calculate the area of ​​multiple connected regions and select the connected region with the largest area as the target connected region. Calculate the position of the target connected region on the first image in the photovoltaic EL image, and cut out the black invalid region in the photovoltaic EL image according to the position to obtain the second image; Obtain relevant parameters from the photovoltaic EL image, including cell specifications, lateral offset, and vertical offset, wherein the cell specifications are M. N, M, and N are positive integers; The second image is cut into M segments according to the relevant parameters. N solar cell images; wherein, reducing the size of the photovoltaic EL image includes: reducing the width and height of the photovoltaic EL image to 1 / K of the original, where K is a positive integer; The process of removing the black invalid region in the photovoltaic EL image includes: obtaining the coordinates of the top-left corner (x0, y0) and the bottom-right corner (x0+w, y0+h) of the target connected region in the first image, where w is the width of the first image and h is the height of the first image; multiplying the top-left corner (x0, y0) and the bottom-right corner (x0+w, y0+h) by K to obtain the coordinates of the top-left corner in the photovoltaic EL image (K... x0, K y0) and the coordinates of the lower right corner in the photovoltaic EL image (K) (x0+w), K (y0+h)); based on coordinates (K) x0, K y0) and coordinates (K) (x0+w), K (y0+h)) Remove the black invalid region in the photovoltaic EL image.

2. The method as described in claim 1, characterized in that, Calculating the position of the target connected region on the first image in the photovoltaic EL image includes: Obtain the top-left and bottom-right corner coordinates of the target connected region in the first image; The positions of the top-left and bottom-right corners in the photovoltaic EL image are obtained by multiplying the values ​​of the top-left and bottom-right corners by K.

3. The method as described in claim 1, characterized in that, The second image is cut into M segments according to the relevant parameters. The N battery cell images include: The size of a single battery cell image is calculated based on the relevant parameters and the second image; The coordinates of each battery cell image are calculated based on the size of the individual battery cell image, the horizontal offset, and the vertical offset. The second image is then traversed and segmented based on the coordinates.

4. The method as described in claim 3, characterized in that, Calculating the size of a single battery cell image based on the relevant parameters and the second image includes: Obtain the width and height of the second image; Subtract the horizontal offset width from the width of the second image, and then divide the width of the individual battery cell image equally according to the battery specifications; Subtract the vertical offset width from the height of the second image, and then divide the image equally according to the battery specifications to obtain the height of a single battery cell image; The lateral offset includes lateral offset coordinates and lateral offset width, and the longitudinal offset includes longitudinal offset coordinates and longitudinal offset width.

5. The method as described in claim 4, characterized in that, Calculating the coordinates of each battery cell image based on its size, the horizontal offset, and the vertical offset includes: Divide the horizontal offset coordinate by the width of the single battery cell image to calculate the column value that needs to be added to the horizontal offset width; Divide the vertical offset coordinate by the height of the single battery cell image to calculate the row value that needs to be added to the vertical offset width; The coordinates of each battery cell image are calculated based on the size of the individual battery cell image, the column value, the row value, the horizontal offset width, and the vertical offset width.

6. The method as described in claim 1, characterized in that, Also includes: The size of the battery cell image is adjusted to a target size, wherein the width and height of the target size are equal.

7. The method as described in claim 1, characterized in that, Also includes: The battery cell image is converted into an RGB format image, and the pixel values ​​in the RGB format image are normalized.

8. The method according to any one of claims 1 to 6, characterized in that, Also includes: Before scaling down, it is determined whether the photovoltaic EL image is a grayscale image. If so, the photovoltaic EL image is converted into a BGR format image.

9. A photovoltaic EL image preprocessing device, characterized in that, include: Memory is used to store instructions that can be executed by the processor; A processor for executing the instructions to implement the method as described in any one of claims 1-8.

10. A computer-readable medium storing computer program code that, when executed by a processor, implements the method as claimed in any one of claims 1-8.

Citation Information

Patent Citations

  • Photovoltaic module defect detection method and system

    CN114187260A