Disclosure of Invention
The invention aims to provide a method and a system for diagnosing faults of a solar cell panel, which aim to solve the problems of large calculated amount and large deviation of the conventional method for diagnosing faults of the solar cell panel.
The invention provides a fault diagnosis method for a solar cell panel, which comprises the following steps: acquiring fault IV data from a collector regularly, processing the fault IV data into a preset data structure, and storing the fault IV data into a first data set after marking metadata; collecting the fault IV data of each solar cell panel, and analyzing and obtaining the characteristics of each fault IV data; analyzing data in the first data set to divide the data in the first data set into normal data, abnormal data and fault data, storing all the abnormal data into a second data set, and storing all the normal data and all the fault data into a third data set; labeling data of the third data set by the characteristics of the fault IV data; constructing a neural network model, and training an abnormal data filtering model by using data in the second data set and the third data set; constructing a time sequence cyclic neural network model, and training a fault diagnosis model by using data in the third data set; and calling the abnormal data filtering model and the fault diagnosis model by using a computer programming language to obtain a diagnosis result.
The solar panel fault diagnosis method can diagnose the fault of the solar panel for a user remotely, massively and regularly, thereby being convenient for providing professional repair suggestions, simultaneously, the data is fully utilized, the code amount can be reduced by using data programming, convenience is provided for the function maintenance and iteration in the future, the probability among different faults can be obtained, the possibility of expanding other functions in the future is provided, the model can be deployed on a server, a browser or a hardware RAM after being trained, the transplantation is convenient, meanwhile, the fault threshold value can be accurately controlled, and the fault accuracy can be continuously improved by adjusting parameters during the training; by deeply mining the relation between fault IV data and faults and using the features in the RNN neural network adaptive learning data, the robustness of the model to the abnormity in the data is improved.
Further, the step of acquiring the fault IV data from the collector at regular time and processing the fault IV data into a preset data structure includes:
setting the sampling number of the collector to be at least four sampling points, wherein the attribute of each sampling point comprises voltage and current;
and randomly extracting 100 collectors for collecting data at regular time, wherein each collector is provided with 8 ports so as to obtain data and establish the first data set.
Further, the step of collecting the fault IV data of each solar panel and analyzing and obtaining the characteristics of each fault IV data includes:
acquiring a maximum current value and a maximum voltage value of the fault IV data to obtain the first data set;
normalizing each piece of fault IV data;
calculating the power of each sampling point;
establishing an IV simulation function;
substituting the voltage in the fault IV data into the IV simulation function to obtain theoretical current, and according to the theoretical current, obtaining derivatives of real current, theoretical current and loss current to the voltage, wherein the real current is the current corresponding to the fault IV data, and the loss current is the difference value of the theoretical current and the real current;
acquiring the real current, the actual voltage, the actual power and the theoretical current of each sampling point attribute according to the steps, and storing the real current, the actual voltage, the actual power and the theoretical current into the first data set;
and clustering the attributes of each piece of metadata in the first data set and the second data set respectively through machine learning K-Means, performing data filtering on the obtained result, and storing the filtered data into a third data set.
Further, the method further comprises:
and carrying out variance operation on the loss current so as to describe each fault IV data.
Further, the computer programming language comprises any one of Python, Java, and JavaScript.
Further, the IV simulation function is:
wherein, PmaxTo a maximum power value, VmaxIs the maximum voltage value, ImaxIs the maximum current value, f is the fill factor, C1Is a first coefficient, C2Is the second coefficient, ViIs the ith voltage value (i is 1 to the number of sampling points).
Further, the method for normalizing each piece of fault IV data includes:
dividing a present voltage value in the fault IV data by a maximum voltage value, and dividing a present current value in the fault IV data by a maximum current value.
Further, the type of the fault IV data includes at least one of occlusion, glass fragmentation, subfissure, hot spot.
The invention also provides a solar cell panel fault diagnosis system, which is suitable for the solar cell panel fault diagnosis method and comprises the following steps:
the collector is used for collecting the fault IV data of the solar cell panel;
the data acquisition module is used for acquiring the fault IV data from the collector at regular time and processing the fault IV data into a preset data structure;
a marking module for marking metadata in the fault IV data;
the data collection module is used for collecting the fault IV data of each solar cell panel;
the data analysis module is used for analyzing and obtaining the characteristics of each fault IV data;
the classification module is used for classifying the data in the first data set into normal data, abnormal data and fault data;
the first storage module is used for storing data of the first data set;
the second storage module is used for storing the data of the second data set;
the third storage module is used for storing the data of the third data set;
the marking module is used for marking the data of the third data set through the characteristics of the fault IV data;
the first model building module is used for building a neural network model;
the second model building module is used for building a time sequence cyclic neural network model;
and the computer programming language is used for calling the abnormal data filtering model and the fault diagnosis model to obtain a diagnosis result.
Further, the collector comprises at least four sampling ports, and each sampling port comprises a voltage value collecting sub-port and a current value collecting sub-port.
Detailed Description
To facilitate an understanding of the invention, the invention will now be described more fully with reference to the accompanying drawings. Several embodiments of the invention are shown in the drawings. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete.
It will be understood that when an element is referred to as being "secured to" another element, it can be directly on the other element or intervening elements may also be present. When an element is referred to as being "connected" to another element, it can be directly connected to the other element or intervening elements may also be present. The terms "vertical," "horizontal," "left," "right," and the like as used herein are for illustrative purposes only.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
Referring to fig. 1, a method for diagnosing a fault of a solar cell panel according to a first embodiment of the present invention includes steps S01 to S0.
And step S01, acquiring the fault IV data from the collector regularly, processing the fault IV data into a preset data structure, and storing the preset data structure into the first data set after marking the metadata. Specifically, the preset data structure is encapsulated with information such as marking metadata time, machine number, port number and the like,
step S02, collecting the fault IV data of each solar panel, and analyzing and obtaining the characteristics of each fault IV data;
step S03, analyzing the data in the first data set to divide the data in the first data set into normal data, abnormal data and fault data, storing all the abnormal data in the second data set, and storing all the normal data and all the fault data in the third data set;
specifically, the variance operation may be performed on the loss current to describe each piece of the fault IV data, so as to describe 7.2 ten thousand pieces of the fault IV data, thereby making the classification of the fault IV data finer.
Step S04, labeling the data of the third data set through the characteristics of the fault IV data; specifically, 5000 pieces of data exist in the third data set obtained through filtering, because the data collected through experiments are very few and are not enough for training the fault diagnosis model, a part of data needs to be labeled from the third data set for training and testing, and a label page is established to facilitate labeling one by one.
Note that, before the annotation, the annotation description must be written, and the annotation is performed strictly according to the above specification, for example, the label of "unknown" and "abnormal" is established to prevent the ambiguous result.
It can be understood that the number of faults originally in the collected data is small, the number of labeled data is small, and the number of data needing characteristic engineering and data derivation is correspondingly small, which is beneficial to improving the accuracy and precision of the model. The labeling data is carried out according to an IV curve graph, and a new piece of data can be obtained when two pieces of data pass through weighted average through analysis:
(
) By randomly extracting 300 pieces of data from each type, 108W pieces of data can be derived
Step S05, a neural network model is built, and the data in the second data set and the data in the third data set are used for training an abnormal data filtering model; because the data structures and purposes in the second data set and the third data set are different, separate training is needed, the accuracy of the model can be improved, the complexity of the model is reduced, and the coupling degree of the model is reduced. Because the data type in the fault IV data has obvious characteristics, the accuracy rate is 100%, and in order to simplify the trouble of later deployment, a data programming mode is used.
Step S06, constructing a time sequence cyclic neural network model, and training a fault diagnosis model by using data in a third data set; as the mapping of the fault data and the fault types needs to be deeply learned, continuous experiments show that the LSTM (long-short term memory network) is better than the CNN (convolutional neural network) on the third data set, the CNN is generally better in effect when being used on a spatial structure, the LSTM fully utilizes the characteristic of sampling on time, through comparison experiments, the LSTM is better in robustness on the data set, only the LSTM has a few parameters and needs a large amount of data for training, and a recurrent neural network model is quickly constructed by using Tensorflow.
Through a recurrent neural network model obtained after training, the accuracy of the training set reaches 99% in 3 hours of training, the accuracy of the training set reaches 91% in a test set, and 70% of error results of results are analyzed and predicted to be confused with similar fault characteristics.
Json, group1-shard1of1 bin can be obtained by converting the fault model by using Tensorflowjs
And step S07, calling the abnormal data filtering model and the fault diagnosis model by using a computer programming language to obtain a diagnosis result.
Specifically, three ways are available for deploying the model, namely, Python writes an API, embeds Java neutralizing JavaScript and calls the model, and after considering that the model is deployed by using JavaScript, the general step network has the URL that only when a model is used, a mistake is reported, the URL of a file of "group 1-shard1of1. bin" in the model is required to be modified into a request group1-shard1of1. bin.
Specifically, the step of acquiring the fault IV data from the collector at regular time and processing the fault IV data into a preset data structure includes:
setting the sampling number of the collector to be at least four sampling points, wherein the attribute of each sampling point comprises voltage and current;
and randomly extracting 100 collectors for collecting data at regular time, wherein each collector is provided with 8 ports so as to obtain data and establish the first data set.
For example, the sampling number of the collector is set to 51 sampling points, the attribute of each sampling point has voltage and current, 100 collectors are randomly extracted to collect data at regular time, the data are collected 3 times a day (for example, 9:00,14:00,17:00) for one day, one week, one month and the like, each machine has 8 ports, and then 7.2 ten thousand pieces of data can be collected to establish a first data set.
It will be appreciated that the greater the number of points employed, the more accurate the diagnostic result.
Specifically, after the first data set is established, characteristic engineering is required to be performed, because light is clustered on 7.2 ten thousand pieces of data from two dimension description IV curves of voltage and current, which is not accurate enough, more dimension information is required, for example, a maximum current value and a maximum voltage value are required, since a panel connected to each machine may not be fixed, an environment detector is not provided, temperature and irradiation amount are not known, and a standard IV curve cannot be obtained, normalization processing is performed on each piece of data, the size of the value is changed as a result, and the structure, the trend, and the correlation between the point and the point of the data are not changed. The specific normalization processing mode is that the current value is divided by the maximum current value to obtain a normalized current value, and the current voltage value is divided by the maximum voltage value to obtain a normalized voltage value; and then, the power of each sampling point is calculated according to a power calculation formula so as to obtain the maximum power value. The method for normalizing each piece of fault IV data comprises the following steps:
dividing a present voltage value in the fault IV data by a maximum voltage value, and dividing a present current value in the fault IV data by a maximum current value.
Then, an IV simulation function is established, specifically, the IV simulation function is:
wherein, PmaxTo a maximum power value, VmaxIs the maximum voltage value, ImaxIs the maximum current value, f is the fill factor, C1Is a first coefficient, C2Is the second coefficient, ViIs the ith voltage value (i is 1 to the number of sampling points).
And substituting the voltage in the fault IV data into the IV simulation function to obtain theoretical current, and according to the theoretical current, obtaining derivatives of real current, the theoretical current and loss current to the voltage, wherein the real current is the current corresponding to the fault IV data, and the loss current is the difference value of the theoretical current and the real current.
And then acquiring the real current, the actual voltage, the actual power and the theoretical current of each sampling point attribute according to the steps, and storing the real current, the actual voltage, the actual power and the theoretical current into the first data set.
And clustering the attributes of each piece of metadata in the first data set and the second data set respectively through machine learning K-Means, performing data filtering on the obtained result, and storing the filtered data into a third data set.
The solar panel fault diagnosis method can diagnose the fault of the solar panel for a user remotely, massively and regularly, thereby being convenient for providing professional repair suggestions, simultaneously, the data is fully utilized, the code amount can be reduced by using data programming, convenience is provided for the function maintenance and iteration in the future, the probability among different faults can be obtained, the possibility of expanding other functions in the future is provided, the model can be deployed on a server, a browser or a hardware RAM after being trained, the transplantation is convenient, meanwhile, the fault threshold value can be accurately controlled, and the fault accuracy can be continuously improved by adjusting parameters during the training; by deeply mining the relation between fault IV data and faults and using the features in the RNN neural network (recurrent neural network) adaptive learning data, the robustness of the model to the abnormity in the data is improved.
Specifically, in this embodiment, the computer programming language includes any one of Python, Java, and JavaScript.
Specifically, in this embodiment, the type of trouble IV data is including sheltering from, glass is cracked, hidden splits, at least one among the hot spot, and is specific, including sheltering from whole, sheltering from half quantity to solar cell panel, shelter from a solar cell panel whole, shelter from a partial solar cell panel, shelter from a little solar cell panel, dynamic shelter from solar cell panel, shelter from the shadow net and shelter from the solar cell panel circumstances such as, carry out summary analysis discovery IV curve can increase the degree of sinking along with sheltering from the degree through the trouble IV data that collect.
Through the fault IV data collected by the solar panels with glass fragmentation, subfissure or hot spot faults respectively, and the analysis of the fault IV data, the three types of faults have the same data characteristics and have fluctuation in IV and PV curves around the maximum power value.
Referring to fig. 2, a solar panel fault diagnosis system according to a second embodiment of the present invention is adapted to the solar panel fault diagnosis method, and includes:
the collector 10 is used for collecting fault IV data of the solar cell panel;
the data acquisition module 20 is used for acquiring the fault IV data from the collector 10 at regular time and processing the fault IV data into a preset data structure;
a marking module 30 for marking metadata in the fault IV data;
a data collection module 40 for collecting the fault IV data of each solar panel;
a data analysis module 50, configured to analyze and obtain characteristics of each of the fault IV data;
a classification module 60 for classifying the data in the first data set into normal data, abnormal data and fault data;
a first storage module 70 for storing data of a first data set;
a second storage module 80, configured to store data of a second data set;
a third storage module 90, configured to store data of a third data set;
a labeling module 100, configured to label data of the third data set according to characteristics of the fault IV data;
a first model building module 110, configured to build a neural network model;
a second model building module 120, configured to build a time-series recurrent neural network model;
and the computer programming language 130 is used for calling the abnormal data filtering model and the fault diagnosis model to obtain a diagnosis result.
Specifically, in this embodiment, the collector 10 includes at least four sampling ports, and each of the sampling ports includes a voltage value collecting sub-port and a current value collecting sub-port.
The solar panel fault diagnosis system can diagnose the fault of the solar panel for a user remotely, massively and regularly, so that professional repair suggestions are provided conveniently, meanwhile, data is fully utilized, the code amount can be reduced by using data programming, convenience is provided for the function maintenance and iteration in the future, the probability among different faults can be obtained, the possibility of expanding other functions in the future is provided, the model can be deployed on a server, a browser or a hardware RAM after being trained well, the transplantation is convenient, meanwhile, the fault threshold value can be accurately controlled, and the fault accuracy can be continuously improved by adjusting parameters during the training; by deeply mining the relation between fault IV data and faults and using the features in the RNN neural network (recurrent neural network) adaptive learning data, the robustness of the model to the abnormity in the data is improved.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.