A photovoltaic panel fault diagnosis method and system based on image processing
Through thermal image processing and temperature rise anomaly index calculation, the accuracy problem of photovoltaic panel fault diagnosis in high-altitude areas was solved, and accurate fault area identification and misjudgment reduction were achieved.
Patent Information
- Application Number
- CN202510740763.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-05
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2045-06-05
AI Technical Summary
Existing photovoltaic panel fault diagnosis methods cannot accurately reflect temperature distribution, resulting in misjudgments or missed diagnosis due to large temperature differences between day and night and changes in light intensity in high-altitude areas, affecting diagnostic accuracy.
By acquiring thermal images of photovoltaic panels in real time, distinguishing between illuminated and shadowed areas, calculating the temperature rise anomaly index, using preset trigger monitoring conditions to obtain the monitoring start time, identifying the degree of anomaly in the non-zero connectivity domain, and combining the threshold to determine the fault area.
It improves the accuracy and versatility of photovoltaic panel fault diagnosis, reduces the false alarm rate, can accurately locate the fault area, and adapt to diagnostic needs under different lighting conditions.
Smart Images

Figure CN120259790B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing, and more particularly to a photovoltaic panel fault diagnosis method and system based on image processing. Background Art
[0002] Photovoltaic panels, also known as solar photovoltaic panels, are semiconductor devices that convert sunlight directly into electricity. Their operating principle is based on the photoelectric effect. When sunlight strikes the surface of a photovoltaic panel, the photon energy is absorbed by the semiconductor material, ultimately creating a potential difference between the two ends of the cell. When an external circuit is connected, a current is generated, thus converting sunlight into electricity.
[0003] When using photovoltaic panels at high altitudes, the thin air allows for strong solar radiation during the day and rapid heat dissipation at night, resulting in large temperature differences between day and night. Furthermore, high altitudes also experience high solar radiation intensity and long hours of sunlight, which means the photovoltaic panels receive a large amount of solar energy. Due to this large temperature difference and strong sunlight, the temperature difference between shaded and unshaded areas of the photovoltaic panel can be significant. For example, shaded areas may be cooler due to lack of direct sunlight, while illuminated areas may be warmer.
[0004] However, existing methods for diagnosing photovoltaic panel faults present several challenges. For one thing, traditional fault diagnosis methods primarily rely on monitoring electrical parameters such as the panel's output current and voltage. These methods cannot directly reflect the panel's temperature distribution, and temperature anomalies are often an early sign of a panel failure. Furthermore, in high-altitude areas, where the temperature difference between shaded and illuminated areas of a panel is significant due to large day-night temperature swings and strong sunlight, existing methods struggle to accurately distinguish between normal temperature differences and temperature anomalies caused by faults, leading to misjudgments or missed detections, thus impacting the accuracy of diagnosing photovoltaic panel faults. Summary of the Invention
[0005] In order to solve the above-mentioned technical problem of how to accurately diagnose the failure of a photovoltaic panel, the present invention provides solutions in the following aspects.
[0006] In a first aspect, a photovoltaic panel fault diagnosis method based on image processing comprises:
[0007] Acquire thermal images of photovoltaic panels in real time and perform binary classification on the thermal images to obtain illuminated and shadowed areas;
[0008] For the illuminated area and the shadowed area, the monitoring start time of the temperature rise in the illuminated area and the monitoring start time of the temperature rise in the shadowed area after the obstruction is removed are obtained based on the preset trigger monitoring conditions;
[0009] Starting from the monitoring start time, the temperature rise anomaly index of each location point is calculated, and each location point in the thermal map is traversed to obtain the temperature rise anomaly matrix;
[0010] Find the non-zero connected domains in the temperature rise anomaly matrix and calculate the abnormality degree of each non-zero connected domain. When the abnormality degree is less than the preset threshold, the corresponding non-zero connected domain is determined to be an abnormal temperature rise area to complete the fault diagnosis of the photovoltaic panel.
[0011] The present invention first distinguishes between illuminated and shadowed areas and sets the monitoring start time to eliminate instantaneous interference caused by obstructions (such as fallen leaves and accumulated dust). Temperature rise monitoring is only started after the obstruction is removed, ensuring that subsequent analysis focuses on the performance issues of the photovoltaic panel itself. The temperature rise anomaly index of each pixel point is then calculated and a matrix is generated, realizing the quantitative conversion from the global thermal map to the local anomaly points. The discrete anomaly points are then aggregated into regional-level features through connected domain analysis. Combined with the degree of anomaly and threshold comparison, the real fault area is focused on.
[0012] Preferably, dividing the thermal image into an illuminated area and a shadowed area comprises:
[0013] The pixel values of all pixels in the thermal image are extracted, and these pixel values are subjected to binary classification processing to divide the thermal image into illuminated area and shadow area.
[0014] Preferably, obtaining the monitoring start time of the temperature rise in the illuminated area and the monitoring start time of the temperature rise in the shadowed area after the shielding is removed based on the preset trigger monitoring conditions includes:
[0015] For the position point of the shadow area collected in real time, the ratio of the grayscale value of the position point to the maximum grayscale value of the shadow area is calculated as the first parameter, and then the ratio of the mean grayscale value of the shadow area to the maximum grayscale value of the shadow area is calculated as the second parameter. When the difference between the first parameter and the second parameter is greater than the preset threshold, the corresponding sampling time is the monitoring start time;
[0016] For the position points of the illumination area collected in real time, operations are performed on the shadow area to obtain the corresponding monitoring start time.
[0017] By calculating the grayscale value ratio (the first parameter and the second parameter) and determining whether the difference is greater than a threshold, the starting time of the temperature rise in the illuminated area and the shadowed area after the obstruction is removed can be accurately determined, thus avoiding temperature data deviation caused by inaccurate monitoring start time.
[0018] Preferably, the calculation process of the temperature rise anomaly index includes:
[0019] Calculate the time difference of any position point from the monitoring start time to the current time, and calculate the ratio of the grayscale value of the position point at the current time to the product of the grayscale value at the monitoring start time and the time difference as the temperature rise anomaly index of the position point at the current time; traverse each position point in the thermal map to obtain the temperature rise anomaly index corresponding to each position point.
[0020] In a thermal map, temperature variations may differ at different locations. By calculating the temperature anomaly index for each location, areas with abnormal temperature rise can be identified. The calculation takes into account the time difference between the start of monitoring and the current moment, allowing the temperature anomaly index to reflect temperature changes over time. Over time, the temperature anomaly index is dynamically updated based on the current temperature changes. This dynamic monitoring method tracks temperature changes in real time and promptly detects early signs of temperature anomalies. For example, if the temperature anomaly index at a location increases rapidly over a short period of time, this may indicate a sudden temperature anomaly at that location, requiring immediate attention and action.
[0021] Preferably, the process of obtaining the non-zero connected domain in the temperature rise anomaly matrix includes:
[0022] The adjacent non-zero temperature rise anomaly indices in the temperature rise anomaly matrix are combined into a non-zero connected domain.
[0023] In the temperature anomaly matrix, a non-zero temperature anomaly index indicates that the temperature change at that location exceeds the normal range, indicating a possible temperature anomaly. Adjacent non-zero temperature anomaly indices form a non-zero connected domain, which means that spatially adjacent locations with temperature anomalies are grouped into the same region. This allows the identification of the regional scope of temperature anomalies, rather than just individual locations.
[0024] Preferably, the calculating of the abnormality degree of each non-zero connected domain includes:
[0025] The maximum value point of the non-zero connected domain is taken as the center point. Starting from the center point, all adjacent points are traversed along the direction in each set direction to calculate the decrease amplitude of the temperature rise anomaly index in each direction.
[0026] The minimum value of the decrease in all directions is regarded as the abnormality degree of the non-zero connected domain.
[0027] The minimum value of the decrease in all directions is selected as the anomaly degree of the non-zero connected domain. This minimum value reflects the slowest decrease in the temperature anomaly index in all directions starting from the center point, and usually represents the direction where the temperature anomaly is most stubborn or difficult to dissipate.
[0028] Preferably, the decrease rate satisfies the relationship:
[0029] ; is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next location point, is the number of steps extending outward from the center point.
[0030] Preferably, the decrease rate satisfies the relationship:
[0031] Where, is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next location point, is the number of steps extending outward from the center point.
[0032] By adopting the above technical solution,
[0033] Preferably, the calculation process of the temperature rise anomaly index includes:
[0034] Calculate the total time of any position point from the monitoring start time to the current time, and calculate the difference between the grayscale value of the position point at the current time and the grayscale value at the monitoring start time;
[0035] The ratio of the calculated gray value difference to the total time is used as the temperature rise trend of the location at the current moment; the ratio of the temperature rise trend to the average of the normal temperature rise trend is used as the temperature rise anomaly index;
[0036] Each location point in the thermal map is traversed to obtain the temperature rise anomaly index corresponding to each location point.
[0037] In a second aspect, a photovoltaic panel fault diagnosis system based on image processing includes: a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, any one of the photovoltaic panel fault diagnosis methods based on image processing is implemented.
[0038] The beneficial effects of the present invention are:
[0039] By dividing the thermal image into illuminated and shadowed areas and calculating the temperature rise anomaly index for each area, the specific area of the photovoltaic panel where the fault occurred can be accurately located, avoiding the errors caused by large-scale inspection of the entire photovoltaic panel and improving the accuracy of fault detection.
[0040] Regardless of whether the photovoltaic panel is in the illuminated area or the shadowed area, this method can obtain the corresponding monitoring start time based on the preset trigger monitoring conditions and calculate the temperature rise anomaly index, thereby adapting to the fault diagnosis needs under different lighting conditions and improving the versatility and adaptability of the method; by calculating the temperature rise anomaly index and combining the abnormality degree of the non-zero connected domain to determine the fault area, when the abnormality degree is greater than or equal to the preset threshold, the corresponding non-zero connected domain is determined to be an abnormal temperature rise area, thereby effectively reducing the false alarm rate and avoiding misjudgment caused by normal temperature rise changes. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 This is a method flow chart of steps S1 to S4 in a photovoltaic panel fault diagnosis method based on image processing in an embodiment of the present invention. DETAILED DESCRIPTION
[0042] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, but not all of the embodiments.
[0043] Reference Figure 1 A photovoltaic panel fault diagnosis method based on image processing includes steps S1 to S4, which are specifically as follows:
[0044] S1: Acquire thermal images of photovoltaic panels in real time and divide the thermal images into illuminated areas and shadow areas.
[0045] In one embodiment, an infrared thermal imager or other device capable of capturing temperature distribution is used to collect real-time thermal images of the photovoltaic panel. These images reflect the temperature distribution of different areas on the surface of the photovoltaic panel.
[0046] The thermal images used in photovoltaic panel fault diagnosis are usually grayscale images, where the grayscale value of each pixel represents the temperature at that location.
[0047] The pixel values of all pixels in the thermal image are further extracted and then classified into two categories. A commonly used binary classification method is the Otsu threshold method, which automatically determines a threshold value and divides the pixel values into two categories: one representing higher temperatures (i.e., illuminated areas) and the other representing lower temperatures (i.e., shadowed areas).
[0048] Through the above two classifications, the thermal image is divided into the illuminated area and the shadow area.
[0049] S2: For the illuminated area and the shadowed area, the monitoring start time of the temperature rise in the illuminated area and the monitoring start time of the temperature rise in the shadowed area after the shielding is removed are obtained based on preset trigger monitoring conditions.
[0050] When a photovoltaic panel is obstructed, the temperature distribution in the obstructed and illuminated areas changes. Once the obstruction is removed, the illuminated area begins to heat up, and the shadowed area may also experience some temperature rise due to changes in ambient temperature. However, only data acquired after the temperature rise begins can truly reflect the temperature rise of the photovoltaic panel after the obstruction is removed. Setting the monitoring start time too early or too late can result in inaccurate temperature rise data, affecting fault diagnosis results.
[0051] Therefore, by setting the preset trigger monitoring conditions, the starting moment of the temperature rise in the illuminated area and the shadow area after the obstruction is removed can be accurately captured, that is, the monitoring start moment.
[0052] In one embodiment, for the position point of the shadow area collected in real time, the ratio of the grayscale value of the position point to the maximum grayscale value of the shadow area is calculated as the first parameter, and then the ratio of the mean grayscale value of the shadow area to the maximum grayscale value of the shadow area is calculated as the second parameter. When the difference between the first parameter and the second parameter is greater than a preset threshold (initially set to 0.1 in the embodiment of the present invention, and can be appropriately adjusted according to actual conditions), the corresponding sampling moment is the monitoring start moment.
[0053] Similarly, for a position point in the illuminated area, when the ratio of the grayscale value of the position point to the grayscale value of the illuminated area minus the ratio of the minimum to maximum grayscale values of the illuminated area is greater than 0.1, the corresponding sampling time is the monitoring start time.
[0054] It should be noted that the grayscale values in the thermal map reflect the temperature at each point on the photovoltaic panel. The higher the grayscale value, the higher the temperature; the lower the grayscale value, the lower the temperature.
[0055] S3: Starting from the monitoring start time, calculate the temperature rise anomaly index of each location point, traverse each location point in the thermal map, and obtain the temperature rise anomaly matrix.
[0056] The monitoring start time finally obtained in the above step S2 is to find a reasonable starting point. Starting the analysis from this starting point can more accurately identify and quantify the abnormal temperature rise of the photovoltaic panel.
[0057] In one embodiment, the time difference of any position point from the monitoring start time to the current time is calculated, and the ratio of the grayscale value of the position point at the current time to the product of the grayscale value at the monitoring start time and the time difference is calculated to obtain a dimensionless relative value, which is the temperature rise anomaly index of the position point at the current time.
[0058] If the temperature rise anomaly index of a certain location point is significantly higher than that of other locations point, it may indicate that there is a fault at that location point.
[0059] Next, we traverse each location in the thermal map and calculate its temperature rise anomaly index. The temperature rise anomaly index for each location is recorded to form a matrix. Locations without a monitoring start time have a value of 0. The resulting matrix is the temperature rise anomaly matrix.
[0060] Through the above operations, the abnormal temperature rise of the photovoltaic panel can be more accurately identified and quantified, providing a solid foundation for subsequent fault diagnosis.
[0061] In another embodiment, considering the influence of different environmental conditions, a temperature rise anomaly index of the current location is calculated based on the temperature rise trend, that is, the following relationship is satisfied:
[0062]
[0063]
[0064] Where, For the current moment The temperature rise anomaly index of the location point, For the current moment Temperature rise trend of the location point, For the current moment Gray value of the position point, For the current moment Gray value of the position point, is the total time from the start of monitoring to the current moment, The temperature rise trend can be recorded by collecting a set of normal photovoltaic panel temperature rise data to monitor the temperature rise and record the temperature rise trend at each location.
[0065] S4: Find the non-zero connected domains in the temperature rise anomaly matrix and calculate the abnormality degree of each non-zero connected domain. When the abnormality degree is less than a preset threshold, the corresponding non-zero connected domain is determined to be an abnormal temperature rise area to complete the fault diagnosis of the photovoltaic panel.
[0066] It is important to consider that excessive cloud cover or unstable lighting conditions may result in inaccurate temperature data, i.e., inaccurate grayscale values at thermal image locations, leading to misjudgment of the monitoring start time. This can cause error points in the temperature rise anomaly matrix.
[0067] In one embodiment, in order to distinguish error points from real abnormal points in the temperature difference abnormality matrix, the error points and real abnormal points may be distinguished by analyzing the gradient change of the temperature rise abnormality index.
[0068] First, take any non-zero connected domain (i.e., a region consisting of adjacent non-zero temperature rise anomaly indices) in the temperature rise anomaly matrix as an example. If the non-zero connected domain is composed of error points, then there is no gradient decrease in the temperature rise anomaly index from the center of the non-zero connected domain to the surrounding points, meaning that the surrounding points will not be affected by the heat and will follow the temperature rise. Conversely, if the non-zero connected domain is an outlier point, then there is no gradient increase in the temperature rise anomaly index from the center of the non-zero connected domain to the surrounding points, and the surrounding points will be affected by the heat and will follow the temperature rise of the point.
[0069] Furthermore, in order to ensure that there is a gradient descent in at least one direction, eight directions with an angle of 45 degrees are set here, namely 0 degrees, 45 degrees, 90 degrees, 135 degrees, 180 degrees, 225 degrees, 270 degrees, and 315 degrees.
[0070] Next, taking any non-zero connected domain in the temperature rise anomaly matrix as an example, the maximum value point of the non-zero connected domain is taken as the center point. Starting from the center point in each direction, all adjacent points are traversed along this direction, and the ratio of the temperature rise anomaly index of each pair of adjacent points is calculated. Then, the average of these ratios is calculated to obtain the decrease in the temperature rise anomaly index in this direction.
[0071] Taking any direction as an example, the above-mentioned decrease rate satisfies the following relationship:
[0072]
[0073] Where, is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next position point (i.e. the next point along the center point of the 0 degree direction), is the number of steps extending outward from the center point.
[0074] In another embodiment, another calculation method is provided:
[0075]
[0076] Where, is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next position point (i.e. the next point along the center point of the 0 degree direction), is the number of steps extending outward from the center point.
[0077] The above total rate of change Amortized to each step, it can reflect the average effect of the overall attenuation trend.
[0078] According to the above operation, the decrease amplitude of the temperature rise anomaly index of the central point in all directions can be calculated, and then the minimum decrease amplitude is retained as the anomaly degree of the non-zero connected domain.
[0079] Then, the abnormality degree of all non-zero connected domains is obtained, and the calculated abnormality degree is compared with a preset threshold (set to 1 in the embodiment of the present invention). If the abnormality degree is less than the preset threshold, it means that the temperature rise of the non-zero connected domain is within the normal range, and it can be determined as a normal area; if the abnormality degree is greater than or equal to the preset threshold, it means that the temperature rise of the non-zero connected domain is abnormal, and it is further determined to be an abnormal temperature rise area.
[0080] The system includes a processor and a memory, wherein the memory stores computer program instructions. When the computer program instructions are executed by the processor, the photovoltaic panel fault diagnosis method based on image processing according to the first aspect of the present invention is implemented.
[0081] The system also includes other components well known to those skilled in the art, such as a communication bus and a communication interface. The configuration and functions of these components are known in the art and therefore will not be described in detail here.
[0082] It should be noted that those skilled in the art may make various modifications and improvements without departing from the scope of the present invention, and these modifications and improvements fall within the scope of protection of the present invention. Therefore, the scope of protection of the patent for this invention shall be based on the appended claims.
Claims
1. A photovoltaic panel fault diagnosis method based on image processing, characterized in that: include: Acquire thermal images of photovoltaic panels in real time and divide the thermal images into illuminated and shadowed areas; For the illuminated area and the shadowed area, the monitoring start time of the temperature rise in the illuminated area and the monitoring start time of the temperature rise in the shadowed area after the shielding is removed are obtained based on the preset trigger monitoring conditions, including: For the position point of the shadow area collected in real time, the ratio of the grayscale value of the position point to the maximum grayscale value of the shadow area is calculated as the first parameter, and then the ratio of the mean grayscale value of the shadow area to the maximum grayscale value of the shadow area is calculated as the second parameter. When the difference between the first parameter and the second parameter is greater than the preset threshold, the corresponding sampling time is the monitoring start time; For the position points of the illumination area collected in real time, operations are performed on the shadow area to obtain the corresponding monitoring start time; Starting from the monitoring start time, the temperature rise anomaly index of each location point is calculated including: Calculate the time difference between the monitoring start time and the current time of any position point, and calculate the ratio of the grayscale value of the position point at the current time to the product of the grayscale value at the monitoring start time and the time difference, as the temperature rise anomaly index of the position point at the current time; traverse each position point in the thermal map to obtain the temperature rise anomaly index corresponding to each position point. The value of the position point without monitoring start time is 0, and the temperature rise anomaly matrix is obtained; The non-zero connected domains in the temperature rise anomaly matrix are found, and the degree of anomaly of each non-zero connected domain is calculated. When the degree of anomaly is greater than or equal to a preset threshold, the corresponding non-zero connected domain is determined to be an abnormal temperature rise area to complete the fault diagnosis of the photovoltaic panel.
2. The photovoltaic panel fault diagnosis method based on image processing according to claim 1, characterized in that: The dividing of the thermal image into the illuminated area and the shadowed area comprises: The pixel values of all pixels in the thermal image are extracted, and these pixel values are subjected to binary classification processing to divide the thermal image into illuminated area and shadow area.
3. The photovoltaic panel fault diagnosis method based on image processing according to claim 2, characterized in that: The process of obtaining the non-zero connected domain in the temperature rise anomaly matrix includes: The adjacent non-zero temperature rise anomaly indices in the temperature rise anomaly matrix are combined into a non-zero connected domain.
4. The photovoltaic panel fault diagnosis method based on image processing according to claim 3, characterized in that: Calculating the abnormality degree of each non-zero connected domain includes: The maximum value point of the non-zero connected domain is taken as the center point. Starting from the center point, all adjacent points are traversed along the direction in each set direction to calculate the decrease amplitude of the temperature rise anomaly index in each direction. The minimum value of the decrease in all directions is regarded as the abnormality degree of the non-zero connected domain.
5. The photovoltaic panel fault diagnosis method based on image processing according to claim 4, characterized in that: The decline rate satisfies the relationship: ; is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next location point, is the number of steps extending outward from the center point.
6. The photovoltaic panel fault diagnosis method based on image processing according to claim 5, characterized in that: The decline rate satisfies the relationship: Where, is the decrease of the temperature rise anomaly index at the center point in the 0 degree direction, For the current point The temperature rise anomaly index, For the current point The temperature rise anomaly index of the next location point, is the number of steps extending outward from the center point.
7. The photovoltaic panel fault diagnosis method based on image processing according to claim 1, characterized in that: The calculation process of the temperature rise anomaly index includes: Calculate the total time of any position point from the monitoring start time to the current time, and calculate the difference between the grayscale value of the position point at the current time and the grayscale value at the monitoring start time; The ratio of the calculated gray value difference to the total time is used as the temperature rise trend of the position point at the current moment; the ratio of the temperature rise trend to the average of the normal temperature rise trend is used as the temperature rise anomaly index; Each location point in the thermal map is traversed to obtain the temperature rise anomaly index corresponding to each location point.
8. A photovoltaic panel fault diagnosis system based on image processing, characterized in that: include: A processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the photovoltaic panel fault diagnosis method based on image processing according to any one of claims 1 to 7 is implemented.