Photovoltaic system installed capacity prediction method and system based on improved YOLO model
Patent Information
- Application Number
- CN202610787829.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-03
- Publication Date
- 2026-08-28
- Estimated Expiration
- 2046-06-03
AI Technical Summary
但现有技术多聚焦组件缺陷检测或电站粗定位,在复杂场景下像素级精准分割、目标可靠识别及容量量化估算方面存在明显瓶颈,无法满足高精度、自动化、工程化的分布式光伏装机容量评估需求
本发明通过规范精细化标注与改进YOLO模型训练,显著提升光伏组件在密集排布、遮挡、复杂屋顶等场景下的分割准确率,有效解决漏检、误检与边界模糊问题;同时,采用像素面积结合面积比例因子转换物理实际面积,再依据功率密度映射装机容量,实现从图像识别到容量计算的全流程自动化。相较于传统电气测量与人工勘查方式,本发明无需停机、无需现场逐块核查,大幅降低人力成本与作业强度,提升大范围光伏资产普查效率与数据可靠性。
Smart Images

Figure CN122336306B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of target detection technology, and in particular to a method and system for predicting the installed capacity of photovoltaic systems based on an improved YOLO model. Background Technology
[0002] The rapid popularization of distributed photovoltaic (PV) systems has created an urgent need for accurate assessment of installed capacity. Traditional assessment methods mainly rely on electrical measurement and manual surveys. Electrical measurement methods, which rely on IV characteristic curve testing, offer high accuracy, but require shutdown operations, have expensive equipment, and are time-consuming, making them unsuitable for rapid surveys of large-scale PV power plants. Manual surveys depend on on-site inventory and record verification, offering lower costs, but are labor-intensive, inefficient, and prone to human error. Furthermore, incomplete records or modifications to the power plant can easily lead to distorted capacity information.
[0003] With the development of remote sensing and deep learning, intelligent recognition based on aerial imagery provides a new direction for capacity assessment, offering advantages such as non-contact, wide-area coverage, and high timeliness. However, existing technologies mostly focus on component defect detection or coarse power plant location, and have significant bottlenecks in pixel-level accurate segmentation, reliable target identification, and capacity quantification estimation in complex scenarios, failing to meet the needs of high-precision, automated, and engineered distributed photovoltaic capacity assessment. Summary of the Invention
[0004] To address the aforementioned issues, this invention proposes a photovoltaic system installation capacity prediction method and system based on an improved YOLO model, which effectively enhances the accuracy of photovoltaic module segmentation and capacity calculation efficiency, enabling contactless, automated, and high-precision rapid prediction of distributed photovoltaic installation capacity.
[0005] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, the present invention provides a method for predicting the installed capacity of photovoltaic systems based on an improved YOLO model, comprising: The improved YOLO model was trained using pre-selected labeled samples, and after multiple iterations, a well-trained improved YOLO model was obtained. In the improved YOLO model, some Conv modules in the Backbone layer were replaced with RepConv modules, and deep semantic features were obtained through multi-level feature enhancement processing. The SPPF module was replaced with the SPPF_CA module to capture spatial distribution features. Some C3K2 modules in the Neck layer were replaced with C2f_Rep modules to enhance fine-grained feature fusion. A DAPM module was added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different dilation rates, which are used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. The image of the distributed photovoltaic system to be detected is input into the trained improved YOLO model to obtain the photovoltaic module segmentation mask; The effective pixel area of the segmentation mask is statistically analyzed and converted into the physical actual area. Based on the physical actual area, the actual total area of a single component is extracted and mapped to the corresponding installed capacity.
[0006] Secondly, the present invention provides a photovoltaic system installed capacity prediction system based on an improved YOLO model, comprising: The model training module is configured to train the improved YOLO model using pre-selected labeled samples, and obtain the trained improved YOLO model through multiple iterations. In the improved YOLO model, some Conv modules in the Backbone layer are replaced with RepConv modules, and deep semantic features are obtained through multi-level feature enhancement processing. The SPPF module is replaced with the SPPF_CA module to capture spatial distribution features. Some C3K2 modules in the Neck layer are replaced with C2f_Rep modules to enhance fine-grained feature fusion. A DAPM module is added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different dilation rates, which are used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. The segmentation module is configured to input the distributed photovoltaic image to be detected into a trained improved YOLO model to obtain a photovoltaic module segmentation mask; The capacity prediction module is configured to calculate the effective pixel area of the segmentation mask and convert it into the physical actual area, extract the actual total area of a single component based on the physical actual area, and map it to the corresponding installed capacity.
[0007] Thirdly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps in the photovoltaic system installed capacity prediction method based on the improved YOLO model described in the first aspect.
[0008] Fourthly, the present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps in the photovoltaic system installed capacity prediction method based on the improved YOLO model described in the first aspect.
[0009] Compared with the prior art, the beneficial effects of the present invention are as follows: This invention significantly improves the segmentation accuracy of photovoltaic modules in scenarios such as dense layout, shading, and complex roofs through standardized and refined annotation and improved YOLO model training, effectively solving the problems of missed detections, false detections, and blurred boundaries. Simultaneously, it uses pixel area combined with an area scaling factor to convert to the actual physical area, and then maps the installed capacity based on power density, achieving full automation from image recognition to capacity calculation. Compared to traditional electrical measurement and manual surveying methods, this invention eliminates the need for downtime and on-site block-by-block verification, greatly reducing labor costs and workload, and improving the efficiency and data reliability of large-scale photovoltaic asset surveys.
[0010] Advantages of additional aspects of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0011] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute a limitation thereof.
[0012] Figure 1 A main flowchart of a photovoltaic system installed capacity prediction method based on an improved YOLO model provided in an embodiment of the present invention; Figure 2 A flowchart illustrating a photovoltaic system installed capacity prediction method based on an improved YOLO model, provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the improved YOLO model structure provided in an embodiment of the present invention. Detailed Implementation
[0013] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0014] Example 1 like Figure 1 As shown in the figure, this embodiment discloses a method for predicting the installed capacity of photovoltaic systems based on an improved YOLO model, including the following steps: S1: The improved YOLO model is trained using pre-selected labeled samples, and after multiple iterations, a trained improved YOLO model is obtained. In the improved YOLO model, some Conv modules in the Backbone layer are replaced with RepConv modules, and deep semantic features are obtained through multi-level feature enhancement processing. The SPPF module is replaced with the SPPF_CA module to capture spatial distribution features. Some C3K2 modules in the Neck layer are replaced with C2f_Rep modules to enhance fine-grained feature fusion. A DAPM module is added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different dilation rates, which are used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. S2: Input the image of the distributed photovoltaic system to be detected into the trained improved YOLO model to obtain the photovoltaic module segmentation mask; S3: Calculate the effective pixel area of the segmentation mask and convert it into the physical actual area. Extract the actual total area of a single component based on the physical actual area and map it to the corresponding installed capacity.
[0015] Next, combined Figure 2 This embodiment provides a detailed description of a photovoltaic system installed capacity prediction method based on an improved YOLO model.
[0016] (a) Pre-defined labeling rules for photovoltaic modules By establishing a set of scientific and standardized photovoltaic module annotation rules, which take into account the core characteristics of distributed photovoltaic arrays in practical applications, such as dense arrangement, rooftop adaptation installation, partial shading, and inconsistent module specifications, and clarify key standards such as module boundary definition, shading area processing, and similar target differentiation during the annotation process, the consistency, completeness, and accuracy of the annotation results are ensured, thereby guaranteeing the accuracy of subsequent instance segmentation model training and the effectiveness of the dataset.
[0017] 1. Component Boundary Definition: Given the dense arrangement and varying specifications of distributed photovoltaic arrays, the annotations are strictly drawn along the visible physical borders. For closely connected components, precise segmentation is performed based on minute physical gaps or texture features within the borders, avoiding the merging of multiple components in the annotations. When handling edge blurring due to reflections or overexposure, reasonable extrapolation and alignment are performed by combining the array's geometric topology with the orientation of surrounding clear components to ensure the boundaries are flush with effective pixels.
[0018] 2. Handling of Occlusion Areas: Rooftop environments are often accompanied by complex obstructions and backgrounds such as trees, chimneys, or antennas. The labeling of occlusion areas needs to be combined with the specific scene. When the visibility of a component is higher than 30%, the complete physical boundary is inferred and filled in using spatial coherence. If severe occlusion makes the outline completely unrecognizable, it is discarded as invalid data.
[0019] 3. Similar Target Distinction: Against a complex roof background, skylights, solar water heaters, and highly reflective materials are easily confused with photovoltaic modules. Distinction is achieved by extracting global features of the photovoltaic array based on its regular grid-like arrangement, consistent orientation, and tilt angle, and by extracting local texture features based on the metal frame and cell grid lines. When isolated, irregularly shaped suspected bright targets exist, a conservative strategy is adopted, combining multi-source contextual information for cross-validation to eliminate false targets and improve the overall dataset purity and model robustness.
[0020] This embodiment optimizes sample data quality, eliminates invalid interference information, and enhances sample feature recognition by defining component boundaries, processing shading areas, and distinguishing similar targets. This can effectively improve the model's recognition accuracy and anti-interference ability for photovoltaic modules.
[0021] (II) Improved YOLO Model 1. Model optimization and improvement content: like Figure 3 As shown, the model architecture is as follows: (1) Backbone network reparameterized downsampling (RepConv) In the critical downsampling layers 5 and 7 of the backbone network, the standard Conv module is replaced with the RepConv module, corresponding to two strided downsampling operations. The backbone actually contains multiple strided convolutions (layers 0, 1, 3, 5, and 7). This embodiment does not replace all downsampling layers, but only performs precise upgrades on the deep downsampling stage—this is the key difference from the "whole network replacement" approach of RepVGG and ELAN, and also avoids the unnecessary overhead brought by shallow multi-branch structures.
[0022] There are three reasons for replacing only layers 5 and 7: First, these two layers are the key entry points for the backbone to move from mid-level semantics to deep semantics, corresponding to the significant channel expansion from 256 to 512 and from 512 to 1024, which are the links with the highest information density and semantic complexity. The RepConv multi-branch structure provides diverse encoding paths during the channel doubling process, ensuring the highest quality feature compression effect for each downsampling. Second, the features output by layers 5 and 7 are subsequently used for C3k2, SPPF_CA, C2PSA, and the neck FPN- The common input source of PAN and DAPM means that improvements in the quality of the source will be amplified step by step along the entire network, achieving single-point investment and benefiting the whole link; thirdly, the spatial resolution of photovoltaic modules is compressed to 50×50 and 25×25 at the P4 / P5 scale, and the actual panel area corresponding to each pixel is significantly enlarged. The features enhanced by RepConv can more accurately preserve the boundaries of adjacent closely packed panels, significantly reducing the probability of panel adhesion and missed detection caused by downsampling, and providing more reliable feature support for subsequent small target recognition and instance segmentation from the root.
[0023] During RepConv training, three parallel branches—3×3 convolutions, 1×1 convolutions, and identity mappings—are added together after passing through a BatchNorm layer, providing diverse gradient paths and feature representation capabilities. During inference, the structure is reparameterized and folded into a single equivalent 3×3 convolution, incurring zero additional computational cost. This embodiment achieves maximum benefit with minimal replacements, strengthening feature preservation at critical nodes where information is most easily lost in densely packed layouts, while fully retaining the lightweight advantages of the original backbone, balancing accuracy and deployment efficiency.
[0024] (2) Spatial pyramid pooling with coordinate attention (SPPF_CA) At the top layer of the backbone network, the standard SPPF is replaced with an SPPF_CA structure that cascades SPPF and coordinate attention. SPPF first aggregates multi-scale context under different receptive fields through three cascaded max pooling operations, and the output features are then fed into the CA module. The CA module decomposes the channel attention into one-dimensional feature encodings in the horizontal and vertical directions, performs global average pooling along the width and height respectively to obtain two directional position encodings, concatenates them and feeds them into a shared 1×1 convolution, BN layer and SiLU activation for dimensionality reduction transformation, and finally splits them into two paths and generates attention maps in the H and W directions respectively through Sigmoid, which are multiplied element-wise with the input features, thereby embedding precise spatial position information into the channel attention.
[0025] This position-sensitive weighting mechanism is particularly well-suited for photovoltaic aerial photography scenarios: solar panels appear as neat rows and columns in images, exhibiting significant periodic structures and strong directional boundaries in both the horizontal and vertical directions. CA can explicitly encode the spatial distribution in the H and W directions along the channel dimension, accurately capturing the row and column arrangement features of the components; SPPF_CA retains multi-scale context awareness capabilities without losing key spatial orientation cues, and also provides a more robust feature foundation for downstream neck fusion and multi-scale receptive field selection.
[0026] (3) Reparameterized feature fusion module (C2f_Rep) In the neck feature fusion stage, at layers 16 and 20, the C3k2 module is replaced with the C2f_Rep block. This position is a crucial node for FPN-PAN to complete bidirectional feature fusion from top to bottom and bottom to top, undertaking the task of complementing high-level semantic information with shallow detail information. Introducing C2f_Rep can significantly improve the fine-grained feature fusion capability, better adapt to the clear edges and regularly arranged details of photovoltaic modules, and provide higher-quality input for the subsequent multi-scale receptive field selection of the DAPM module.
[0027] C2f_Rep upgrades each internal Bottleneck unit to a RepConv unit based on the overall topology of the original C2f. The original C2f structure excels in multi-path concatenation and feature reuse by separating features through split operations, sequential processing through multiple Bottlenecks with skip connections, concatenation, and 1×1 convolution. Replacing the internal units with RepConv is equivalent to superimposing unit-level multi-branching on top of the original block-level multi-path, forming a nested multi-path structure. This significantly enhances the representation capacity of the entire C2f_Rep block in the fine-grained fusion task undertaken by the neck layer. This change complements the replacement of RepConv in layers 5 and 7 of the backbone: the backbone focuses on preserving information at key downsampling nodes, while the neck layer focuses on maintaining details during repeated fusion. Both work together to ensure feature quality at different locations and scales. This design is highly compatible with photovoltaic aerial photography scenarios. The solar panels are arranged in groups with sharp edges, and the gaps between the panels are prone to blurring during multiple top-down and bottom-up fusions of the FPN-PAN. The nested multi-path structure can robustly preserve subtle boundary and gap information. During the inference phase, all RepConv units within the block are uniformly folded back to standard convolutions through reparameterization.
[0028] (4) Densely Arranged Perception Module (DAPM) To address the characteristics of densely packed photovoltaic modules, a DAPM module is introduced in layers 17 and 21. This module contains three depthwise separable dilated convolutional branches with different expansion rates, corresponding to receptive fields of 3×3, 7×7, and 11×11, respectively. A spacing adaptive attention mechanism is used to extract spacing context information through global average pooling, dynamically generating the fusion weights of each branch, enabling the model to automatically select the optimal receptive field based on the module spacing.
[0029] The aerial photograph shows a dense arrangement of photovoltaic panels, but the spacing varies from area to area. DAPM uses three branches to process these panels simultaneously: small-area (3×3), medium-area (7×7), and large-area (11×11), corresponding to dense, medium, and sparse arrangements, respectively. Instead of directly measuring pixel distance, the model first compresses the feature map into channels, then uses global average pooling to reduce each channel to a single value, resulting in an overall summary that implicitly contains information about the density of the panel arrangement.
[0030] Specifically, the output features of the C2f_Rep module are used as the input feature map and fed in parallel into three depthwise separable dilated convolution branches with different dilation rates to obtain the corresponding branch feature maps. After channel compression of the input feature map, a one-dimensional global summary vector is obtained through global average pooling, which is used to characterize the sparsity of the photovoltaic panel arrangement.
[0031] Next, this summary is fed into a two-layer small fully connected network, outputting three weights between 0 and 1, corresponding to three branches. The results of the three branches are multiplied by their respective weights and then added together: when the grid is densely packed, the smaller branches have higher weights, and when it is sparsely packed, the larger branches have higher weights. The spacing is reflected in the magnitude of these three weights, and the global summary of the entire image automatically determines which branch to use. Finally, the results are added back to the original input to obtain the output.
[0032] Specifically, the overall summary vector is used as the query, and learnable embedding vectors are defined as keys for the three branches. Attention is calculated using the query and keys to obtain three scores, which are then normalized to obtain attention weights. Among them, branches with small expansion rates have higher weights when the arrangement is dense, and branches with large expansion rates have higher weights when the arrangement is sparse. The feature maps of the three branches are multiplied by their corresponding weights and then added element by element to obtain a fused feature map. This fused feature map is then added element by element to the input feature map to obtain spatial features of different spacing patterns.
[0033] Hyperparameter optimization strategies: This embodiment proposes an adaptive hyperparameter tuning strategy based on Bayesian optimization. The TPE algorithm is used to replace traditional grid search or random search. By constructing a probabilistic surrogate model between hyperparameters and model performance, the global optimum is efficiently approximated within a finite number of trials.
[0034] Simultaneously, a median pruning mechanism is introduced to automatically terminate trials with performance below the historical median in the early stages of training, significantly reducing unnecessary computational overhead. The optimization objective adopts a comprehensive Fitness metric that integrates bounding boxes and masks to ensure optimal model performance under a strict IoU threshold.
[0035] We conduct targeted searches for 16 key hyperparameters, such as learning rate and data augmentation intensity, while fixing the remaining parameters based on prior experience. This achieves a balance between search efficiency and search space coverage, enabling efficient hyperparameter optimization under computationally limited conditions.
[0036] Loss function optimization: A boundary-aware geometrical loss function is introduced. This loss consists of three shape-independent differentiable constraints: edge smoothness loss, which uses the Laplacian operator to calculate the second derivative response of the predicted mask, penalizing jagged and burr-like edge contours, but does not restrict the edge direction, remaining friendly to tilted targets at any angle; boundary sharpness loss, which uses binary information entropy to penalize pixels with probability values in the middle region, driving the mask prediction towards a sharp 0 / 1 binarization, eliminating the blurred gradient band at the boundary between the foreground and background; and foreground compactness loss, which calculates the weighted variance of the spatial coordinates of the foreground pixels with the mask probability as the weight. The larger the variance, the more dispersed the foreground, and the higher the variance, the more scattered the false detections in the roof background are suppressed by penalizing high variance.
[0037] The three constraints work together to comprehensively improve the geometric accuracy of the segmentation mask from three dimensions: edge quality, boundary sharpness, and spatial connectivity, without introducing any specific shape assumptions.
[0038] 2. Specific implementation process of this model: First, the complex scene photovoltaic aerial images that have undergone size normalization preprocessing are used as raw data input into the backbone network. After two layers of standard convolutional Conv, preliminary feature extraction and downsampling are performed to obtain shallow features.
[0039] Subsequently, cross-stage local feature fusion is performed through the second layer C3k2 module, followed by standard convolution downsampling in the third layer, and mid-level semantic features are extracted by the fourth layer C3k2 module.
[0040] Then, the reparameterized downsampling stage is entered. The RepConv module is used to replace the ordinary convolution. The feature preservation ability in the downsampling process is enhanced by three parallel branches during training: 3×3 convolution, 1×1 convolution and identity mapping. Downsampling is completed in the 5th and 7th layers, respectively.
[0041] The 9th layer of the backbone network adopts the spatial pyramid pooling module SPPF_CA that integrates coordinate attention. First, it captures multi-scale contextual information through three cascaded max pooling. Then, it decomposes the channel attention into one-dimensional feature encodings in the horizontal and vertical directions. After dimensionality reduction and splitting by the shared bottleneck layer, directional attention maps are generated respectively. The directional attention maps are multiplied element-wise with the features to achieve position-sensitive channel weighting. Then, the high-level semantic features are further enhanced by the C2PSA module in the 10th layer.
[0042] At the head of the feature pyramid network, high-level features are upsampled sequentially and concatenated with the features of the corresponding layers of the backbone network. After being fused through the C3k2 module, they are passed to the next level.
[0043] In layers 16 and 20, the fused features are first processed by the C2f_Rep module, which replaces the bottleneck block inside the C2f structure with the RepConv block, introducing structural reparameterization enhancement during the feature fusion stage. Then, the features are input to the Densely Arranged Perception (DAPM) module in layers 17 and 21. The features are reduced in dimensionality through 1×1 convolutions and then fed into three depthwise separable dilated convolution branches with different dilation rates of 1, 3, and 5, corresponding to three receptive fields of 3×3, 7×7, and 11×11, respectively, to extract spatial features of different spacing patterns in parallel. Simultaneously, the dimensionality-reduced features are processed by a global average pooling layer to extract global spacing context information and achieve further dimensionality reduction. This is then input into a two-layer fully connected network for processing, where ReLU activation and a Sigmoid function generate adaptive weights for the three branches. The weights are multiplied by the corresponding branch outputs and weighted summed to obtain the fused features. A 1×1 convolution is then used to restore the channel dimension, and the fused features are added pixel-by-pixel to the input features via residual connections to obtain the final Densely Arranged Perception output features. Finally, the feature input segmentation heads at the three scales of layer 17, layer 21, and layer 25 are used by the prototype mask generator and the mask coefficient predictor to output instance segmentation results.
[0044] (III) Model Training The dataset is segmented based on labeled and quality-verified photovoltaic module instances. The dataset is divided in a ratio of 7.5:1.5:1. Then, based on the optimized training hyperparameters, the improved YOLOv11n-seg model is iteratively trained using the training set data. During the training process, the model's loss value, average accuracy, and other key indicators are monitored in real time using the validation set, and the training strategy is dynamically adjusted.
[0045] After the model training converged, image data covering different scenes was selected from the test set. The improved YOLOv11n-seg model was then used for photovoltaic module instance segmentation inference, generating pixel-level segmentation results for each module. The segmentation output results were compared and analyzed pixel-by-pixel with the original aerial images, focusing on evaluating core dimensions such as the segmentation accuracy of module edge contours, the recognition effect of occluded areas, and the ability to distinguish similar targets. Based on the comparison, issues such as missed detections, false detections, and blurred segmentation boundaries were identified. The model's hyperparameters were further optimized and the network structure was improved to continuously enhance the model's segmentation performance.
[0046] First, multi-scale edge and pixel quantization metrics are constructed. Addressing the straight geometric characteristics of photovoltaic module edges, the traditional approach of relying solely on mask intersection-over-union (IoU) is abandoned, and boundary IoU is introduced. By setting a fixed pixel tolerance band, the overlap between the model-predicted boundary and the actual manually labeled boundary is specifically calculated, thereby accurately quantifying microscopic issues such as blurred edge contours, inconsistent shapes, or jagged edges.
[0047] Secondly, we conducted scene-based false negative and false positive detection. For areas with low thresholds, we extracted subsets based on the proportion of occlusion such as vegetation and building shadows, calculated the recall rate, and evaluated the model's ability to handle false negatives caused by missing features. For distinguishing similar targets, we combined the confusion matrix to extract false positive samples and quantified the model's shortcomings in local texture feature extraction based on the precision index.
[0048] Finally, a pixel-level error visualization and alignment mechanism is established. An overlay image of the predicted mask and the ground truth annotations is automatically generated, superimposing all missed, falsely detected, and edge alignment errors onto the original aerial image. This intuitive error map can accurately locate the model's perceptual blind spots under specific lighting angles or complex roof topologies, providing direct data and visual validation support for subsequent adjustments to the feature pyramid structure or the introduction of adaptive boundary loss functions.
[0049] In this embodiment, the model parameters are dynamically adjusted during training, which can adapt to the distribution characteristics of sample data in real time, accelerate the convergence speed of the loss function, effectively reduce the risk of model overfitting, and simultaneously improve the segmentation accuracy and generalization ability of the model in complex scenarios.
[0050] (iv) Target segmentation and capacity prediction After multiple rounds of hyperparameter tuning and network structure improvement, the improved YOLOv11n-seg model completes instance segmentation of the input aerial image of distributed photovoltaics to be detected and outputs accurate masks for each photovoltaic module. For each independent photovoltaic module instance obtained by segmentation, the model first calculates the effective pixel area within its mask region.
[0051] The area scale factor is determined based on the ground sampling distance (GSD) of the aerial imagery. The data source is the Swissimage-dop10 orthophoto imagery released by the Swiss Federal Office of Geography and Information (SGE), with a nominal spatial resolution of 10 cm / pixel, meaning each pixel corresponds to a 0.1 m × 0.1 m square area on the ground. Therefore, the area scale factor is 0.01 m. 2 / pixel. This conversion factor directly converts the number of mask pixels output by the model into the physical area, completing the quantitative conversion from pixel area to actual physical area.
[0052] Then, area-driven capacity mapping is adopted. The essence of the area-driven method is to calculate the installed capacity by accurately measuring the actual footprint of the photovoltaic panels and combining it with the standard power density coefficient. Compared with the traditional counting method, the area-driven method has significant advantages. It can adapt to photovoltaic panels of different shapes and sizes and effectively handle irregular shapes or blurred edges. Since the installed capacity is an inherent parameter of the photovoltaic system and is not affected by weather conditions and seasonal changes, this embodiment uses the estimation model of installed capacity (kWp) = photovoltaic panel area (m²) × power density (kWp / m²): ; in, A This indicates the area of the photovoltaic panel (m²). It represents solar irradiance G (watts per square meter). η This indicates the photovoltaic module conversion efficiency (%).
[0053] Based on the accurate extraction of the actual total physical area of individual modules and the entire distributed photovoltaic array, and combined with the core characteristics of the rated power density of this type of photovoltaic module, a refined and accurate prediction of the installed capacity of distributed photovoltaic power stations is ultimately achieved through scientific capacity calculation logic.
[0054] This embodiment provides a non-contact method for predicting photovoltaic installed capacity, which requires no additional hardware equipment, significantly improves resource identification efficiency, and substantially reduces grid dispatching costs. Furthermore, while ensuring capacity prediction accuracy, this invention achieves a rapid, closed-loop process from "image recognition" to "area statistics" and then to "capacity calculation," filling a gap in this field.
[0055] Furthermore, to comprehensively verify the performance of the improved YOLOv11n-seg model in the task of predicting distributed photovoltaic installed capacity, the predicted capacity results output by the model are compared and analyzed with the actual installed capacity data obtained from actual annotation and measurement. Core evaluation indicators such as average accuracy and capacity prediction accuracy are selected to quantify the prediction accuracy. At the same time, the generalization ability of the model is evaluated by combining the prediction performance of different application scenarios. Finally, the accuracy, reliability and practical value of the model in engineering practice are verified, providing technical support for intelligent assessment of distributed photovoltaic capacity.
[0056] Example 2 This embodiment provides a photovoltaic system installed capacity prediction system based on an improved YOLO model, including: The model training module is configured to train the improved YOLO model using pre-selected labeled samples, and obtain the trained improved YOLO model through multiple iterations. In the improved YOLO model, some Conv modules in the Backbone layer are replaced with RepConv modules, and deep semantic features are obtained through multi-level feature enhancement processing. The SPPF module is replaced with the SPPF_CA module to capture spatial distribution features. Some C3K2 modules in the Neck layer are replaced with C2f_Rep modules to enhance fine-grained feature fusion. A DAPM module is added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different dilation rates, which are used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. The segmentation module is configured to input the distributed photovoltaic image to be detected into a trained improved YOLO model to obtain a photovoltaic module segmentation mask; The capacity prediction module is configured to calculate the effective pixel area of the segmentation mask and convert it into the physical actual area, extract the actual total area of a single component based on the physical actual area, and map it to the corresponding installed capacity.
[0057] Example 3 This embodiment provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps in the photovoltaic system installed capacity prediction method based on the improved YOLO model described in Embodiment 1 above.
[0058] Example 4 This embodiment provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps in the photovoltaic system installed capacity prediction method based on the improved YOLO model as described in Embodiment 1 above.
[0059] The steps or modules involved in Embodiments 2 to 4 above correspond to those in Embodiment 1. For specific implementation details, please refer to the relevant description section of Embodiment 1. The term "computer-readable storage medium" should be understood as a single medium or multiple media including one or more instruction sets; it should also be understood as including any medium capable of storing, encoding, or carrying an instruction set for execution by a processor and enabling the processor to perform any of the methods in this invention.
[0060] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for predicting the installed capacity of distributed photovoltaic systems based on the YOLO model, characterized in that, include: An improved YOLO model was trained using pre-selected labeled samples, and after multiple iterations, a well-trained improved YOLO model was obtained. In this improved YOLO model, some Conv modules in the Backbone layer were replaced with RepConv modules. These RepConv modules were placed in the 5th and 7th layers of the key downsampling layers in the backbone network, and deep semantic features were obtained through multi-level feature enhancement processing. The SPPF module was replaced with an SPPF_CA module to capture spatially distributed features. The SPPF_CA module includes a three-stage cascaded max pooling and channel attention mechanism. The three-stage cascaded max pooling is used to capture multi-scale contextual information, and the input channel attention is decomposed into one-dimensional feature encodings in the horizontal and vertical directions. After dimensionality reduction and splitting by the shared bottleneck layer, directional attention maps are generated respectively. Element-wise multiplication with the features achieves position-sensitive channel weighting, resulting in globally aggregated features. Some C3K2 modules in the Neck layer were replaced with C2f_Rep modules to enhance fine-grained feature fusion. The C2f_Rep module uses RepConv as the... The C2f module, designed for bottleneck structures, is used for structural reparameterization enhancement. A DAPM module is added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different expansion rates, used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. Specifically, the output features of the C2f_Rep module are used as input feature maps, fed in parallel into the three depthwise separable dilated convolutional branches with different expansion rates to obtain corresponding branch feature maps. After channel compression of the input feature maps, global average pooling is used to obtain a one-dimensional overall summary vector, used to characterize the sparsity of the photovoltaic panel arrangement. The overall summary vector is used as a query, and learnable embedding vectors are defined as keys for the three branches. Attention is calculated using the query and keys to obtain three scores, which are then normalized to obtain attention weights. The branches with smaller expansion rates have higher weights when the arrangement is dense, and the branches with larger expansion rates have higher weights when the arrangement is sparse. The three branch feature maps are multiplied by their corresponding weights and then added element-wise to obtain a fused feature map, which is then added element-wise to the input feature map to obtain spatial features of different spacing patterns. The image of the distributed photovoltaic system to be detected is input into the trained improved YOLO model to obtain the photovoltaic module segmentation mask; The effective pixel area of the segmentation mask is statistically analyzed and converted into the physical actual area. Based on the physical actual area, the actual total area of a single component is extracted and mapped to the corresponding installed capacity. Specifically, the effective pixel area of the segmentation mask is converted into the physical actual area based on the area scaling factor, and the installed capacity is calculated using the standard power density coefficient. The formula is as follows: Where A represents the area of the photovoltaic panel. G represents solar irradiance, and η represents the photovoltaic module conversion efficiency.
2. The method for predicting the installed capacity of a distributed photovoltaic system based on the YOLO model as described in claim 1, characterized in that, The screening process for the pre-screened labeled samples is as follows: based on the preset photovoltaic module labeling rules, the distributed photovoltaic image dataset is screened and labeled to obtain labeled samples; the labeling rules include component boundary definition, occlusion area processing and similar target differentiation.
3. The method for predicting the installed capacity of a distributed photovoltaic system based on the YOLO model as described in claim 1, characterized in that, The RepConv module includes three parallel branches during model training: 3×3 convolution, 1×1 convolution, and identity mapping, which are used to enhance feature preservation during downsampling. During deployment, these branches are fused into a single convolution.
4. A distributed photovoltaic system installed capacity prediction system based on the YOLO model, characterized in that, include: The model training module is configured to train the improved YOLO model using pre-selected labeled samples, obtaining a trained improved YOLO model through multiple iterations. In the improved YOLO model, some Conv modules in the Backbone layer are replaced with RepConv modules. The RepConv modules are located in the 5th and 7th layers of the key downsampling layers in the backbone network, and deep semantic features are obtained through multi-level feature enhancement processing. The SPPF module is replaced with an SPPF_CA module to capture spatial distribution features. The SPPF_CA module includes a three-stage cascaded max pooling and channel attention mechanism. The three-stage cascaded max pooling is used to capture multi-scale contextual information. The input channel attention is decomposed into one-dimensional feature encodings in the horizontal and vertical directions, which are then dimensionality-reduced and split by a shared bottleneck layer to generate directional attention maps. Element-wise multiplication with the features achieves position-sensitive channel weighting, resulting in globally aggregated features. Some C3K2 modules in the Neck layer are replaced with C2f_Rep modules to enhance fine-grained feature fusion. The C2f_Rep module uses Re... pConv, as the C2f module of the bottleneck structure, is used for structural reparameterization enhancement. A DAPM module is added after the C2f_Rep module. The DAPM module includes three depthwise separable dilated convolutional branches with different expansion rates, used to extract spatial features of different spacing patterns based on the output features of the C2f_Rep module. Specifically, it includes: using the output features of the C2f_Rep module as the input feature map, feeding them in parallel into the three depthwise separable dilated convolutional branches with different expansion rates to obtain corresponding branch feature maps; compressing the input feature maps by channels, and then performing global average pooling to obtain a one-dimensional overall summary vector, used to characterize the sparsity of the photovoltaic panel arrangement; using the overall summary vector as a query, defining learnable embedding vectors as keys for each of the three branches; calculating attention using the query and keys to obtain three scores, which are then normalized to obtain attention weights; where branches with smaller expansion rates have higher weights when the arrangement is dense, and branches with larger expansion rates have higher weights when the arrangement is sparse; multiplying the three branch feature maps by their corresponding weights and then adding them element-wise to obtain a fused feature map, which is then added element-wise to the input feature map to obtain spatial features of different spacing patterns. The segmentation module is configured to input the distributed photovoltaic image to be detected into a trained improved YOLO model to obtain a photovoltaic module segmentation mask; The capacity prediction module is configured to: statistically analyze the effective pixel area of the segmentation mask and convert it into the physical actual area; extract the actual total area of a single component based on the physical actual area and map it to the corresponding installed capacity; specifically, convert the effective pixel area of the segmentation mask into the physical actual area based on the area scaling factor, and calculate the installed capacity using the standard power density coefficient, as shown in the formula: Where A represents the area of the photovoltaic panel. G represents solar irradiance, and η represents the photovoltaic module conversion efficiency.
5. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the steps in the method for predicting the installed capacity of a distributed photovoltaic system based on the YOLO model as described in any one of claims 1-3.
6. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps in the distributed photovoltaic system installed capacity prediction method based on the YOLO model as described in any one of claims 1-3.
Citation Information
Patent Citations
Method for counting number of people in construction elevator based on lightweight target detection algorithm
CN118823675A
Remote sensing image target detection method based on MCD-YOLO network
CN118918487A
Distributed photovoltaic installed capacity calculation method, device, equipment and medium
CN119762985A