User electricity abnormality analysis method and system based on double comparison, and medium
Patent Information
- Application Number
- CN202211180693.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-27
- Publication Date
- 2026-11-03
- Estimated Expiration
- 2042-09-27
AI Technical Summary
[0002]随着电表使用年限不断增加,电能表精准度也越来越低,误差越来越大,使得台区电表误差情况无法被监测到
[0055]本发明获取用户用电数据,生成对应的用电数据特征指标,通过双向对比分析,一方面从横向对比得到用户的初步异常用电情况,另一方面根据初步异常的用电数据进行纵向对比,得到精准的判定结果,综合考虑了用户用电的差异性,提高智能电表的检测和运行状态评价的准确性,有利于维护智能电表的安全稳定运行。
Smart Images

Figure CN115549299B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of user electricity consumption behavior analysis, specifically relating to a user electricity consumption anomaly analysis method, system, and medium based on dual comparison. Background Technology
[0002] As electricity meters age, their accuracy decreases and errors increase, making it difficult to monitor meter errors in a distribution area. Current technologies for calculating meter errors in distribution areas require statistical analysis of user electricity consumption behavior to improve the effective monitoring and evaluation of smart meter asset management. However, due to variations in user behavior, the obtained electricity consumption data has a degree of randomness. In actual calculations, this random data needs to be comprehensively considered, leading to inaccurate statistical results. Furthermore, the statistical process is based on distribution areas, failing to consider user differences, resulting in low accuracy in smart meter detection and operational status evaluation. Therefore, to improve the effective monitoring and evaluation of smart meter asset management, error calculation of massive amounts of meter data is necessary. Summary of the Invention
[0003] The main objective of this invention is to overcome the shortcomings and deficiencies of the prior art and provide a method, system, and medium for analyzing abnormal user electricity consumption based on dual comparison. By acquiring user electricity consumption data, corresponding electricity consumption data indicators are generated. User electricity consumption behavior is analyzed from both horizontal and vertical comparisons. The differences in user electricity consumption are comprehensively considered, enabling the judgment of abnormal user electricity consumption data and improving the accuracy of smart meter detection and operational status evaluation.
[0004] To achieve the above objectives, the present invention adopts the following technical solution:
[0005] On the one hand, a user power consumption anomaly analysis method based on dual comparison is provided, including the following steps:
[0006] Obtain electricity consumption data for all users within the same transformer area and generate an electricity consumption dataset for all users.
[0007] Set thresholds for abnormal user electricity consumption, including a first abnormal threshold and a second abnormal threshold;
[0008] In the first electricity consumption cycle, extract the electricity consumption data of all users in a certain electricity consumption time period from the electricity consumption dataset of all users, and generate the average electricity consumption data feature index of all users; in the second electricity consumption cycle, extract the electricity consumption data of a specified user in the same electricity consumption time period from the electricity consumption dataset of all users, and generate the electricity consumption data feature index of the specified user.
[0009] The average electricity consumption data of all users is used as the first anomaly threshold. A horizontal comparative analysis is conducted with the electricity consumption data of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal.
[0010] If an initial anomaly is detected, the electricity consumption data of the specified user in the same time period during the first N electricity consumption cycles is extracted from all user electricity consumption datasets, and the average electricity consumption data feature index of the specified user is generated as the second anomaly threshold.
[0011] By comparing the characteristic indicators of the specified user's electricity consumption data with the second abnormal threshold, the electricity consumption data of the specified user is determined to be abnormal, and the electricity consumption analysis results are obtained.
[0012] Furthermore, the generation of the electricity consumption dataset for all users specifically involves:
[0013] For the same transformer substation, the electricity metering platform is accessed via an interface to obtain the electricity consumption data of all users within the substation, generating a dataset of all user electricity consumption. The dataset includes the smart meter's profile information and error information. The smart meter's profile information includes the user number, installation date, substation number, meter reading, and location information. The error information includes the error value, error rate, and out-of-tolerance value.
[0014] Furthermore, the first electricity consumption cycle is different from the second electricity consumption cycle; the unit of the electricity consumption cycle is day, week, month, quarter or year;
[0015] The electricity consumption data characteristic indicators are any one of voltage, current, and electricity consumption.
[0016] Furthermore, the generation of average electricity consumption data characteristic indicators for all users specifically includes:
[0017] Within the first electricity consumption cycle, extract the electricity consumption data of all users within a certain electricity consumption time period from the electricity consumption dataset of all users;
[0018] Preprocess the electricity consumption data of all users within a certain electricity consumption period and delete the electricity consumption data that has been marked as abnormal;
[0019] The electricity consumption period is divided into several time units, and the electricity consumption data of each electricity user in each time unit is obtained.
[0020] The formula for integrating the electricity consumption data over several time periods is as follows:
[0021]
[0022] Where Ind represents the user's electricity consumption data characteristic index; Data i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units.
[0023] The electricity consumption data characteristic indicators for each user are accumulated and divided by the number of users to generate the average electricity consumption data characteristic indicator Ind_ave for all users.
[0024] Furthermore, the generation of electricity consumption data characteristic indicators for a specified user specifically includes:
[0025] During the second electricity consumption cycle, extract the electricity consumption data of the specified user in the same time period as the first electricity consumption period from the electricity consumption dataset of all users;
[0026] Preprocess the electricity consumption data of specified users within the same electricity consumption time period and delete the electricity consumption data that has been marked as abnormal electricity consumption;
[0027] Divide the same period of electricity consumption into several time units and obtain the electricity consumption data of a specified user in each time unit;
[0028] The electricity consumption data of a specified user over several time units is integrated using the following formula:
[0029]
[0030] Where Ind_P is the electricity consumption data characteristic indicator for the specified user; Data_P i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units.
[0031] Furthermore, the horizontal comparative analysis is performed to determine whether the electricity consumption data of the specified user is initially abnormal, specifically as follows:
[0032] Assign values to the first anomaly threshold based on the average electricity consumption data characteristics of all users.
[0033] Subtract Ind_P - Ind_ave from the power consumption data characteristic index of the specified user and the first abnormal threshold. Determine whether |Ind_P - Ind_ave| exceeds the set first abnormal threshold range: if it exceeds the first abnormal threshold range, the power consumption data of the specified user is determined to be initially abnormal; if it does not exceed the first abnormal threshold range, the power consumption data of the specified user is determined to be normal.
[0034] Furthermore, the generation of the average electricity consumption data characteristic index for a specified user as the second anomaly threshold is specifically as follows:
[0035] When a specified user is determined to have preliminary abnormal electricity consumption data, extract the electricity consumption data of the same time period as the first electricity consumption time period in the previous N periods of the specified user.
[0036] Preprocess the electricity consumption data of a specified user within the same time period in each cycle, and delete the electricity consumption data that has been marked as abnormal;
[0037] Divide the same electricity consumption period of each cycle into several time units, and obtain the electricity consumption data of a specified user in each time unit within each cycle;
[0038] The electricity consumption data for several time units within each cycle is integrated using the following formula:
[0039]
[0040] Where Ind_P′ represents the electricity consumption data characteristic index of a specified user within a certain period, and Data_P′ represents the data characteristic index of Data_P′. i This represents the electricity consumption data for the i-th time unit within a certain period, where t is the time span of the time unit.
[0041] Accumulate the electricity consumption data characteristic indicators of a specified user over the previous N periods, and divide by the number of periods N to generate the average electricity consumption data characteristic indicator Ind_Pave for the specified user;
[0042] Assign the average electricity consumption data characteristic index of the specified user to the second abnormal threshold.
[0043] Furthermore, the step of performing longitudinal comparative analysis to determine whether the electricity consumption data of a specified user is abnormal and obtaining the electricity consumption analysis results specifically involves:
[0044] Subtract Ind_P - Ind_Pave from the power consumption data characteristic index of the specified user and the second abnormal threshold. Determine whether |Ind_P - Ind_Pave| exceeds the set range of the second abnormal threshold. If it exceeds the range of the second abnormal threshold, the power consumption data of the specified user is determined to be abnormal. If it does not exceed the range of the second abnormal threshold, a manual judgment is made. If it is confirmed to be correct, the power consumption data of the specified user is determined to be normal.
[0045] On the other hand, a user power consumption anomaly analysis system based on dual comparison is provided, which is applied to the above-mentioned user power consumption anomaly analysis method based on dual comparison. It includes a dataset generation module, a threshold setting module, a first indicator generation module, a second indicator generation module, a horizontal comparison module, a third indicator generation module, and a vertical comparison module.
[0046] The dataset generation module is used to obtain the electricity consumption data of all users in the same transformer area and generate an electricity consumption dataset for all users.
[0047] The threshold setting module is used to set abnormal user electricity consumption thresholds, including a first abnormal threshold and a second abnormal threshold;
[0048] The first indicator generation module is used to extract the electricity consumption data of all users in a certain electricity consumption time period from the electricity consumption dataset of all users in the first electricity consumption cycle, and generate the average electricity consumption data feature index of all users.
[0049] The second indicator generation module is used to extract the electricity consumption data of a specified user within the same electricity consumption time period from all user electricity consumption datasets during the second electricity consumption cycle, and generate the electricity consumption data feature indicators of the specified user.
[0050] The horizontal comparison module is used to take the average electricity consumption data characteristic indicators of all users as the first abnormal threshold and perform a horizontal comparison analysis with the electricity consumption data characteristic indicators of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal.
[0051] If an initial anomaly is detected, the third indicator generation module extracts the electricity consumption data of the specified user in the same time period in the first N electricity consumption cycles from all user electricity consumption datasets, and generates the average electricity consumption data feature index of the specified user as the second anomaly threshold.
[0052] The longitudinal comparison module is used to perform longitudinal comparison analysis of the characteristic indicators of the specified user's electricity consumption data with the second abnormal threshold, and to determine whether the specified user's electricity consumption data is abnormal and obtain the electricity consumption analysis result.
[0053] In another aspect, a computer-readable storage medium is provided, storing a program, characterized in that, when the program is executed by a processor, it implements the above-mentioned user power consumption anomaly analysis method based on dual comparison.
[0054] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0055] This invention acquires user electricity consumption data, generates corresponding electricity consumption data characteristic indicators, and conducts bidirectional comparative analysis. On the one hand, it obtains preliminary abnormal electricity consumption information from horizontal comparison; on the other hand, it conducts vertical comparison based on the preliminary abnormal electricity consumption data to obtain accurate judgment results. It comprehensively considers the differences in user electricity consumption, improves the accuracy of smart meter detection and operational status evaluation, and is conducive to maintaining the safe and stable operation of smart meters. Attached Figure Description
[0056] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0057] Figure 1 This is a flowchart of the user power consumption anomaly analysis method based on dual comparison in an embodiment of the present invention;
[0058] Figure 2 This is a structural diagram of the user power consumption anomaly analysis system based on dual comparison in an embodiment of the present invention;
[0059] Figure 3 This is a schematic diagram of the structure of a computer-readable storage medium in an embodiment of the present invention. Detailed Implementation
[0060] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of the present application, and not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present application without creative effort are within the scope of protection of the present application.
[0061] In this application, the reference to "embodiment" means that a specific feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described in this application can be combined with other embodiments.
[0062] like Figure 1 As shown, this embodiment of the invention provides a user power consumption anomaly analysis method based on dual comparison, including the following steps:
[0063] S1. Obtain the electricity consumption data of all users in the same transformer area and generate an electricity consumption dataset for all users;
[0064] For the same distribution area, the system accesses the electricity metering platform via an interface to obtain the electricity consumption data of all users within that distribution area, generating a dataset of all user electricity consumption data, including the corresponding smart meter profile information and error information. The profile information includes user number, installation date, distribution area number (or distribution area name), meter reading and location information, etc.; the error information includes error value, error rate and out-of-tolerance value, etc.
[0065] S2. Set abnormal user electricity consumption thresholds, including a first abnormal threshold and a second abnormal threshold;
[0066] The first anomaly threshold is used to perform horizontal comparative analysis of abnormal electricity consumption behavior of a specified user, and to preliminarily determine whether the specified user's electricity consumption data is abnormal; the second anomaly threshold is used to perform vertical comparative analysis of abnormal electricity consumption behavior of a specified user, and to ultimately determine whether the specified user's electricity consumption data is abnormal. Through this bidirectional comparative analysis method, accurate and effective judgment of the specified user's electricity consumption data can be achieved.
[0067] S3. Within the first electricity consumption cycle, extract the electricity consumption data of all users within a certain time period from the electricity consumption dataset of all users, and generate the average electricity consumption data characteristic index of all users (denoted as the horizontal standard electricity consumption characteristic). The specific process is as follows:
[0068] S31. During the first electricity consumption cycle, extract the electricity consumption data of all users within a certain electricity consumption time period from the electricity consumption dataset of all users.
[0069] S32. Preprocess the electricity consumption data of all users within a certain electricity consumption period and delete the electricity consumption data that has been marked as abnormal electricity consumption;
[0070] S33. Divide the electricity consumption period into several time units, and obtain the electricity consumption data of each electricity user in each time unit;
[0071] S34. Integrate the electricity consumption data over several time units using the following formula:
[0072]
[0073] Where Ind represents the user's electricity consumption data characteristic index; Data i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units.
[0074] If electricity consumption E is used as a characteristic indicator of a user's electricity consumption data, then the calculation formula is:
[0075]
[0076] Among them, e i Let t represent the electricity consumption data for the i-th time unit, where t is the time span of the time unit.
[0077] S35. Accumulate the electricity consumption data characteristic indicators for each user and divide by the number of users to generate the average electricity consumption data characteristic indicator Ind_ave for all users.
[0078] S4. During the second electricity consumption cycle, extract the electricity consumption data of the specified user within the same electricity consumption time period from all user electricity consumption datasets, and generate the electricity consumption data characteristic index of the specified user (denoted as anomaly analysis electricity consumption characteristic). The specific process is as follows:
[0079] S41. During the second electricity consumption cycle, extract the electricity consumption data of the specified user in the same time period as the first electricity consumption period from the electricity consumption dataset of all users.
[0080] S42. Preprocess the electricity consumption data of the specified user within the same electricity consumption time period and delete the electricity consumption data that has been marked as abnormal electricity consumption;
[0081] S43. Divide the same electricity consumption period into several time units and obtain the electricity consumption data of the specified user in each time unit;
[0082] S44. Integrate the electricity consumption data of a specified user over several time units, using the following formula:
[0083]
[0084] Where Ind_P is the electricity consumption data characteristic indicator for the specified user; Data_P i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units.
[0085] The first and second electricity consumption cycles mentioned above are different, and the unit of the electricity consumption cycle can be a day, week, month, quarter or year, that is, a day, a month, a quarter or a year can be used as a cycle; the electricity consumption data characteristic indicators mentioned above can be any one of voltage, current and electricity consumption.
[0086] S5. Using the average electricity consumption data characteristic indicators of all users as the first anomaly threshold, conduct a horizontal comparative analysis with the electricity consumption data characteristic indicators of the specified user to determine whether the electricity consumption data of the specified user is initially abnormal. Specifically:
[0087] Assign values to the first anomaly threshold based on the average electricity consumption data characteristics of all users.
[0088] Subtract Ind_P - Ind_ave from the power consumption data characteristic index of the specified user and the first abnormal threshold. Determine whether |Ind_P - Ind_ave| exceeds the set first abnormal threshold range: if it exceeds the first abnormal threshold range, the power consumption data of the specified user is determined to be initially abnormal; if it does not exceed the first abnormal threshold range, the power consumption data of the specified user is determined to be normal.
[0089] S6. If an initial anomaly is detected, extract the electricity consumption data of the specified user within the same time period in the previous N electricity consumption cycles from all user electricity consumption datasets, and generate the average electricity consumption data characteristic index of the specified user as the second anomaly threshold. Specifically:
[0090] S61. When a specified user is determined to have preliminary abnormal electricity consumption data, extract the electricity consumption data of the same time period as the first electricity consumption time period in the first N periods of the specified user (N>3).
[0091] S62. Preprocess the electricity consumption data of the specified user in the same time period of each cycle, and delete the electricity consumption data that has been marked as abnormal electricity consumption;
[0092] S63. Divide the same electricity consumption period of each cycle into several time units, and obtain the electricity consumption data of a specified user in each time unit within each cycle;
[0093] S64. Integrate the electricity consumption data for several time units within each cycle, using the following formula:
[0094]
[0095] Where Ind_P′ represents the electricity consumption data characteristic index of a specified user within a certain period, and Data_P′ represents the data characteristic index of Data_P′. i This represents the electricity consumption data for the i-th time unit within a certain period, where t is the time span of the time unit.
[0096] S65. Accumulate the electricity consumption data characteristic indicators of the specified user for the previous N periods, and divide by the number of periods N to generate the average electricity consumption data characteristic indicator Ind_Pave of the specified user.
[0097] S66. Assign the average electricity consumption data characteristic index of the specified user to the second abnormal threshold (denoted as the longitudinal standard electricity consumption characteristic).
[0098] S7. Perform a longitudinal comparative analysis of the specified user's electricity consumption data characteristic indicators with the second abnormal threshold to determine whether the specified user's electricity consumption data is abnormal, and obtain the electricity consumption analysis results. Specifically:
[0099] Subtract Ind_P - Ind_Pave from the power consumption data characteristic index of the specified user and the second abnormal threshold. Determine whether |Ind_P - Ind_Pave| exceeds the set range of the second abnormal threshold. If it exceeds the range of the second abnormal threshold, the power consumption data of the specified user is determined to be abnormal. If it does not exceed the range of the second abnormal threshold, a manual judgment is made. If it is confirmed to be correct, the power consumption data of the specified user is determined to be normal.
[0100] This invention achieves accurate and effective analysis of abnormal electricity consumption data through bidirectional comparative analysis, first performing horizontal comparative analysis and then vertical comparative analysis. However, this invention is not limited to this; it can also employ a method of simultaneous horizontal and vertical comparison for analyzing abnormal user electricity consumption data, specifically:
[0101] When making a horizontal comparison, if Ind_P-Ind_ave is within the first abnormal threshold range, it is scored as 100 points; if it exceeds the first abnormal threshold range by 10%, it is scored as 80 points; if it exceeds the first abnormal threshold range by 20%, it is scored as 70 points; if it exceeds the first abnormal threshold range by 30%, it is scored as 70 points; if it exceeds the first abnormal threshold range by 40%, it is scored as 60 points; and if it exceeds the first abnormal threshold range by 50%, it is scored as 0 points.
[0102] When performing longitudinal comparisons, if Ind_P-Ind_Pave is within the second abnormality threshold range, it is scored as 100 points; if it exceeds the second abnormality threshold range by 10%, it is scored as 80 points; if it exceeds the second abnormality threshold range by 20%, it is scored as 70 points; if it exceeds the second abnormality threshold range by 30%, it is scored as 70 points; if it exceeds the second abnormality threshold range by 40%, it is scored as 60 points; and if it exceeds the second abnormality threshold range by 50%, it is scored as 0 points.
[0103] The scores from both horizontal and vertical comparisons are comprehensively evaluated, and the abnormal electricity consumption score for the user is determined based on a 6:4 ratio between the horizontal and vertical comparison scores.
[0104] If the final score is between 85 and 100, it is considered normal electricity use; if it is less than 85 but greater than 70, it is initially judged as abnormal, and a final conclusion will be reached after manual intervention; if the final score is less than 70, it is directly judged as abnormal.
[0105] For example, if a user's electricity consumption data characteristic index has a horizontal comparison score of 90 points and a vertical comparison score of 80 points, according to the ratio of horizontal and vertical scores, the total score is 90*60%+80*40%=86 points, which is considered normal electricity consumption data.
[0106] It should also be noted that in the longitudinal comparison, the standard deviation and variance of user electricity consumption data can be compared and analyzed with the longitudinal standard electricity consumption characteristics to obtain the fluctuation of electricity consumption and further judge the abnormal situation of user electricity consumption data. This embodiment will not elaborate on these points.
[0107] It should be noted that, for the sake of simplicity, the aforementioned method embodiments are all described as a series of actions. However, those skilled in the art should understand that the present invention is not limited to the described order of actions, because according to the present invention, some steps can be performed in other orders or simultaneously.
[0108] Based on the same idea as the user power consumption anomaly analysis method based on dual comparison in the above embodiments, the present invention also provides a user power consumption anomaly analysis system based on dual comparison, which can be used to execute the above-described user power consumption anomaly analysis method based on dual comparison. For ease of explanation, the structural schematic diagram of the user power consumption anomaly analysis system embodiment only shows the parts related to the embodiments of the present invention. Those skilled in the art will understand that the illustrated structure does not constitute a limitation on the device, and may include more or fewer components than illustrated, or combine certain components, or have different component arrangements.
[0109] like Figure 2 As shown, another embodiment of the present invention provides a user power consumption anomaly analysis system based on dual comparison, including a dataset generation module, a threshold setting module, a first indicator generation module, a second indicator generation module, a horizontal comparison module, a third indicator generation module, and a vertical comparison module.
[0110] The dataset generation module is used to obtain the electricity consumption data of all users in the same transformer area and generate an electricity consumption dataset for all users.
[0111] The threshold setting module is used to set abnormal user electricity consumption thresholds, including a first abnormal threshold and a second abnormal threshold;
[0112] The first indicator generation module is used to extract the electricity consumption data of all users within a certain electricity consumption time period from the electricity consumption dataset of all users in the first electricity consumption cycle, and generate the average electricity consumption data feature indicators of all users.
[0113] The second indicator generation module is used to extract the electricity consumption data of a specified user within the same electricity consumption time period from all user electricity consumption datasets during the second electricity consumption cycle, and generate the electricity consumption data feature indicators of the specified user.
[0114] The horizontal comparison module is used to take the average electricity consumption data characteristic indicators of all users as the first abnormal threshold and perform horizontal comparison analysis with the electricity consumption data characteristic indicators of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal.
[0115] If an initial anomaly is detected, the third indicator generation module will extract the electricity consumption data of the specified user in the same time period in the first N electricity consumption cycles from all user electricity consumption datasets, and generate the average electricity consumption data feature index of the specified user as the second anomaly threshold.
[0116] The longitudinal comparison module is used to perform longitudinal comparison analysis of the characteristic indicators of the electricity consumption data of a specified user with the second abnormal threshold, and to determine whether the electricity consumption data of the specified user is abnormal and obtain the electricity consumption analysis results.
[0117] It should be noted that the user power consumption anomaly analysis system based on dual comparison of the present invention corresponds one-to-one with the user power consumption anomaly analysis method based on dual comparison of the present invention. The technical features and beneficial effects described in the embodiments of the user power consumption anomaly analysis method based on dual comparison described above are applicable to the embodiments of the user power consumption anomaly analysis system based on dual comparison. For details, please refer to the description in the embodiments of the method of the present invention, which will not be repeated here.
[0118] Furthermore, in the above embodiments of the user power consumption anomaly analysis system based on dual comparison, the logical division of each program module is only an example. In actual applications, the above functions can be assigned to different program modules as needed, for example, for the sake of corresponding hardware configuration requirements or software implementation convenience. That is, the internal structure of the user power consumption anomaly analysis system based on dual comparison is divided into different program modules to complete all or part of the functions described above.
[0119] like Figure 3 As shown, in one embodiment, a computer-readable storage medium is provided, storing a program in a memory. When the program is executed by a processor, it implements the user power consumption anomaly analysis method based on dual comparison, specifically:
[0120] Obtain electricity consumption data for all users within the same transformer area and generate an electricity consumption dataset for all users.
[0121] Set thresholds for abnormal user electricity consumption, including a first abnormal threshold and a second abnormal threshold;
[0122] In the first electricity consumption cycle, extract the electricity consumption data of all users in a certain electricity consumption time period from the electricity consumption dataset of all users, and generate the average electricity consumption data feature index of all users; in the second electricity consumption cycle, extract the electricity consumption data of a specified user in the same electricity consumption time period from the electricity consumption dataset of all users, and generate the electricity consumption data feature index of the specified user.
[0123] The average electricity consumption data of all users is used as the first anomaly threshold. A horizontal comparative analysis is conducted with the electricity consumption data of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal.
[0124] If an initial anomaly is detected, the electricity consumption data of the specified user in the same time period during the first N electricity consumption cycles is extracted from all user electricity consumption datasets, and the average electricity consumption data feature index of the specified user is generated as the second anomaly threshold.
[0125] By comparing the characteristic indicators of the specified user's electricity consumption data with the second abnormal threshold, the electricity consumption data of the specified user is determined to be abnormal, and the electricity consumption analysis results are obtained.
[0126] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments described above. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.
[0127] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0128] The above embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above embodiments. Any changes, modifications, substitutions, combinations, or simplifications made without departing from the spirit and principle of the present invention shall be considered equivalent substitutions and shall be included within the protection scope of the present invention.
Claims
1. A user power consumption anomaly analysis method based on dual comparison, characterized in that, Includes the following steps: Obtain electricity consumption data for all users within the same transformer area and generate an electricity consumption dataset for all users. Set thresholds for abnormal user electricity consumption, including a first abnormal threshold and a second abnormal threshold; In the first electricity consumption cycle, extract the electricity consumption data of all users in a certain electricity consumption time period from the electricity consumption dataset of all users, and generate the average electricity consumption data feature index of all users; in the second electricity consumption cycle, extract the electricity consumption data of a specified user in the same electricity consumption time period from the electricity consumption dataset of all users, and generate the electricity consumption data feature index of the specified user. The average electricity consumption data of all users is used as the first anomaly threshold. A horizontal comparative analysis is conducted with the electricity consumption data of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal. If an initial anomaly is detected, the electricity consumption data of the specified user in the same time period during the first N electricity consumption cycles is extracted from all user electricity consumption datasets, and the average electricity consumption data feature index of the specified user is generated as the second anomaly threshold. The electricity consumption data characteristic indicators of the specified user are compared and analyzed longitudinally with the second abnormal threshold to determine whether the electricity consumption data of the specified user is abnormal and obtain the electricity consumption analysis results. The specific features of generating the average electricity consumption data for all users are as follows: Within the first electricity consumption cycle, extract the electricity consumption data of all users within a certain electricity consumption time period from the electricity consumption dataset of all users; Preprocess the electricity consumption data of all users within a certain electricity consumption period and delete the electricity consumption data that has been marked as abnormal; The electricity consumption period is divided into several time units, and the electricity consumption data of each electricity user in each time unit is obtained. The formula for integrating the electricity consumption data over several time periods is as follows: , Where Ind represents the user's electricity consumption data characteristic index; Data i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units. Accumulate the electricity consumption data characteristic indicators for each user and divide by the number of users to generate the average electricity consumption data characteristic indicator Ind_ave for all users; The horizontal comparative analysis is performed to determine whether the electricity consumption data of a specified user is initially abnormal. Specifically: Assign values to the first anomaly threshold based on the average electricity consumption data characteristics of all users. Subtract Ind_P-Ind_ave from the power consumption data characteristic index of the specified user and the first abnormal threshold. Determine whether |Ind_P-Ind_ave| exceeds the set first abnormal threshold range: if it exceeds the first abnormal threshold range, the power consumption data of the specified user is initially abnormal; if it does not exceed the first abnormal threshold range, the power consumption data of the specified user is normal. The average electricity consumption data characteristic index of the specified user is used as the second anomaly threshold, specifically: When a specified user is determined to have preliminary abnormal electricity consumption data, extract the electricity consumption data of the same time period as the first electricity consumption time period in the previous N periods of the specified user. Preprocess the electricity consumption data of a specified user within the same time period in each cycle, and delete the electricity consumption data that has been marked as abnormal; Divide the same electricity consumption period of each cycle into several time units, and obtain the electricity consumption data of a specified user in each time unit within each cycle; The electricity consumption data for several time units within each cycle is integrated using the following formula: , Among them, Ind_P ' For a specific user's electricity consumption data characteristics within a certain period, This represents the electricity consumption data for the i-th time unit within a certain period, where t is the time span of the time unit. Accumulate the electricity consumption data characteristic indicators of a specified user over the previous N periods, and divide by the number of periods N to generate the average electricity consumption data characteristic indicator Ind_Pave for the specified user; Assign the average electricity consumption data characteristic index of the specified user to the second anomaly threshold; The process of performing longitudinal comparative analysis to determine whether the electricity consumption data of a specified user is abnormal and obtaining the electricity consumption analysis results is as follows: Subtract Ind_P - Ind_Pave from the power consumption data characteristic index of the specified user and the second abnormal threshold. Determine whether |Ind_P - Ind_Pave| exceeds the set range of the second abnormal threshold. If it exceeds the range of the second abnormal threshold, the power consumption data of the specified user is determined to be abnormal. If it does not exceed the range of the second abnormal threshold, a manual judgment is made. If it is confirmed to be correct, the power consumption data of the specified user is determined to be normal.
2. The user electricity consumption anomaly analysis method based on dual comparison according to claim 1, characterized in that, The generation of the electricity consumption dataset for all users is specifically as follows: For the same transformer substation, the electricity metering platform is accessed via an interface to obtain the electricity consumption data of all users within the substation, generating a dataset of all user electricity consumption. The dataset includes the smart meter's profile information and error information. The smart meter's profile information includes the user number, installation date, substation number, meter reading, and location information. The error information includes the error value, error rate, and out-of-tolerance value.
3. The user electricity consumption anomaly analysis method based on dual comparison according to claim 2, characterized in that, The first electricity consumption cycle is different from the second electricity consumption cycle; the unit of the electricity consumption cycle is day, week, month, quarter or year; The electricity consumption data characteristic indicators are any one of voltage, current, and electricity consumption.
4. The user power consumption anomaly analysis method based on dual comparison according to claim 1, characterized in that, The specific steps for generating electricity consumption data characteristic indicators for a specified user are as follows: During the second electricity consumption cycle, extract the electricity consumption data of the specified user in the same time period as the first electricity consumption period from the electricity consumption dataset of all users; Preprocess the electricity consumption data of specified users within the same electricity consumption period and delete the electricity consumption data that has been marked as abnormal; Divide the same period of electricity consumption into several time units and obtain the electricity consumption data of a specified user in each time unit; The electricity consumption data of a specified user over several time units is integrated using the following formula: , Where Ind_P is the electricity consumption data characteristic indicator for the specified user; Data_P i Let t be the electricity consumption data for the i-th time unit, t be the time span of the time unit, and n be the number of time units.
5. A user power consumption anomaly analysis system based on dual comparison, characterized in that, The user electricity consumption anomaly analysis method based on dual comparison, applicable to any one of claims 1-4, includes a dataset generation module, a threshold setting module, a first indicator generation module, a second indicator generation module, a horizontal comparison module, a third indicator generation module, and a vertical comparison module; The dataset generation module is used to obtain the electricity consumption data of all users in the same transformer area and generate an electricity consumption dataset for all users. The threshold setting module is used to set abnormal user electricity consumption thresholds, including a first abnormal threshold and a second abnormal threshold; The first indicator generation module is used to extract the electricity consumption data of all users in a certain electricity consumption time period from the electricity consumption dataset of all users in the first electricity consumption cycle, and generate the average electricity consumption data feature index of all users. The second indicator generation module is used to extract the electricity consumption data of a specified user within the same electricity consumption time period from all user electricity consumption datasets during the second electricity consumption cycle, and generate the electricity consumption data feature indicators of the specified user. The horizontal comparison module is used to take the average electricity consumption data characteristic indicators of all users as the first abnormal threshold and perform a horizontal comparison analysis with the electricity consumption data characteristic indicators of a specified user to determine whether the electricity consumption data of the specified user is initially abnormal. If an initial anomaly is detected, the third indicator generation module extracts the electricity consumption data of the specified user in the same time period in the first N electricity consumption cycles from all user electricity consumption datasets, and generates the average electricity consumption data feature index of the specified user as the second anomaly threshold. The longitudinal comparison module is used to perform longitudinal comparison analysis of the characteristic indicators of the specified user's electricity consumption data with the second abnormal threshold, and to determine whether the specified user's electricity consumption data is abnormal and obtain the electricity consumption analysis result.
6. A computer-readable storage medium storing a program, characterized in that, When the program is executed by the processor, it implements the user power consumption anomaly analysis method based on dual comparison as described in any one of claims 1-4.
Citation Information
Patent Citations
Method and device for identification of abnormal electricity behavior, and central server
CN108022043A
Power consumption abnormal behavior identification method based on data driving
CN113298355A
