Method for identifying and positioning pitting corrosion and cracks of solar photovoltaic panel under deep and far sea
By pre-processing and model training on the images of the surface of offshore solar photovoltaic panels, combined with sliding detection frame method and multi-scale detection, the problems of insufficient identification accuracy and inaccurate positioning in the prior art are solved, and accurate identification and positioning of pitting corrosion and cracks are achieved, and detection accuracy and work efficiency are improved.
Patent Information
- Application Number
- CN202510452293.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-11
- Publication Date
- 2025-05-09
- Estimated Expiration
- 2045-04-11
AI Technical Summary
In the automated detection of offshore solar photovoltaic panels, the identification accuracy is insufficient and the positioning is inaccurate, making it difficult to effectively identify and locate pitting and cracks on the surface of the photovoltaic panel.
By collecting images of the photovoltaic panel surface, performing data preprocessing and model training, building a loss function and an optimizer, using sliding detection frame method and multi-scale detection, combining edge detection, segmentation loss and generalized Dice loss, the accurate identification and positioning of pitting and cracks is achieved.
It realizes accurate identification and positioning of pitting and cracks on the surface of offshore solar photovoltaic panels, improves detection accuracy and work efficiency, and can timely issue maintenance alarms to ensure the normal operation and power generation efficiency of photovoltaic panels.
Smart Images

Figure CN119964017A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of intelligent detection technology, and in particular relates to a method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels. Background Art
[0002] With the growing demand for clean energy, offshore solar photovoltaic panels are increasingly being used. However, due to factors such as anti-corrosion, their construction height is relatively high, making it impossible for maintenance ships to conduct manual inspections directly after they approach. With the widespread use of offshore solar photovoltaic panels, the harsh conditions of the marine environment have caused different types of damage to the surface of photovoltaic panels, especially pitting and cracks, which seriously affect the service life and power generation efficiency of photovoltaic panels. Due to the need for anti-corrosion construction, offshore photovoltaic panels are usually installed at a higher position, making it impossible for maintenance ships to conduct manual inspections directly after they approach. This urgently requires an automated detection technology that can accurately identify and locate defects such as pitting and cracks on the surface of photovoltaic panels to ensure the normal operation and power generation efficiency of photovoltaic panels.
[0003] The existing offshore photovoltaic panel inspection method relies on unmanned ships or drones equipped with cameras to collect images and process them manually or with simple algorithms, but there are still problems such as insufficient recognition accuracy and inaccurate positioning. In order to improve detection accuracy and work efficiency, a new image recognition and positioning method is urgently needed. Summary of the invention
[0004] The present invention is mainly to overcome the deficiencies of the prior art and provides a method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels.
[0005] The present invention is achieved through the following technical solutions: A method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels, the specific steps are as follows: Step 1: Collect the surface image of the photovoltaic panel; Step 2: Perform preprocessing operations such as data cleaning, normalization, standardization, labeling, processing missing values, and balancing categories on the data set of photovoltaic panel surface images collected in step 1; Step 3: Construct a photovoltaic panel pitting and crack defect recognition model; Step 3.1: Construct the loss function. The total loss function consists of three parts equipped with weight coefficients: edge detection loss, segmentation loss and generalized Dice loss function; Step 3.2: Design the optimizer: introduce continuous adaptive gradient flow and combine it with stability hyperparameters to update the model training parameters; Step 3.3: Use the training data from step 2 to train the model. In each iteration, input the training data into the model, calculate the loss through the loss function in step 3.1, update the model parameters through the optimizer in step 3.2, and continuously adjust the model to reduce the loss so that the model can learn the patterns and rules in the data. Step 4: Locate the location of pitting and cracks; Step 4.1: Use the sliding detection frame method to detect the image. At each detection frame position, use the model trained in step 3 to classify the image in the detection frame to obtain candidate detection frames with pitting and cracks. Step 4.2: Scale the image at different ratios to generate a multi-scale image, and repeat the sliding detection box detection process in step 4.1 to detect pitting and crack areas of different sizes; Step 4.3: For the candidate detection frames obtained in steps 4.1 and 4.2, remove redundant and overlapping detection frames, and finally retain the detection frame that is most likely to represent the real damage to determine the location of the damage.
[0006] In the above technical solution, in step 1, a reflector is installed around the photovoltaic panel, and the reflector is installed on an angle adjustment mechanism with an adjustable angle, and the angle of the reflector is adjusted by controlling the angle adjustment mechanism; a camera is arranged under the reflector to receive the surface image of the photovoltaic panel reflected by the reflector.
[0007] In the above technical solution, the edge detection loss , used to capture the pitting and crack edges in the image, based on the gradient information or the edge features of the image, calculated using the edge detection algorithm, and used to measure the gap between the edge of the segmented image and the true edge gradient; ; in, : The model predicts that the image is at position The gradient value at ; : The true label image is at position The gradient value at .
[0008] In the above technical solution, the segmentation loss , by calculating the difference between the predicted image and the true label, the image's pitting and crack segmentation capabilities are optimized: ; in, : The true label image is at position The value at : The model predicts that the image is at position The probability value at .
[0009] In the above technical solution, the generalized Dice loss , which is used to deal with the problem of unbalanced categories and measure the overlap between the predicted area and the true area: ; in, : The model predicts that the image is at position The pixel value of : The true label image is at position The pixel value of : Sum all pixel positions in the image.
[0010] In the above technical solution, step 3.2 includes the following steps: Step 3.2.1: Define the gradient update rule: ; : At time The squared gradient update of ; : Exponential decay coefficient scheduling, which controls the contribution of the previous estimate to the current estimate. It is a vector-valued function with a value range of between and defined in time superior; : Current parameters The square of the gradient of the loss function under ; :time The cumulative estimate of the squared gradient of ; Step 3.2.2: Define the second moment update rule: ; :time The cumulative estimate of the square of the parameter updates; : At time Parameters The update step length is calculated as in step 3.2.3; :time The cumulative estimate of the square of the parameter updates; Step 3.2.3: Define parameter update rules: ; :time Parameter update, applying it to the current parameters ; : Numerical stability term, to prevent numerical problems such as division by zero during updates; : Numerical stability term, used to stabilize the gradient flow; : Current parameters The gradient of the loss function under is used to calculate the update step size.
[0011] In the above technical solution, in step 4.3, for multiple candidate detection boxes , is the total number of detection boxes, each detection box has a confidence score , confidence score According to the probability value of the detection box To calculate; use the non-maximum suppression algorithm to remove redundant and overlapping detection frames according to the set threshold. The process is as follows: ①. According to the confidence score Sort the detection boxes from large to small; ②. Select the detection box with the highest confidence as a retention box; ③. Calculation Intersection and union with other detection boxes ; ④ If Greater than the set threshold , then remove the detection box ; ⑤. Repeat steps ② to ④ until all detection frames are processed.
[0012] In the above technical solution, the positioning results are recorded and stored, and the data is transmitted to the monitoring center or the equipment of relevant maintenance personnel through wireless communication so that repair and maintenance work can be arranged in time.
[0013] The advantages and beneficial effects of the present invention are: The present invention automatically inspects offshore solar photovoltaic panels, and the regularly collected images and positioning results can determine the location of damage such as pitting and cracks on the surface of the photovoltaic panels, and issue maintenance alarms in advance to help operation and maintenance personnel perform maintenance work in a timely manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] Figure 1 It is a flow chart of the method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels of the present invention.
[0015] For ordinary technicians in this field, other relevant drawings can be obtained based on the above drawings without any creative work. DETAILED DESCRIPTION
[0016] In order to enable those skilled in the art to better understand the technical solution of the present invention, the technical solution of the present invention is further described below in conjunction with specific embodiments.
[0017] The present invention designs a method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels, and the specific steps are as follows: Step 1: Collect the surface image of the photovoltaic panel.
[0018] In this embodiment, a reflector is combined with a camera to collect images of the photovoltaic panel surface. Specifically, a reflector is installed around the photovoltaic panel, and the reflector is installed on an angle adjustment mechanism with adjustable angles. The angle of the reflector is adjusted by controlling the angle adjustment mechanism, so that the reflector can capture images at different angles as needed to ensure that the entire photovoltaic panel area is covered.
[0019] A camera is arranged below the reflector to receive the surface image of the photovoltaic panel reflected by the reflector.
[0020] Set up a program for timed image acquisition and determine the acquisition frequency according to actual needs, such as collecting images once every hour or at a specific time every day. This method can collect images of the photovoltaic panel surface at regular intervals without touching the photovoltaic panel, making it easier to implement regular inspections.
[0021] Step 2: For the dataset of photovoltaic panel surface images collected in step 1, perform preprocessing operations such as data cleaning, normalization, standardization, adding labels, processing missing values, and balancing categories to ensure the quality and availability of the data and make the data suitable for model training.
[0022] Step 3: Construct a photovoltaic panel pitting and crack defect recognition model.
[0023] The present invention introduces an improved loss function and optimizer, which is helpful for the training and convergence of the model. The specific steps are as follows.
[0024] Step 3.1: Construct the loss function.
[0025] The total loss function consists of three parts with assigned weight coefficients: edge detection loss, segmentation loss, and generalized Dice loss function; ; : Total loss function, which represents the ultimate goal of model optimization; : edge detection loss, : segmentation loss, : Generalized Dice loss; : Weight coefficient of edge detection loss, : weight coefficient of segmentation loss, : Weight coefficient of Dice loss.
[0026] The edge detection loss , used to capture the pitting and crack edges in the image. It is calculated based on the gradient information or the edge features of the image using an edge detection algorithm (such as the Sobel operator, the Canny operator, etc.) to measure the gap between the edge of the segmented image and the true edge gradient: ; in, : The model predicts that the image is at position The gradient value at ; : The true label image is at position The gradient value at .
[0027] The segmentation loss , by calculating the difference between the predicted image and the true label, the image's pitting and crack segmentation capabilities are optimized: ; in, : The true label image is at position The value at (0 or 1, indicating whether it is a pitting and crack area); : The model predicts that the image is at position The probability value at (indicating the probability of being predicted as pitting and crack areas).
[0028] The generalized Dice loss , which is used to deal with the problem of unbalanced categories. It can effectively measure the overlap between the predicted area and the true area, especially when the target area is small or sparse: ; in, : The model predicts that the image is at position The pixel value of (0 or 1, indicating whether it is a pitting and crack area); : The true label image is at position The pixel value of (0 or 1, indicating whether it is a pitting and crack area); : Sum all pixel positions in the image.
[0029] Step 3.2: Build the optimizer: Update the model training parameters by introducing a continuous adaptive gradient flow and combining it with stability hyperparameters. The specific steps are as follows.
[0030] Step 3.2.1: Define the gradient update rule: ; : At time The squared gradient update of ; : Exponential decay coefficient scheduling, which controls the contribution of the previous estimate to the current estimate. It is a vector-valued function with a value range of between and defined in time superior; : Current parameters The square of the gradient of the loss function under ; :time The cumulative estimate of the squared gradient of .
[0031] Step 3.2.2: Define the second moment update rule: ; :time The cumulative estimate of the square of the parameter updates; : At time Parameters The update step length is calculated as in step 3.2.3; :time The cumulative estimate of the square of the parameter updates.
[0032] Step 3.2.3: Define parameter update rules: ; :time Parameter update, applying it to the current parameters ; : Numerical stability term, which prevents numerical problems such as division by zero during updates (usually a very small positive number); : Numerical stability term, used to stabilize the gradient flow (usually a small positive number); : Current parameters The gradient of the loss function under is used to calculate the update step size.
[0033] Step 3.2: After building the above model, use the training data in step 2 to train the model. In each iteration, input the training data into the model, calculate the loss through the loss function in step 3.1, update the model parameters through the optimizer in step 3.2, and continuously adjust the model to reduce the loss so that the model can learn the patterns and rules in the data.
[0034] Step 4: Locate the pitting and cracks.
[0035] Step 4.1: Use the sliding detection frame method to detect the image to determine whether there are pitting or cracks.
[0036] First, set the appropriate detection frame size and moving step length, start from the upper left corner of the image, and slide on the image with a certain step length. At each detection frame position, use the model trained in step 3 to classify the image in the detection frame to determine whether there are pitting or cracks.
[0037] Step 4.1.1: Slide the position of the detection box.
[0038] Assume the image size is , the detection box size is ,in is the height of the detection box, is the brightness of the detection box, and the step size is and , then the current position of the sliding detection box It can be expressed by the following formula: ; : The coordinates of the upper left corner of the detection box; : The position index of the current detection frame; : Sliding step length in horizontal and vertical directions; : The height and width of the detection box.
[0039] Step 4.1.2: Classification of images within the detection box.
[0040] At the position of each sliding detection frame , image classification is performed through the trained defect recognition model, and the probability value of whether it contains pitting or cracks is output , which is expressed by the following formula: ; : Detection box the classification probability of the location, indicating whether the area contains pitting or cracks; : Trained defect recognition model; : Current detection frame position The image area on the .
[0041] The probability value The detection boxes with probability greater than the set threshold are considered as candidate detection boxes with pitting or cracks.
[0042] Step 4.2: Scale the image at different scales to generate multi-scale images, and repeat the sliding detection frame detection process in step 4.1 to detect pitting and crack areas of different sizes. This operation can effectively enhance the accuracy and robustness of the model in detecting damage of different sizes, thereby improving the detection capability of pitting and crack areas of different sizes.
[0043] Step 4.3: For the candidate detection frames obtained in steps 4.1 and 4.2, remove redundant and overlapping detection frames, and finally retain the detection frame that is most likely to represent the real damage, so as to determine the location of the damage.
[0044] For multiple candidate detection boxes , is the total number of detection boxes, each detection box has a confidence score , confidence score The probability value of the detection box To calculate; use the non-maximum suppression algorithm to remove redundant and overlapping detection frames according to the set threshold. The process is as follows: ①. According to the confidence score Sort the detection boxes from large to small; ②. Select the detection box with the highest confidence as a retention box; ③. Calculation Intersection and union with other detection boxes ; ④ If Greater than the set threshold , then remove the detection box ; ⑤. Repeat steps ② to ④ until all detection frames are processed.
[0045] The intersection-over-union ratio is used to measure the degree of overlap between two detection frames, and its calculation formula is as follows: ; : Detection box and The intersection-and-union ratio between them; : Detection box and The intersection area of ; : Detection box and The union area of .
[0046] Finally, the positioning results are recorded and stored, and the data can be transmitted to the monitoring center or the equipment of relevant maintenance personnel through wireless communication and other means, so as to arrange repair and maintenance work in time.
[0047] Experimental verification The present invention collected 5,000 images, including 3,000 images without corrosion and cracks and 2,000 images with pitting and cracks. These image datasets were randomly divided into training set, validation set and test set, where the test set and validation set each accounted for 15% of the dataset (30% in total), and the relative proportion of each type of image in each subset was the same as the total dataset. The model evaluation indicators are as follows: Accuracy: It is used to measure the proportion of samples that are correctly classified by the model. The calculation formula is: ; Among them, TP is a true positive example (the model predicts a positive example and it is actually a positive example), TN is a true negative example (the model predicts a negative example and it is actually a negative example), FP is a false positive example (the model predicts a positive example but it is actually a negative example), and FN is a false negative example (the model predicts a negative example but it is actually a positive example).
[0048] F1 score: It is the harmonic mean of precision and recall. Precision indicates the proportion of positive examples predicted by the model and correct, while recall indicates the proportion of positive examples that are actually predicted by the model and correct. The formula for calculating F1 score is: ; ; ; Receiver operating characteristic area under the curve (ROC AUC): used to evaluate the performance of the model at different classification thresholds. The ROC curve depicts the relationship between the true positive rate (TPR, equivalent to the recall rate) and the false positive rate (FPR). The larger the AUC value, the better the model's adaptability to different thresholds.
[0049] Area under the precision-recall curve (P-RAUC): Similar to ROCAUC, it is used to evaluate the performance of a binary classification model at different thresholds. It is especially suitable for cases with imbalanced categories. The P-RAUC curve shows the relationship between precision and recall. The higher the AUC value, the better the model performance. ;
[0050] As shown in Table 1, the accuracy of the method of the present invention is significantly higher than that of the CNN model, indicating that the method of the present invention performs better in classification correctness. The F1 score of the method of the present invention is also better than that of CNN, indicating that it performs better in balancing precision and recall. The ROC AUC of the method of the present invention is 0.95, which is higher than 0.91 of CNN, indicating that the performance of the method of the present invention is better at each classification threshold. The P-RAUC of the method of the present invention is 0.92, which is significantly higher than 0.87 of CNN, indicating that it has stronger detection ability in the case of class imbalance.
[0051] The present invention is described above by way of example. It should be noted that, without departing from the core of the present invention, any simple deformation, modification or other equivalent replacement that can be made by those skilled in the art without inventive effort falls within the protection scope of the present invention.
Claims
1. A method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels, characterized in that: The following steps are involved: Step 1: Collect the surface image of the photovoltaic panel; Step 2: Perform preprocessing operations such as data cleaning, normalization, standardization, labeling, processing missing values, and balancing categories on the data set of photovoltaic panel surface images collected in step 1; Step 3: Construct a photovoltaic panel pitting and crack defect recognition model; Step 3.1: Construct the loss function. The total loss function consists of three parts equipped with weight coefficients: edge detection loss, segmentation loss and generalized Dice loss function; Step 3.2: Design the optimizer: introduce continuous adaptive gradient flow and combine it with stability hyperparameters to update the model training parameters; Step 3.3: Use the training data from step 2 to train the model. In each iteration, input the training data into the model, calculate the loss through the loss function in step 3.1, update the model parameters through the optimizer in step 3.2, and continuously adjust the model to reduce the loss so that the model can learn the patterns and rules in the data. Step 4: Locate the location of pitting and cracks; Step 4.1: Use the sliding detection frame method to detect the image. At each detection frame position, use the model trained in step 3 to classify the image in the detection frame to obtain candidate detection frames with pitting and cracks. Step 4.2: Scale the image at different ratios to generate a multi-scale image, and repeat the sliding detection box detection process in step 4.1 to detect pitting and crack areas of different sizes; Step 4.3: For the candidate detection frames obtained in steps 4.1 and 4.2, remove redundant and overlapping detection frames, and finally retain the detection frame that is most likely to represent the real damage to determine the location of the damage.
2. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: In step 1, a reflector is installed around the photovoltaic panel, and the reflector is installed on an angle adjustment mechanism with an adjustable angle, and the angle of the reflector is adjusted by controlling the angle adjustment mechanism; a camera is arranged under the reflector to receive the surface image of the photovoltaic panel reflected by the reflector.
3. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: The edge detection loss , used to capture the pitting and crack edges in the image, based on the gradient information or the edge features of the image, calculated using the edge detection algorithm, and used to measure the gap between the edge of the segmented image and the true edge gradient; ; in, : The model predicts that the image is at position The gradient value at ; : The true label image is at position The gradient value at .
4. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: The segmentation loss , by calculating the difference between the predicted image and the true label, the image's pitting and crack segmentation capabilities are optimized: ; in, : The true label image is at position The value at : The model predicts that the image is at position The probability value at .
5. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: The generalized Dice loss , which is used to deal with the problem of unbalanced categories and measure the overlap between the predicted area and the true area: ; in, : The model predicts that the image is at position The pixel value of : The true label image is at position The pixel value of : Sum all pixel positions in the image.
6. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: Step 3.2 includes the following steps: Step 3.2.1: Define the gradient update rule: ; : At time The squared gradient update of ; : Exponential decay coefficient scheduling, which controls the contribution of the previous estimate to the current estimate. It is a vector-valued function with a value range of between and defined in time superior; : Current parameters The square of the gradient of the loss function under ; :time The cumulative estimate of the squared gradient of ; Step 3.2.2: Define the second moment update rule: ; :time The cumulative estimate of the square of the parameter updates; : At time Parameters The update step length is calculated as in step 3.2.3; :time The cumulative estimate of the square of the parameter updates; Step 3.2.3: Define parameter update rules: ; :time Parameter update, applying it to the current parameters ; : Numerical stability term, to prevent numerical problems such as division by zero during updates; : Numerical stability term, used to stabilize the gradient flow; : Current parameters The gradient of the loss function under is used to calculate the update step size.
7. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: In step 4.3, for multiple candidate detection boxes , is the total number of detection boxes, each detection box has a confidence score , confidence score According to the probability value of the detection box To calculate; use the non-maximum suppression algorithm to remove redundant and overlapping detection frames according to the set threshold. The process is as follows: ①. According to the confidence score Sort the detection boxes from large to small; ②. Select the detection box with the highest confidence as a retention box; ③. Calculation Intersection and union with other detection boxes ; ④ If Greater than the set threshold , then remove the detection box ; ⑤. Repeat steps ② to ④ until all detection frames are processed.
8. The method for identifying and locating pitting and cracks of deep-sea solar photovoltaic panels according to claim 1, characterized in that: The positioning results are recorded and stored, and the data are transmitted to the monitoring center or the equipment of relevant maintenance personnel through wireless communication.
Citation Information
Patent Citations
Adaptive optimization training method of convolutional neural network for image classification
CN115205577A
Photovoltaic module evaluation method and system based on AI visual inspection algorithm
CN118261878A
Photovoltaic panel external damage detection method based on multi-task joint training
CN119006439A
Lithium battery life prediction method based on DCAE-Transformer
CN119044778A
Remote sensing image ground object segmentation method based on hierarchical feature extraction and decoding
CN119672555A