A method, device, system and storage medium for generating training data
By optimizing the target timing data multiple times, building and adjusting the objective functions and constraints, the problem of insufficient data samples in deep learning model training is solved, and efficient and accurate training data generation and data recovery are achieved.
Patent Information
- Application Number
- CN202111601397.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-24
- Publication Date
- 2025-03-07
- Estimated Expiration
- 2041-12-24
AI Technical Summary
In deep learning model training, non-stationary time series data are inadequate due to uncertain fluctuation rules, which easily leads to underfitting the model and cannot obtain an effective deep learning model.
By obtaining the target timing data, the initial objective function and initial constraints are constructed, and the constraint and objective function are optimized multiple times until the verification conditions are met, simulation data for training deep learning models are generated.
It realizes accurate and efficient generation of sufficient training data, ensures the adequacy of the model's data sample, and can recover lost or damaged data to ensure data integrity.
Smart Images

Figure CN114266314B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of deep learning technology, and more specifically, to a method, device, system and storage medium for generating training data. Background Art
[0002] Before the deep learning model can be put into practical use, a large amount of data needs to be prepared in advance for training in order to obtain an applicable model.
[0003] At present, in order to ensure the accuracy of the trained model, sufficient training data needs to be prepared before training the deep learning model. However, in time series data, non-stationary time series data has no certain regularity in its fluctuations, and it is difficult to repair when the data is lost or damaged, which leads to insufficient training data samples. Training the model with insufficient data samples is likely to cause underfitting of the model and fail to obtain an effective deep learning model. Therefore, it can be seen that preparing sufficient data samples in advance is a crucial link in model training.
[0004] Therefore, how to provide a technical solution for an accurate and efficient method for generating training data has become a technical problem that needs to be solved urgently. Summary of the invention
[0005] The purpose of some embodiments of the present application is to provide a method, device, system and storage medium for generating training data. Through the technical solutions of the embodiments of the present application, it is possible to achieve the effect of accurately and efficiently generating sufficient training data. On the one hand, it is possible to recover lost or damaged data to ensure data integrity. On the other hand, it is possible to solve the problem of being unable to train an effective deep learning model due to insufficient data.
[0006] In a first aspect, some embodiments of the present application provide a method for generating training data, comprising: obtaining target time series data; constructing an initial objective function and initial constraints corresponding to the initial objective function based on the target time series data; confirming that the i-th updated objective function has not passed the verification, then adjusting the i-th constraint at least according to the fluctuation range of the target time series data, and adjusting the parameters of the i-th updated objective function according to the i-th constraint, until it is determined that the i-th updated objective function meets the verification conditions, and obtaining the objective function and target constraints, wherein, if i takes a value of 1, then the i-th updated objective function is the initial objective function and the i-th constraint is the initial constraint, and the value of i is an integer greater than or equal to 1; generating simulation data based on the objective function and the target constraints, wherein the simulation data is used as training data for training a deep learning model.
[0007] Some embodiments of the present application construct an initial objective function and initial constraints for the target time series data, and optimize the i-th constraint and then optimize the i-th updated objective function until the objective function and target constraint that meet the conditions are obtained, thereby generating training data for training the deep learning model. This method can make the generated simulation data more consistent with the real data after multiple optimizations of the objective function and target constraint, and on the one hand, it can efficiently generate a large amount of data to ensure the adequacy of the data samples of the training model, thereby providing protection for training an effective deep learning model. On the other hand, lost or damaged data can also be recovered to ensure the integrity of important data.
[0008] In some embodiments, the simulation data includes: high-voltage direct current transmission data of a high-voltage direct current transmission system, high-voltage alternating current transmission data of a high-voltage alternating current transmission system, interference voltage data of a subway stray current system, fault equipment voltage data of a pipeline equipment system, and discharge voltage data of a natural discharge system.
[0009] Some embodiments of the present application generate simulated data for different types of data, which is conducive to training various types of deep learning models and adapting to more practical application scenarios.
[0010] In some embodiments, the acquisition of target timing data includes: acquiring timing fluctuation data of real data; dividing the timing fluctuation data into multiple segments of timing data according to timing; and taking any one segment of the multiple segments of timing data as the target timing data, wherein the target timing data is two-dimensional data with time as the independent variable and voltage data as the dependent variable.
[0011] Some embodiments of the present application further acquire target time series data based on real time series fluctuation data, thereby ensuring that the ultimately generated simulation data conforms to the fluctuation trend of the real data, reducing the error between the simulation data and the real data, and thereby improving the accuracy of the simulation data.
[0012] In some embodiments, constructing an initial objective function and initial constraints corresponding to the initial objective function based on the target time series data includes: constructing the initial objective function based on the volatility and change rate of the target time series data, wherein the volatility is determined by the function value and multiplier parameter of the target time series data, and the change rate is determined by the function value of the target time series data, and confirming the initial constraints based on at least the fluctuation range of the target time series data within the target time series, wherein the initial constraints are used to limit the function value of the initial objective function.
[0013] Some embodiments of the present application construct an initial objective function and initial constraints through fluctuations in target time series data, thereby effectively improving the fitting accuracy of the initial objective function.
[0014] In some embodiments, the initial objective function is obtained by the following formula:
[0015] H=[b+F×(ba)×Percentage]×Rate
[0016] Among them, H is the initial objective function, a is the minimum value of the target parameter, b is the maximum value of the target parameter, Percentage is the rate of change of the target time series data, Rate is the volatility of the target time series data, F is a positive and negative parameter, and its value is -1 or 1, wherein F is determined by the potential of the target time series data.
[0017] Some embodiments of the present application confirm the initial target function through the characteristics of the target time series data, so as to ensure the accuracy of the initial target function.
[0018] In some embodiments, the Percentage is obtained by the following formula:
[0019]
[0020] In the formula, (c, d) is the first constraint condition set for the initial objective function, RandInt(c, d) is the random function corresponding to the first constraint condition, (e, f) is the second constraint condition set for the initial objective function, and RandInt(e, f) is the random function corresponding to the second constraint condition.
[0021] Some embodiments of the present application confirm constraint conditions through fluctuations in target time series data, thereby confirming a method for calculating the rate of change, constraining data from a qualitative and quantitative perspective, and ensuring the accuracy of feature extraction.
[0022] In some embodiments, the Rate is obtained by the following formula:
[0023]
[0024] In the formula, (q, w) is the third constraint condition set for the initial objective function, RandInt(q, w) is the random function corresponding to the third constraint condition, (s, r) is the fourth constraint condition set for the initial objective function, RandInt(s, r) is the random function corresponding to the fourth constraint condition, and D is the multiplier.
[0025] Some embodiments of the present application confirm constraint conditions through the fluctuation of target time series data, and confirm the calculation method of fluctuation rate in combination with the multiple of the data, thereby constraining the data from qualitative and quantitative perspectives and ensuring the accuracy of feature extraction.
[0026] In some embodiments, adjusting the i-th constraint condition at least according to the fluctuation range of the target time series data includes: adjusting the i-th constraint condition within a set fluctuation threshold according to the fluctuation range and offset of the target time series data, wherein the i-th constraint condition is used to limit the function value of the i-th updated objective function.
[0027] Some embodiments of the present application continuously optimize the i-th constraint condition by adjusting the fluctuation range and offset of the target time series data, thereby gradually improving the accuracy of the constraint condition.
[0028] In some embodiments, the offset is obtained by the following positive offset function h1: h1=b+F×(ba); or, the offset is obtained by the following negative offset function h2: h2=a+F×(ab).
[0029] Some embodiments of the present application confirm the offset through the target parameter, and can perform qualitative and quantitative analysis and solution on the function.
[0030] In some embodiments, the determination that the i-th updated objective function satisfies the verification conditions to obtain the objective function and the target constraint conditions includes: confirming that the error between the simulation data generated according to the i-th updated objective function and the i-th constraint conditions and the target timing data is less than or equal to a set error threshold, then using the i-th updated objective function as the objective function, and using the i-th constraint conditions as the target constraint conditions.
[0031] Some embodiments of the present application compare the error between the generated simulation data and the target time series data with a threshold to confirm whether to stop updating the i-th update objective function, so that the final objective function and objective constraints can generate simulation data with higher accuracy, providing effective support for data recovery and model training.
[0032] In some embodiments, confirming the initial constraint condition at least based on the fluctuation range of the target time series data within the target time series includes: determining the initial constraint condition based on the fluctuation range of the target time series data within the target time series and the type of the target time series data.
[0033] Some embodiments of the present application extract different data features through different data types, so that the initial constraint conditions can accurately constrain the initial objective function corresponding to the corresponding data type.
[0034] In some embodiments, the target time series data is the high voltage direct current transmission data acquired by collecting data from the high voltage direct current transmission system, wherein the initial constraint condition further includes: a=0.
[0035] Some embodiments of the present application constrain high-voltage direct current transmission data by relevant parameters of the high-voltage direct current transmission system, so as to accurately constrain the initial objective function corresponding to the high-voltage direct current transmission data and ensure the accuracy of the high-voltage direct current transmission simulation data generated by the final objective function.
[0036] In some embodiments, the target time series data is the high-voltage AC power transmission data acquired by collecting data from the high-voltage AC power transmission system, wherein the initial constraint condition further includes: D≥380.
[0037] Some embodiments of the present application constrain high-voltage AC transmission data by relevant parameters of the high-voltage AC transmission system, so as to accurately constrain the initial objective function corresponding to the high-voltage AC transmission data and ensure the accuracy of the high-voltage AC transmission simulation data generated by the final objective function.
[0038] In some embodiments, the target time series data is the interference voltage data obtained by collecting the subway stray current system, wherein the initial constraint condition further includes: a=0.
[0039] Some embodiments of the present application can accurately constrain the initial objective function corresponding to the interference voltage data by constraining the interference voltage data through the relevant parameters of the subway stray current system, thereby ensuring the accuracy of the interference voltage simulation data generated by the final objective function.
[0040] In some embodiments, the target time series data is the faulty equipment voltage data acquired by collecting the pipeline equipment system, wherein the initial constraint condition further includes:
[0041] Percentage = 0
[0042] as well as
[0043]
[0044] Among them, R Receive-voltage is the peak voltage of the test pile.
[0045] Some embodiments of the present application can accurately constrain the initial objective function corresponding to the equipment voltage data by constraining the faulty equipment voltage data through relevant parameters of the pipeline equipment system, thereby ensuring the accuracy of the equipment voltage simulation data generated by the final objective function.
[0046] In some embodiments, the target time series data is the discharge voltage data obtained by collecting the natural discharge system, wherein the constraint condition further includes:
[0047] D ≥ K;
[0048] Percentage = 0; and
[0049]
[0050] Among them, R Receive-voltage is the peak voltage of the test pile.
[0051] Some embodiments of the present application constrain the discharge voltage data by relevant parameters of the natural discharge system, so as to accurately constrain the initial objective function corresponding to the discharge voltage data and ensure the accuracy of the discharge voltage simulation data generated by the final objective function.
[0052] In a second aspect, some embodiments of the present application provide a training data generation device, comprising: a data acquisition module, configured to acquire target time series data; a function construction module, configured to construct an initial objective function and initial constraints corresponding to the initial objective function according to the target time series data; a function confirmation module, configured to confirm that if the i-th updated objective function fails the verification, then adjust the i-th constraint at least according to the fluctuation range of the target time series data, and adjust the parameters of the i-th updated objective function according to the i-th constraint, until it is determined that the i-th updated objective function meets the verification conditions, and the objective function and target constraints are obtained, wherein, if i takes the value of 1, the i-th updated objective function is the initial objective function and the i-th constraint is the initial constraint, and the value of i is an integer greater than or equal to 1; a data generation module, configured to generate simulation data according to the objective function and the target constraint, wherein the simulation data is used as training data for training a deep learning model.
[0053] In a third aspect, some embodiments of the present application provide a device for training a deep learning model, the device comprising one or more modules, and the one or more modules are configured to train the deep learning model with simulated data obtained by the method of any embodiment of the first aspect.
[0054] In a fourth aspect, some embodiments of the present application provide a system comprising one or more computers and one or more storage devices storing instructions, wherein when the instructions are executed by the one or more computers, the one or more computers perform the operations of the corresponding methods of any embodiment in the first aspect.
[0055] In a fifth aspect, some embodiments of the present application provide one or more computer storage media storing instructions, which, when executed by one or more computers, enable the one or more computers to perform the operations of the corresponding methods of any embodiment in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] In order to more clearly illustrate the technical solutions of some embodiments of the present application, the drawings required for use in some embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0057] Figure 1 A system structure diagram of a method for generating training data provided in some embodiments of the present application;
[0058] Figure 2 A flowchart of a method for generating training data provided in some embodiments of the present application;
[0059] Figure 3 A schematic diagram of time series fluctuation data of real data provided by some embodiments of the present application;
[0060] Figure 4 A flowchart of a method for generating training data provided in some embodiments of the present application;
[0061] Figure 5 A block diagram of a device for generating training data provided in some embodiments of the present application. DETAILED DESCRIPTION
[0062] The technical solutions in some embodiments of the present application will be described below in conjunction with the drawings in some embodiments of the present application.
[0063] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.
[0064] In related art examples, in response to the loss, damage, and insufficiency of non-stationary time series data, traditional methods generally adopt a completely quantitative perspective to analyze the data, resulting in poor performance of recovered or regenerated data.
[0065] From the above related technologies, we can see that the traditional method of generating time series data only analyzes from a quantitative perspective. This analysis method is too simple and cannot generate a large amount of data, resulting in underfitting in the training model stage. At the same time, the accuracy of the restored or regenerated time series data is also low.
[0066] In view of this, some embodiments of the present application construct the corresponding initial objective function and initial constraints for the target time series data, and adjust the ith constraint multiple times to adjust the ith updated objective function to obtain the final objective function and target constraint. This method achieves the effect of accurately and efficiently generating sufficient training data, and on the one hand, it can recover lost or damaged data to ensure data integrity, and on the other hand, it can also solve the problem of being unable to train an effective deep learning model due to insufficient data.
[0067] The following is an illustrative introduction to the specific implementation process of a method for generating training data provided in some embodiments of the present application.
[0068] like Figure 1 As shown, some embodiments of the present application provide a system structure diagram of a method for generating training data, which includes a terminal device 100 and a data processing server 200, wherein the terminal device 100 can be used to store collected real data and send the real data to the data processing server 200 for processing to obtain training data.
[0069] In addition, it should be noted that in some other embodiments of the present application, the terminal device 100 may also have the function of storing and processing real data to obtain training data, and in this case, the data processing server may not be set. Among them, the terminal device may be a non-portable PC terminal or a portable mobile terminal device.
[0070] Figure 1 The data processing server 200 is provided with an algorithm corresponding to the method for generating training data, and it is through the configuration file of the algorithm that the data processing server 200 can obtain the training data.
[0071] It is understandable that in order to enable the data processing server 200 to have the ability to generate training data, it is necessary to confirm in advance the corresponding algorithm of the training data generation method.
[0072] The specific implementation process of a method for generating training data provided by some embodiments of the present application is described below with reference to examples.
[0073] Please see attached Figure 2 , Figure 2A flowchart of a method for generating training data provided for some embodiments of the present application, the method may include: S210, obtaining target time series data; S220, constructing an initial objective function and initial constraints corresponding to the initial objective function based on the target time series data; S230, confirming that the i-th updated objective function has not passed the verification, then adjusting the i-th constraint at least according to the fluctuation range of the target time series data, and adjusting the parameters of the i-th updated objective function according to the i-th constraint, until it is determined that the i-th updated objective function meets the verification conditions, and obtaining the objective function and target constraints, wherein, if i takes the value of 1, then the i-th updated objective function is the initial objective function and the i-th constraint is the initial constraint, and the value of i is an integer greater than or equal to 1; S240, generating simulation data based on the objective function and the target constraints, wherein the simulation data is used as training data for training a deep learning model.
[0074] The above process is explained below as an example.
[0075] In some embodiments of the present application, S210 may include acquiring timing fluctuation data of real data; dividing the timing fluctuation data into multiple segments of timing data according to timing; and taking any segment of the multiple segments of timing data as the target timing data, wherein the target timing data is two-dimensional data with time as the independent variable and voltage data as the dependent variable.
[0076] For example, as a specific example of this application, the time series fluctuation data of real data is as follows Figure 3 The time-voltage image shown in the figure, wherein the four circles in the figure indicate that the entire segment of data is divided into five segments of timing data, and any segment among them is taken as the target timing data.
[0077] In some embodiments of the present application, S220 may include constructing the initial objective function based on the volatility and change rate of the target time series data, wherein the volatility is determined by the function value and multiplication parameter of the target time series data, and the change rate is determined by the function value of the target time series data, and the initial constraint condition is confirmed at least based on the fluctuation range of the target time series data within the target time series, wherein the initial constraint condition is used to limit the function value of the initial objective function.
[0078] For example, as a specific example of the present application, the initial target function is determined based on the volatility and change rate of the target time series data. The target time series data is divided into several segments again to obtain the target data, and then the voltage fluctuation range of each segment of the target data is obtained and a random function is constructed. The change rate is the ratio of the random function of any two segments of the target data, and the volatility is the relationship between the ratio of any two segments of the target data and the multiple and the positive and negative parameters.
[0079] It should be noted that those skilled in the art can construct reasonable calculation formulas based on concepts or formulas. The calculation formulas provided in some embodiments of the present application are as follows.
[0080] In some embodiments of the present application, the initial objective function is obtained by the following formula:
[0081] H=[b+F×(ba)×Percentage]×Rate
[0082] Among them, H is the initial objective function, a is the minimum value of the target parameter, b is the maximum value of the target parameter, Percentage is the rate of change of the target time series data, Rate is the volatility of the target time series data, F is a positive and negative parameter, and its value is -1 or 1, wherein F is determined by the potential of the target time series data.
[0083] For example, as a specific example of this application, Figure 3 In the potential change image (i.e., time-voltage image) of the HVDC shown, the target parameters are the normal voltage change range, a=-1.25V, b=-0.85V, and F is determined based on the potential change of the HVDC. When the potential change is positive, it takes 1, and when it is negative, it takes -1. It should be understood that the value of F is specifically determined based on actual conditions and is not limited here.
[0084] In some embodiments of the present application, the Percentage is obtained by the following formula:
[0085]
[0086] In the formula, (c, d) is the first constraint condition set for the initial objective function, RandInt(c, d) is the random function corresponding to the first constraint condition, (e, f) is the second constraint condition set for the initial objective function, and RandInt(e, f) is the random function corresponding to the second constraint condition.
[0087] In some embodiments of the present application, the Rate is obtained by the following formula:
[0088]
[0089] In the formula, (q, w) is the third constraint condition set for the initial objective function, RandInt(q, w) is the random function corresponding to the third constraint condition, (s, r) is the fourth constraint condition set for the initial objective function, RandInt(s, r) is the random function corresponding to the fourth constraint condition, and D is the multiplier.
[0090] In some embodiments of the present application, S230 may include adjusting the i-th constraint condition within a set fluctuation threshold according to the fluctuation range and offset of the target time series data, wherein the i-th constraint condition is used to limit the function value of the i-th updated objective function.
[0091] In some embodiments of the present application, the offset is obtained by the following positive offset function h1:
[0092] h1=b+F×(ba);
[0093] or,
[0094] The offset is obtained by the following negative offset function h2:
[0095] h2=a+F×(ab).
[0096] For example, as a specific example of the present application, the fluctuation range of a segment of target data in the target time series data is (y1, y2), the offset h1=1, h2=0, and the set fluctuation threshold is Δy, then the adjusted constraint condition is (y1+h1+h2+Δy, y2+h1+h2+Δy).
[0097] In some embodiments of the present application, when executing S230 to determine whether the i-th updated objective function satisfies the verification conditions and obtains the objective function and target constraint conditions, it includes: confirming that the error between the simulation data generated according to the i-th updated objective function and the i-th constraint conditions and the target timing data is less than or equal to a set error threshold, then using the i-th updated objective function as the objective function, and using the i-th constraint conditions as the target constraint conditions.
[0098] For example, in some embodiments of the present application, the error between the generated simulation data and the target time series data is confirmed in the form of relative error or absolute error. In addition, the above can confirm whether the i-th updated target function has passed the verification based on the comparison between the error and the error threshold, or it can use the idea of limit in higher mathematics to determine whether the error tends to 0 to confirm whether the i-th updated target function has passed the verification. It should be understood that the specific method of using relative error or absolute error needs to be selected according to the actual data situation, and is not limited here.
[0099] In some embodiments of the present application, confirming the initial constraint condition at least based on the fluctuation range of the target time series data within the target time series includes: determining the initial constraint condition based on the fluctuation range of the target time series data within the target time series and the type of the target time series data.
[0100] For example, since the training data involves different application scenarios, the initial constraints need to be determined based on the characteristics of the data type in the scenario to ensure the accuracy of the simulation data generated by the final objective function and objective constraints.
[0101] In some embodiments of the present application, the target time series data is the high voltage direct current transmission data acquired by collecting data from the high voltage direct current transmission system, wherein the initial constraint condition further includes: a=0.
[0102] For example, in some embodiments of the present application, the non-stationary time series data characteristic of high voltage direct current (HVDC) discharge generated by high voltage direct current transmission (Higher Voltage DC, HVDC) data is that the voltage will increase or decrease regularly in a certain period of time, so the specific constraint condition of the initial constraint condition is a=0.
[0103] In some embodiments of the present application, the target time series data is the high-voltage AC power transmission data acquired by collecting the high-voltage AC power transmission system, wherein the initial constraint condition further includes: D≥380.
[0104] For example, in some embodiments of the present application, the non-stationary time series data characteristic of high voltage AC discharge generated by high voltage AC transmission data is that periodic and violent fluctuations occur over a period of time, so the specific constraint condition of the initial constraint condition is D≥380.
[0105] In some embodiments of the present application, the target time series data is the interference voltage data obtained by collecting the subway stray current system, wherein the initial constraint condition also includes: a=0.
[0106] For example, in some embodiments of the present application, the interference voltage data of the subway stray current interference generated by the subway stray current system (Random Voltage, RV for short) is non-stationary time series data, characterized by large up and down fluctuations, so the specific constraint condition of the initial constraint condition is a=0.
[0107] In some embodiments of the present application, the target time series data is the faulty equipment voltage data acquired by collecting the pipeline equipment system, wherein the initial constraint condition further includes:
[0108] Percentage = 0
[0109] as well as
[0110]
[0111] Among them, R Receive-voltage is the peak voltage of the test pile.
[0112] For example, in some embodiments of the present application, the time series data related to the outliers generated by the pipeline short circuit (One Point Voltage, abbreviated as OPV) system is characterized by large fluctuations at a single point, which is the time series data generated when the equipment fails. Therefore, the specific constraints of the initial constraints are Percentage=0 and the test pile voltage value constraint.
[0113] In some embodiments of the present application, the target time series data is the discharge voltage data obtained by collecting the natural discharge system, wherein the constraint condition further includes:
[0114] D ≥ K;
[0115] Percentage = 0; and
[0116]
[0117] Among them, R Receive-voltage is the peak voltage of the test pile.
[0118] For example, in some embodiments of the present application, the non-stationary time series data of the natural discharge interference generated by the natural discharge system (Nature Voltage, NV for short) is characterized by violent fluctuations at a single point or multiple points. Therefore, the specific constraints of the initial constraints are D≥K, Percentage=0 and the test pile voltage value constraint, where the value of K is determined based on the average voltage received by the RV system equipment after the ball lightning hits the ground, which is (5000, 10000). It can be understood that the specific value of D can be finally confirmed within the range of (5000, 10000) according to actual conditions, and no specific limitation is made here. In addition, it should be understood that the voltage peak value of the test pile involved above is obtained by actual measurement of the measuring equipment.
[0119] Below Figure 3 The real data time series fluctuation image is used as an example, combined with Figure 4 The specific implementation process of the method for generating training data provided in some embodiments of the present application is exemplified.
[0120] S410, obtaining time series fluctuation data of real data, and segmenting the time series fluctuation data to obtain target time series data.
[0121] For example, as a specific example of this application, Figure 3 The figure shows the HVDC non-stationary time series data obtained in the HVDC system. Figure 3The data is divided into five time series data segments (as shown in the circles indicated by "1, 2, 3, 4" in the figure). The specific coordinates of the four dividing points are: (x1, y1), (x2, y2), (x3, y3), (x4, y4). The time series value ranges of the five time series data segments are (0, x1), (x1, x2), (x2, x3), (x3, x4), (x4, x5).
[0122] S420, constructing an initial objective function and initial constraints corresponding to the initial objective function according to the target time series data, and adjusting to obtain an i-th updated objective function and an i-th constraint, where i is a positive integer.
[0123] For example, as a specific example of the present application, it should be understood that each segmented function in the following segmented initial objective function represents the initial objective function of a segment of target time series data. The constructed segmented initial objective function is as follows:
[0124]
[0125] Initial constraints:
[0126]
[0127] Where a1, a2, b1, b2, c1 and c2 are the parameters of the initial objective functions y2 and y4, y a is the minimum value of the function value y2, y b is the maximum value of the function value y2, y c is the minimum value of the function value y4, y d is the maximum value of the function y4.
[0128] It should be noted that, in order to facilitate the understanding of the above formula, y1 and y2 are used as examples for illustrative explanation, and the remaining initial objective functions can be understood by referring to the following description. In the interval (0, x1), the value of y1 in the image is -1.2. When the initial constraint condition is given, the value of y1 can be a random number in (-1.25, -1.15). Then, according to the specific fluctuation range of the real image, the initial constraint condition is adjusted to obtain the range of the i-th constraint condition. For example, the value of y1 is adjusted to (-1.22, -1.17), and such constraints are also defined as probabilistic constraints. In addition, for the initial objective function y2, the function parameters of y2 are adjusted by the value range of y2 to obtain the i-th updated objective function, so that the image corresponding to the i-th updated objective function is more in line with the real time series data image.
[0129] It should be noted that the above initial objective function is derived from the general formula H = [b + F × (ba) × Percentage] × Rate by recursive method. Although there are differences in the form of the formula, the essential content expressed is the same, and the method steps involved in constructing the objective function are essentially the same. Although the equation description is different, its essential idea principle is based on the method for generating training data in some embodiments of the present application, and will not be repeated here for the sake of brevity.
[0130] S430, determining whether the i-th updated objective function satisfies a verification condition, and obtaining an objective function and objective constraint conditions.
[0131] As a specific example of the present application, it can be confirmed that the error between the simulation data generated according to the i-th updated objective function and the i-th constraint condition and the target time series data is less than or equal to the set error threshold, then the i-th updated objective function is used as the objective function, and the i-th constraint condition is used as the target constraint condition. The error can be characterized by a relative error or an absolute error.
[0132] In some embodiments of the present application, the relative error W Relative-Error It is obtained through the following formula:
[0133]
[0134] In the formula, X t is the target time series data at the tth moment, Y t is the simulation data at the tth moment, and m is the total number of moments.
[0135] In some embodiments of the present application, the relative error W Relative-Error It is obtained by the following formula:
[0136]
[0137] In addition, the limit idea can also be used to confirm whether it has passed the verification, that is:
[0138]
[0139]
[0140] It should be noted that some embodiments of the present application are only described for the target time series data (that is, any segment of multiple segments in the real data). In actual application scenarios, the lengths of the time series data involved are different. After the real data is divided into multiple segments, the final generated objective function and objective constraints can be represented in the form of piecewise functions.
[0141] S440, generating simulation data according to the objective function and the objective constraints, wherein the simulation data is used as training data for training the deep learning model.
[0142] For example, as a specific example of the present application, sufficient simulation data is generated according to the objective function and constraint conditions of the HVDC data obtained above, and the simulation data is used as training data for training the HVDC deep learning model.
[0143] In addition, in some other embodiments of the present application, simulation data may be generated according to the objective function and constraint conditions of the HVDC data obtained above, and the simulation data is used to restore or repair the real data.
[0144] Please refer to Figure 5 , Figure 5 FIG. 1 is a block diagram showing a training data generation device provided in some embodiments of the present application. It should be understood that the training data generation device is similar to the above-mentioned Figure 2 Corresponding to the method embodiment, each step involved in the above method embodiment can be executed. The specific functions of the training data generating device can be found in the above description. To avoid repetition, the detailed description is appropriately omitted here.
[0145] Figure 5 The training data generation device includes at least one software function module that can be stored in a memory in the form of software or firmware or fixed in the training data generation device, and the training data generation device may include: a data acquisition module 510, configured to acquire target time series data; a function construction module 520, configured to construct an initial objective function and an initial constraint condition corresponding to the initial objective function according to the target time series data; a function confirmation module 530, configured to confirm that the i-th updated objective function has not passed the verification, then adjust the i-th constraint condition at least according to the fluctuation range of the target time series data, and adjust the parameters of the i-th updated objective function according to the i-th constraint condition, until it is determined that the i-th updated objective function meets the verification condition, and obtain the objective function and the objective constraint condition, wherein, if i takes a value of 1, the i-th updated objective function is the initial objective function and the i-th constraint condition is the initial constraint condition, and the value of i is an integer greater than or equal to 1; a data generation module 540, configured to generate simulation data according to the objective function and the target constraint condition, wherein the simulation data is used as training data for training a deep learning model.
[0146] In some embodiments of the present application, the simulation data includes: high-voltage direct current transmission data of a high-voltage direct current transmission system, high-voltage alternating current transmission data of a high-voltage alternating current transmission system, interference voltage data of a subway stray current system, fault equipment voltage data of a pipeline equipment system, and discharge voltage data of a natural discharge system.
[0147] In some embodiments of the present application, the data acquisition module 510 can also be configured to acquire timing fluctuation data of real data; divide the timing fluctuation data into multiple segments of timing data according to the timing; and use any one of the multiple segments of timing data as the target timing data, wherein the target timing data is two-dimensional data with time as the independent variable and voltage data as the dependent variable.
[0148] In some embodiments of the present application, the function construction module 520 is configured to construct the initial objective function based on the volatility and change rate of the target time series data, wherein the volatility is determined by the function value and the multiplier parameter of the target time series data, and the change rate is determined by the function value of the target time series data, and the initial constraint condition is confirmed at least based on the fluctuation range of the target time series data within the target time series, wherein the initial constraint condition is used to limit the function value of the initial objective function.
[0149] In some embodiments of the present application, the initial objective function is obtained by the following formula:
[0150] H=[b+F×(ba)×Percentage]×Rate
[0151] Among them, H is the initial objective function, a is the minimum value of the target parameter, b is the maximum value of the target parameter, Percentage is the rate of change of the target time series data, Rate is the volatility of the target time series data, F is a positive and negative parameter, and its value is -1 or 1, wherein F is determined by the potential of the target time series data.
[0152] In some embodiments of the present application, the Percentage is obtained by the following formula:
[0153]
[0154] In the formula, (c, d) is the first constraint condition set for the initial objective function, RandInt(c, d) is the random function corresponding to the first constraint condition, (e, f) is the second constraint condition set for the initial objective function, and RandInt(e, f) is the random function corresponding to the second constraint condition.
[0155] In some embodiments of the present application, the Rate is obtained by the following formula:
[0156]
[0157] In the formula, (q, w) is the third constraint condition set for the initial objective function, RandInt(q, w) is the random function corresponding to the third constraint condition, (s, r) is the fourth constraint condition set for the initial objective function, RandInt(s, r) is the random function corresponding to the fourth constraint condition, and D is the multiplier.
[0158] In some embodiments of the present application, the function confirmation module 530 can also be configured to adjust the i-th constraint condition within a set fluctuation threshold according to the fluctuation range and offset of the target time series data, wherein the i-th constraint condition is used to limit the function value of the i-th updated objective function.
[0159] In some embodiments of the present application, the offset is obtained by the following positive offset function h1:
[0160] h1=b+F×(ba);
[0161] or,
[0162] The offset is obtained by the following negative offset function h2:
[0163] h2=a+F×(ab).
[0164] In some embodiments of the present application, the function confirmation module 530 can also be configured to confirm that the error between the simulation data generated according to the i-th updated objective function and the i-th constraint condition and the target timing data is less than or equal to a set error threshold, and then the i-th updated objective function is used as the objective function, and the i-th constraint condition is used as the target constraint condition.
[0165] In some embodiments of the present application, confirming the initial constraint condition at least based on the fluctuation range of the target timing data within the target timing, includes: determining the initial constraint condition based on the fluctuation range of the target timing data within the target timing and the type of the target timing data.
[0166] In some embodiments of the present application, the target time series data is the high voltage direct current transmission data acquired by collecting data from the high voltage direct current transmission system, wherein the initial constraint condition further includes: a=0.
[0167] In some embodiments of the present application, the target time series data is the high-voltage AC power transmission data acquired by collecting the high-voltage AC power transmission system, wherein the initial constraint condition further includes: D≥380.
[0168] In some embodiments of the present application, the target time series data is the interference voltage data obtained by collecting the subway stray current system, wherein the initial constraint condition also includes: a=0.
[0169] In some embodiments of the present application, the target time series data is the faulty equipment voltage data acquired by collecting the pipeline equipment system, wherein the initial constraint condition further includes:
[0170] Percentage = 0
[0171] as well as
[0172]
[0173] Among them, R Receive-voltage is the peak voltage of the test pile.
[0174] In some embodiments of the present application, the target time series data is the discharge voltage data obtained by collecting the natural discharge system, wherein the constraint condition further includes:
[0175] D ≥ K;
[0176] Percentage = 0; and
[0177]
[0178] Among them, R Receive-voltage is the peak voltage of the test pile.
[0179] Some embodiments of the present application also provide a device for training a deep learning model, the device comprising one or more modules, wherein the one or more modules are configured to adopt Figure 2 The deep learning model is trained using simulated data obtained using the method of any embodiment.
[0180] Some embodiments of the present application also provide a system, the system comprising one or more computers and one or more storage devices storing instructions, when the instructions are executed by the one or more computers, the one or more computers execute Figure 2 The operations of the method of any embodiment.
[0181] Some embodiments of the present application also provide one or more computer storage media storing instructions, which, when executed by one or more computers, enable the one or more computers to execute Figure 2 The operations of the method of any embodiment.
[0182] The above description is only an embodiment of the present application and is not intended to limit the scope of protection of the present application. For those skilled in the art, the present application may have various changes and variations. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application. It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in the subsequent drawings.
[0183] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0184] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
Claims
1. A method for generating training data, characterized in that: include: Get target time series data; Constructing an initial objective function and initial constraint conditions corresponding to the initial objective function according to the target time series data; If it is confirmed that the i-th updated objective function has not passed the verification, the i-th constraint condition is adjusted at least according to the fluctuation range of the target time series data, and the parameters of the i-th updated objective function are adjusted according to the i-th constraint condition, until it is determined that the i-th updated objective function meets the verification conditions, and the objective function and the target constraint condition are obtained, wherein, if the value of i is 1, the i-th updated objective function is the initial objective function and the i-th constraint condition is the initial constraint condition, and the value of i is an integer greater than or equal to 1; Generate simulation data according to the objective function and the objective constraint, wherein the simulation data is used as training data for training a deep learning model; The acquiring target time series data comprises: acquiring time series fluctuation data of real data; dividing the time series fluctuation data into multiple time series data segments according to the time series; taking any one of the multiple time series data segments as the target time series data, wherein the target time series data is two-dimensional data with time as the independent variable and voltage data as the dependent variable; The constructing of the initial objective function and the initial constraint conditions corresponding to the initial objective function according to the target time series data comprises: constructing the initial objective function according to the volatility and change rate of the target time series data, wherein the volatility is determined by the function value and the multiplication parameter of the target time series data, and the change rate is determined by the function value of the target time series data, and confirming the initial constraint conditions at least according to the fluctuation range of the target time series data within the target time series, wherein the initial constraint conditions are used to limit the function value of the initial objective function; The initial objective function is obtained by the following formula: H=[b+F×(ba)×Percentage]×Rate Among them, H is the initial objective function, a is the minimum value of the target parameter, b is the maximum value of the target parameter, Percentage is the rate of change of the target time series data, Rate is the volatility of the target time series data, F is a positive and negative parameter, and its value is -1 or 1, wherein F is determined by the potential of the target time series data.
2. The generation method according to claim 1, characterized in that: The simulation data includes: high-voltage direct current transmission data of the high-voltage direct current transmission system, high-voltage alternating current transmission data of the high-voltage alternating current transmission system, interference voltage data of the subway stray current system, fault equipment voltage data of the pipeline equipment system and discharge voltage data of the natural discharge system.
3. The generation method according to claim 1, characterized in that: The Percentage is obtained by the following formula: In the formula, (c, d) is the first constraint condition set for the initial objective function, RandInt(c, d) is the random function corresponding to the first constraint condition, (e, f) is the second constraint condition set for the initial objective function, and RandInt(e, f) is the random function corresponding to the second constraint condition.
4. The generation method according to claim 1, characterized in that: The Rate is obtained by the following formula: In the formula, (q, w) is the third constraint condition set for the initial objective function, RandInt(q, w) is the random function corresponding to the third constraint condition, (s, r) is the fourth constraint condition set for the initial objective function, RandInt(s, r) is the random function corresponding to the fourth constraint condition, and D is the multiplier.
5. The generation method according to any one of claims 1 to 2, characterized in that: The step of adjusting the i-th constraint condition at least according to the fluctuation range of the target time series data includes: According to the fluctuation range and offset of the target time series data, the i-th constraint condition is adjusted within a set fluctuation threshold, wherein the i-th constraint condition is used to limit the function value of the i-th update objective function.
6. The generation method according to claim 5, characterized in that: The offset is obtained by the following positive offset function h1: h1=b+F×(ba); or, The offset is obtained by the following negative offset function h2: h2=a+F×(ab).
7. The generation method according to claim 5, characterized in that: The determining that the i-th updated objective function satisfies a verification condition to obtain an objective function and an objective constraint condition comprises: Confirm that the error between the simulation data generated according to the i-th updated objective function and the i-th constraint condition and the target time series data is less than or equal to the set error threshold, then use the i-th updated objective function as the objective function and the i-th constraint condition as the target constraint condition.
8. The generation method according to claim 1, characterized in that: The step of confirming the initial constraint condition at least according to the fluctuation range of the target time series data within the target time series includes: The initial constraint condition is determined according to a fluctuation range of the target time series data within the target time series and a type of the target time series data.
9. The generation method according to claim 2 or 8, characterized in that: The target time series data is the high voltage direct current transmission data acquired by collecting data from the high voltage direct current transmission system, wherein the initial constraint condition further includes: a=0.
10. The generation method according to claim 2 or 8, characterized in that: The target time series data is the high-voltage AC power transmission data acquired by collecting the high-voltage AC power transmission system, wherein the initial constraint condition further includes: D≥380.
11. The generation method according to claim 2 or 8, characterized in that: The target time series data is the interference voltage data obtained by collecting the subway stray current system, wherein the initial constraint condition also includes: a=0.
12. The generation method according to claim 2 or 8, characterized in that: The target time series data is the faulty equipment voltage data acquired by collecting the pipeline equipment system, wherein the initial constraint condition further includes: Percentage = 0 as well as Among them, R Receive-voltage is the peak voltage of the test pile.
13. The generation method according to claim 2 or 8, characterized in that: The target time series data is the discharge voltage data obtained by collecting the natural discharge system, wherein the constraint condition further includes: D ≥ K; Percentage = 0; and Among them, R Receive-voltage is the peak voltage of the test pile.
14. A training data generating device, characterized in that: The device is used to perform the method according to claim 1, comprising: A data acquisition module is configured to acquire target time series data; A function construction module is configured to construct an initial objective function and initial constraints corresponding to the initial objective function according to the target time series data; A function confirmation module is configured to confirm that if the i-th updated objective function fails the verification, adjust the i-th constraint condition at least according to the fluctuation range of the target time series data, and adjust the parameters of the i-th updated objective function according to the i-th constraint condition, until it is determined that the i-th updated objective function meets the verification conditions, and obtain the objective function and the target constraint condition, wherein, if the value of i is 1, the i-th updated objective function is the initial objective function and the i-th constraint condition is the initial constraint condition, and the value of i is an integer greater than or equal to 1; The data generation module is configured to generate simulation data according to the objective function and the objective constraint conditions, wherein the simulation data is used as training data for training a deep learning model.
15. A device for training a deep learning model, the device comprising one or more modules, wherein the one or more modules are configured to train the deep learning model by performing the functions implemented by the method described in any one of claims 1 to 3.
16. A system comprising one or more computers and one or more storage devices storing instructions, which, when executed by the one or more computers, cause the one or more computers to perform the method according to any one of claims 1 to 13.
17. One or more computer storage media storing instructions which, when executed by one or more computers, cause the one or more computers to perform the method according to any one of claims 1-13.
Citation Information
Patent Citations
Migration model training method and device and fault detection method and device
CN111612035A
Data processing method and device based on federated learning
CN111985649A