Polarization Super-Resolution Photovoltaic Panel Defect Detection via Deep Learning

Photovoltaic power generation has experienced unprecedented growth in recent years. By 2023, the cumulative installed photovoltaic capacity worldwide reached 1.6 TW, and the increasing deployment of solar panels requires reliable and cost-effective inspection techniques. Since solar panels are often installed in deserts, plateaus, or mountainous areas, they are exposed to harsh environmental conditions such as sand, rain, hail, and bird droppings, leading to various surface defects including cracks, dust accumulation, and foreign object coverage. These physical defects may eventually cause hot-spot effects, which degrade the overall efficiency of solar panel systems and can even create safety hazards. Therefore, regular inspection and early detection of solar panel defects are essential for maintaining the performance and safety of photovoltaic plants.

Traditional inspection methods include manual inspection, electrical analysis, and computer vision based techniques. Manual inspection is slow and impractical for large-scale solar farms. Electrical analysis monitors circuit abnormalities but cannot localize specific surface defects. Computer vision methods based on infrared or electroluminescence imaging have been widely studied, but visible-light methods are more effective for preventive maintenance because they capture surface-level physical anomalies. However, visible-light inspection under challenging environments, such as strong reflection or haze, suffers from poor contrast. Polarization imaging offers a promising alternative because it exploits the polarization state of reflected light, which encodes additional physical information about surface materials, roughness, and defect morphology.

Despite the advantages of polarization imaging, two major challenges hinder its practical application to solar panel inspection. First, polarized wide-field inspection from an unmanned aerial vehicle (UAV) suffers from low image resolution; a polarization sensor typically divides the image into four sub-image channels corresponding to different polarization angles, which further reduces spatial resolution. Low-resolution images lead to false detections and missed defects. Second, polarization image datasets and specialized algorithms are still nascent, especially for solar panel defect detection. The corresponding public datasets are extremely rare, and the existing algorithms are not adapted to the unique characteristics of polarization data.

To overcome these issues, we propose a degradation-aware learning based polarization super-resolution (SR) reconstruction method and a polarization-feature-enhanced object detection algorithm, both specifically designed for solar panel defect detection. We demonstrate that our methods achieve high accuracy and efficiency, even under small-sample or zero-sample conditions, and preserve the essential polarization information that is critical for distinguishing fine defects.

1. Polarization Imaging Fundamentals

Polarization is a fundamental property of light describing the orientation of the electric field oscillations. Natural light is generally unpolarized, but when light is reflected or refracted by a surface, the reflection becomes partially polarized. The polarization state can be characterized by Stokes parameters, which define the intensity and polarization ellipse of the light. For linear polarization, the four intensity images at polarization angles of 0°, 45°, 90°, and 135° are captured simultaneously by a division-of-focal-plane (DoFP) polarization camera. From these intensities, \(I_0, I_{45}, I_{90}, I_{135}\), the Stokes parameters are computed as:

\[
S_0 = I_0 + I_{90}, \quad S_1 = I_0 – I_{90}, \quad S_2 = I_{45} – I_{135}, \quad S_3 = 0.
\]

The degree of linear polarization (\(DoLP\)) and the angle of linear polarization (\(AoLp\)) are then derived as:

\[
DoLP = \frac{\sqrt{S_1^2 + S_2^2}}{S_0}, \qquad AoLP = \frac{1}{2} \arctan\left(\frac{S_2}{S_1}\right).
\]

The \(S_0\) image is essentially the intensity image that resembles a conventional grayscale image, while the \(DoLP\) image emphasizes edges, textures, and material boundaries, and the \(AoLp\) image encodes the orientation of the reflected polarization, which is particularly sensitive to surface orientation and refractive index. These polarization attributes are highly useful for solar panel defect inspection because defects such as cracks, scratches, and glass delamination modify the surface reflection properties and thus produce distinctive polarization signatures.

2. Degradation-Aware Polarization Super-Resolution

The low resolution of DoFP sensors is a bottleneck for wide-field solar panel inspection. A typical DoFP sensor with a \(2448 \times 2048\) pixel array delivers four sub-images, each of size \(1224 \times 1024\). This means that the effective resolution is one quarter of the native sensor resolution. Super-resolution reconstruction is a cost-effective solution to recover high-frequency details from low-resolution polarized images. We design a lightweight network that can learn the mapping from a low-resolution polarization image to a high-resolution counterpart, while simultaneously preserving the physical polarization information.

2.1 Network Architecture

We propose a backbone composed of residual groups with degradation-aware convolutional (DAC) layers. The architecture consists of a down-sampling stage, a feature extraction stage, and an up-sampling stage. The down-sampling stage reduces the spatial size of the input to decrease computational cost, while the up-sampling stage restores the resolution using transposed convolutions. The internal feature extraction employs two residual groups, each containing two DAC layers and one standard \(3 \times 3\) convolution. Unlike conventional super-resolution networks that use fixed convolution kernels, the DAC layers adaptively adjust their kernels based on the estimated degradation representation of the input image.

The degradation representation is obtained by a small encoder that processes the low-resolution image and outputs a compact feature vector. This vector is then transformed through fully-connected layers into a set of \(3 \times 3\) convolution kernels. These kernels are used inside the DAC layers to modulate the features according to the specific degradation. This mechanism, which we call degradation-aware learning, enables the network to handle various degradation types, including blur, noise, and JPEG compression, in a unified framework. The overall SR process can be expressed as:

\[
\hat{I}_{SR} = \mathcal{F}_{\theta}(I_{LR}, \mathbf{k}),
\]

where \(\theta\) denotes the network parameters, \(I_{LR}\) is the low-resolution input, \(\mathbf{k}\) is the degradation kernel derived from the encoder, and \(\hat{I}_{SR}\) is the super-resolved output.

2.2 Polarization Loss Function

Standard SR loss functions, such as \(L_1\) or \(L_2\), focus on pixel-wise similarity and often fail to preserve the polarization parameters that are critical for subsequent defect analysis. We therefore design a composite loss function that combines the conventional \(L_1\) loss with two polarization-specific losses:

\[
\mathcal{L} = L_1 + w_1 \, L_{P-dolp} + w_2 \, L_{P-aolp},
\]

where \(w_1\) and \(w_2\) are learnable weight factors. The \(L_1\) loss is defined as:

\[
L_1 = \frac{1}{N} \sum_{i=1}^N |\hat{y}_i – y_i|,
\]

with \(\hat{y}_i\) and \(y_i\) being the pixel values of the SR and HR reference images, respectively. The \(DoLP\) loss is based on the information entropy of the \(DoLP\) maps, which encourages the network to preserve texture and edge details:

\[
L_{P-dolp} = \sum_{i,j} | \widehat{DoLP}_{i,j} – DoLP_{i,j} | – \frac{1}{N} \sum_{i,j} f(i,j) \log f(i,j),
\]

where \(f(i,j)\) is the joint frequency of pixel intensity and local mean, and \(N\) is the total number of pixels. The \(AoLp\) loss is formulated using the structural similarity index (SSIM) to preserve the angular information and structural coherence:

\[
L_{P-aolp} = 1 – \mathrm{SSIM}(\widehat{AoLp}, AoLp).
\]

The total loss is minimized during training, ensuring that the reconstructed image not only matches the original intensity but also retains the polarization properties.

2.3 Two-Stage Self-Supervised Training Strategy

Because polarization solar panel datasets are extremely rare, we adopt a two-stage self-supervised training strategy. The first stage is a transfer-learning stage that utilizes large-scale conventional super-resolution datasets (e.g., Set5, Set14, DIV2K, Flickr2K) to pre-train the network with only the \(L_1\) loss. This provides robust initial features and reduces convergence time in the second stage. The second stage is a zero-shot learning stage that operates directly on the polarization image to be super-resolved. For a given high-resolution polarization image \(I_{HR}\), we generate its low-resolution degraded version \(I_{LR}\) by applying a set of degradation kernels:

\[
I_{LR} = \mathcal{D}(I_{HR}) = [(I_{HR} * k) \downarrow_{r}] + n,
\]

where \(k\) is a blur kernel, \(\downarrow_{r}\) denotes down-sampling with scale factor \(r\), and \(n\) represents Gaussian noise. This \((I_{LR}, I_{HR})\) pair is used to fine-tune the network on the fly. During this stage, we use the full polarization loss function introduced above. The fine-tuned network is then applied to the original low-resolution polarization image to produce the final SR result.

This zero-shot scheme eliminates the need for a pre-collected training dataset and enables high-quality SR reconstruction from a single polarization image, making it extremely practical for field inspections where ground-truth data are unavailable.

3. Polarization-Enhanced Object Detection for Solar Panel Defects

After reconstructing high-resolution polarization images, the next step is to localize and classify solar panel defects. We develop a lightweight detection network that exploits the rich polarization features to achieve accurate detection under small-sample and zero-sample conditions.

3.1 Polarization Information Fusion Module

The raw polarization camera delivers four polarization intensity images corresponding to 0°, 45°, 90°, and 135°. From these images we can compute the \(S_0\), \(DoLP\), and \(AoLp\) maps. To make the input compatible with CNN-based detectors while maximizing the use of polarization information, we design a polarization fusion module. Instead of simply concatenating all four raw polarization images, we first transform the \(S_0\) image from RGB to Lab color space and keep the three Lab channels for color information. The \(DoLP\) and \(AoLp\) maps are also converted to a single-channel representation by extracting their luminance component. All five channels—\(L, a, b\) of the Lab space, \(DoLP\), and \(AoLp\)—are then concatenated to form a 5-channel polarized input. This fusion reduces the raw 12-channel input (4 polarization angles × 3 color channels) to a compact 5-channel representation that preserves the core polarization features and dramatically reduces the computational burden.

3.2 Lightweight Feature Extraction with Partial Convolutions

To ensure real-time inference on UAVs or embedded devices, we design the detection backbone using partial convolutions (PConv). PConv operates convolution only on a subset of the input channels, leaving the remaining channels unchanged. For an input feature tensor \(X \in \mathbb{R}^{C \times H \times W}\), PConv selects the first \(m\) channels to apply a \(3 \times 3\) convolution and concatenates the output with the untouched channels:

\[
Y = \mathrm{Concat}\left( \mathrm{Conv}(X_{1:m}), X_{m+1:C} \right).
\]

The computational complexity scales as \(H \times W \times k^2 \times m \times n\), which is significantly smaller than a standard convolution. We also combine PConv with depthwise separable convolution to design a C2P module that replaces the widely used C3 module in YOLOv5. The C2P module consists of a pointwise convolution, followed by a channel split operation. One branch goes through a depthwise separable convolution, while the other branch goes through a PConv. The two branches are then concatenated and fused. This structure improves feature extraction capability while reducing the parameter count and GFLOPs.

3.3 Self-Supervised Pseudo-Label Generation

Because labeled solar panel defect data are scarce, we incorporate a self-training pipeline that generates pseudo-labels using unsupervised segmentation. In the first stage, we apply K-means clustering to the polarized images to produce coarse pseudo-labels of defect candidates. These pseudo-labels are used to update the feature extractor. In the second stage, we refine the pseudo-labels using the Normalized Cut (Ncut) algorithm on the extracted features. The refined masks are subsequently used as ground-truth boxes for the detection head. This approach allows the network to learn from unlabeled data, which is especially useful in zero-shot inspection scenarios where defects are not known a priori.

3.4 Loss Function for Detection

Our detection loss integrates multiple components. The overall loss is:

\[
\mathcal{L}_{det} = \mathcal{L}_{CIoU} + \mathcal{L}_{cls} + \mathcal{L}_{DFL},
\]

where \(\mathcal{L}_{CIoU}\) is the Complete IoU box regression loss, \(\mathcal{L}_{cls}\) is the binary cross-entropy classification loss, and \(\mathcal{L}_{DFL}\) is the distribution focal loss. For the box regression loss, we adapt the standard IoU to incorporate polarization information:

\[
IoU_{P} = \lambda_d \cdot \frac{R_{S_0} \cap R_D}{R_{S_0} \cup R_D} + \lambda_d \cdot \frac{R_{DoLP} \cap R_D}{R_{DoLP} \cup R_D} + \lambda_a \cdot \frac{R_{AoLp} \cap R_D}{R_{AoLp} \cup R_D},
\]

where \(R_{S_0}, R_{DoLP}, R_{AoLp}\) are the segmented regions from the three polarization features, \(R_D\) is the detected bounding box, and \(\lambda_d, \lambda_a\) are weight coefficients. This polarization-aware IoU improves the alignment between the predicted boxes and the actual defect boundaries, especially for defects that are more visible in \(DoLP\) or \(AoLp\) than in intensity images.

4. Experiments

We evaluated the proposed SR method and detection method on both public and self-collected datasets. The experiments were conducted on a PC with an Intel Core i7-12700 CPU and an NVIDIA GeForce RTX 4070 GPU with 8 GB memory. The software environment included Python 3.11.5, CUDA 12.1, and PyTorch 2.1.1.

4.1 Super-Resolution Ablation Study

We first studied the impact of different components in the SR network. Table 1 presents the results for various configurations at \(\times 4\) SR reconstruction from a polarized photo set. The configuration marked “NC” refers to a standard \(3 \times 3\) convolutional layer, “DAC” refers to our degradation-aware convolutional layer, and “attention” refers to a \(1 \times 1\) attention module.

Model Residual groups Conv layers per group Structure PSNR (dB) Run time (ms)
A 2 2 NC (3×3) 31.19 3.3
B 2 2 NC + attention 32.85 45.0
C (Ours) 2 2 DAC (3×3) 33.07 4.1
D 2 2 DAC + attention 34.53 63.0
E 2 3 DAC 33.16 6.7
F 2 4 DAC 33.20 9.4
G 1 2 DAC 29.76 1.8
H 3 2 DAC 33.14 8.7
I 4 2 DAC 33.21 11.2

Table 1 shows that incorporating the DAC layer significantly improves the PSNR by about 2 dB compared with a standard convolutional layer (C vs. A). Adding an attention mechanism further improves PSNR but dramatically increases runtime, making it unsuitable for real-time applications. Considering the trade-off between accuracy and speed, configuration C is selected for subsequent experiments.

We also evaluated the influence of the polarization loss components. Table 2 reports the PSNR and SSIM values for the output images and the \(DoLP\)/\(AoLp\) SSIM computed from the SR outputs.

Model Loss function PSNR (dB) DoLP-SSIM AoLp-SSIM
J \(L_2\) 31.23 0.2650 0.0748
K \(L_1\) 32.40 0.3808 0.0920
L \(L_1 + L_{P-dolp}\) 32.16 0.4916 0.1352
M \(L_1 + L_{P-aolp}\) 30.85 0.4135 0.3007
N (Ours) \(L_1 + L_{P-dolp} + L_{P-aolp}\) 32.31 0.5422 0.3229

From Table 2, it is clear that the \(AoLp\) loss alone decreases the PSNR of the intensity image, but the combination of both polarization losses yields the highest \(DoLP\)-SSIM and \(AoLp\)-SSIM while maintaining a competitive PSNR. This confirms that the polarization loss helps preserve the physical polarization information without sacrificing the overall reconstruction quality.

4.2 Super-Resolution Comparison on Polarization Datasets

We compared our proposed ZPSR model with the standard Bicubic interpolation, Bicubic++, DASR, and ZSSR on four different types of blur kernels (kernel = 0, 0.8, 1.6, 2.4). The datasets used were Miki, DOFP30, Simeng, and Polar-SR, and we also collected our own polarization images for validation. Table 3 summarizes the PSNR/SSIM results for \(\times 2\), \(\times 3\), and \(\times 4\) super-resolution tasks.

Method Scale #Params Time (ms) Kernel=0 Kernel=0.8 Kernel=1.6 Kernel=2.4
Bicubic ×2 0.6 34.22/0.9594 30.55/0.8952 26.07/0.8253 23.08/0.7614
×3 30.17/0.8971 26.02/0.8317 22.46/0.7483 20.18/0.6803
×4 27.44/0.8523 24.43/0.7967 20.65/0.7216 18.71/0.6365
Bicubic++ ×2 30K 1.2 35.16/0.9762 31.24/0.9038 26.31/0.8453 23.43/0.7948
×3 32.06/0.9025 27.48/0.8498 22.78/0.7555 20.28/0.6832
×4 31.58/0.8998 25.03/0.8059 20.75/0.6970 18.74/0.6367
DASR ×2 5.8M 92.5 38.98/0.9835 35.59/0.9638 34.62/0.9533 33.75/0.9407
×3 36.82/0.9731 35.03/0.9581 34.07/0.9456 33.35/0.9345
×4 34.71/0.9544 33.79/0.9462 32.37/0.9200 31.67/0.9174
ZSSR ×2 0.22M 35.41/0.9621 32.02/0.9151 29.33/0.8794 27.04/0.8437
×3 33.79/0.9413 30.98/0.9010 28.41/0.8652 26.32/0.8313
×4 32.06/0.9301 30.30/0.8919 27.84/0.8565 25.89/0.8232
ZPSR (Ours) ×2 0.23M 3.7 38.43/0.9814 35.41/0.9621 34.20/0.9475 33.42/0.9356
×3 36.52/0.9711 34.71/0.9544 33.79/0.9413 33.06/0.9301
×4 34.19/0.9518 33.40/0.9410 31.98/0.9219 30.64/0.8966

The results show that ZPSR achieves nearly the same PSNR as DASR under ideal conditions while being significantly faster (3.7 ms vs. 92.5 ms). Under strong degradation conditions (kernel = 2.4), ZPSR outperforms both Bicubic++ and ZSSR by a large margin. This demonstrates that the degradation-aware design effectively adapts to diverse blur kernels.

Table 4 compares the \(DoLP\)-SSIM and \(AoLp\)-SSIM of the SR images from different methods. These metrics evaluate how well the polarization information is preserved. We also show the visual quality by computing SSIM values on the self-collected polarization dataset.

Method \(S_0\)-PSNR (dB) \(DoLP\)-SSIM \(AoLp\)-SSIM
Bicubic 30.52 0.3145 0.1480
Bicubic++ 31.20 0.3680 0.1618
DASR 34.71 0.1225 0.1288
ZSSR 32.06 0.3807 0.3673
ZPSR (Ours) 34.19 0.5422 0.4994

Interestingly, DASR achieves a high PSNR but a much lower \(DoLP\)-SSIM than ZPSR. This implies that DASR tends to smooth the texture and destroy the high-frequency polarization cues. Our zero-shot strategy, on the other hand, explicitly preserves the polarization-related features because the network learns directly from the image’s internal statistics using the polarization loss.

4.3 Object Detection Ablation Study

We constructed a polarization solar panel dataset consisting of 400 images at a resolution of \(300 \times 300\) pixels, of which 200 images (50 defective and 50 flawless, augmented) were used for training/validation experiments. We first evaluated the contribution of the proposed polarization fusion module and the C2P module. Table 5 reports the parameter count, GFLOPs, FPS, and average precision (AP) for various combinations.

Model Structure Param/M GFLOPs FPS AP (%)
O CNN + C3 1.9 1.9 16 86.8
P CNN + FasterBlock 3.9 0.8 25 84.7
Q CNN + C2P 3.7 1.1 32 89.4
R FOCUS + C3 1.9 1.9 18 88.0
S FOCUS + FasterBlock 4.0 0.8 23 85.1
T FOCUS + C2P 3.7 1.1 33 90.1
U PolarFusion + C3 1.9 1.9 21 89.1
V PolarFusion + FasterBlock 4.0 0.8 26 85.5
W (Ours) PolarFusion + C2P 3.7 1.1 51 91.6

The results in Table 5 clearly show that the combination of the proposed polarization fusion module and C2P module yields the best AP (91.6%) while maintaining a high FPS (51). Replacing the C3 module with C2P reduces the computational cost and improves the inference speed without sacrificing accuracy.

We also investigated the optimal number of iterations for the self-supervised training. The IoU and AP values on a single image as a function of the iteration number are shown in Figure 6 (conceptually). We observed that both metrics converge after 10–15 iterations, so we set the number of fine-tuning iterations to 10 in the experiments to minimize training time.

4.4 Comparison with State-of-the-Art Detectors

We compared our method with Faster R-CNN, SSD300, YOLOv5n, YOLOv8n, YOLOv11n, and YOLOv5s using the complete 400-image dataset (360 for training, 40 for validation). All the baselines were trained on the \(S_0\) intensity images, while our model ingested the 5-channel polarization input. Table 6 reports the parameter count, GFLOPs, AP, and runtime.

Model Param/M GFLOPs AP (%) Run Time/ms
Faster R-CNN 41.5 207 77.5 381
SSD300 26.3 62 52.5 80
YOLOv5n 1.93 4.5 60.0 45
YOLOv8n 3.16 8.7 67.5 27
YOLOv11n 2.59 6.4 70.0 25
YOLOv5s 7.24 16.5 80.0 63
Ours 3.66 1.1 92.5 20

Our method achieves the highest AP (92.5%) and the lowest runtime (20 ms), demonstrating both superior accuracy and efficiency. The parameter count of our model is comparable to the smallest YOLOv5n, while the GFLOPs are significantly lower. The use of polarization features provides an inherent advantage in distinguishing defects from the background, especially for faint cracks or contamination that are less visible in standard intensity images.

We further compared the visual results under three dataset sizes (100, 200, and 400 images). In the 100-image case, the YOLOv5s model produced many false positives on flawless panels, while our model still correctly identified the defective regions. This indicates that the self-supervised pseudo-label strategy greatly improves robustness in small-sample scenarios. The performance gap narrows as the data size increases, but our model consistently provides higher confidence scores and more precise bounding boxes for the defect areas.

4.5 Iteration and Training Dynamics

We monitored the relationship between the number of iterations and the IoU/AP metrics during zero-shot detection. The results are summarized in Table 7.

Iterations IoU AP (%)
1 0.52 83.2
5 0.61 87.5
10 0.65 91.2
15 0.65 92.0
20 0.64 92.3

As shown in Table 7, the IoU and AP stabilize after 10 iterations, confirming that the self-supervised process converges quickly without a large labeled dataset.

5. Conclusion

This paper presented two deep learning methods to solve the resolution and data scarcity problems in polarization-based solar panel defect inspection. The first method is a degradation-aware super-resolution network that reconstructs high-resolution polarization images from low-resolution inputs. The network learns a degradation representation from the input and uses a specially designed polarization loss to maintain the integrity of \(DoLP\) and \(AoLp\) information. The second method is a lightweight object detector that consumes five-channel polarization features and uses a C2P feature extraction module for fast and accurate defect localization. A self-supervised pseudo-label generation scheme makes the detector trainable with very few or even no annotated images. Experimental results on public and self-collected datasets demonstrated that the proposed SR network produces high-quality polarization-preserving images with a runtime of only 3.7 ms for \(\times 4\) upscaling, and the detector achieves 92.5% AP on solar panel defects with a runtime of 20 ms per image. These improvements are expected to facilitate reliable, real-time UAV-based inspection of large photovoltaic farms, ultimately contributing to more efficient and safer solar panel operation.

Future work will explore the integration of infrared and polarization features, the application of arbitrary-scale super-resolution, and the deployment of the model on embedded platforms for edge computing. In addition, we will continue to build a larger public polarization solar panel defect dataset to support further research in this emerging field.

Keywords: polarization imaging; solar panel defect detection; super-resolution reconstruction; degradation-aware learning; unsupervised learning

Scroll to Top