A method for automatically identifying abnormalities in billing parameter execution
Through big data analysis technology, the abnormal data of billing parameter execution is analyzed and classified, and the user portrait is built, which solves the problems of complex, time-consuming and error-prone execution of billing parameter execution in the existing technology, and realizes automatic identification and intelligent analysis of billing parameter execution exceptions, which improves work efficiency.
Patent Information
- Application Number
- CN202111256610.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-27
- Publication Date
- 2025-04-08
- Estimated Expiration
- 2041-10-27
AI Technical Summary
The existing technology has complex rules, large user volume and diverse power consumption in the execution of billing parameters, which leads to business personnel needing to manually select from hundreds of billing parameters, which is time-consuming and prone to errors. There is a lack of monitoring and positioning means to support abnormal identification, resulting in large management workload, low efficiency and high cost.
Big data analysis methods are used to analyze abnormal data on billing parameters. By representing abnormal user tag data as a vector, matching user basic information, and data classification and integration are carried out according to user tag library, and the overall image of the user is finally constructed and displayed.
It realizes automatic identification of abnormal billing parameters, accurately locking abnormal users, intelligently analyze the causes of abnormalities, greatly reducing the workload of personnel inspection and identification, and improving work efficiency.
Smart Images

Figure CN113988925B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of information perception and identification in the electric power industry, and relates to a method for automatically identifying abnormalities in billing parameter execution. Background Art
[0002] Billing parameters are an important manifestation of information perception and identification in the power industry. The categories of billing parameters are numerous and complex, and the billing parameters of different categories and voltage levels are different. Moreover, since billing parameters are an important means for the country to regulate the economy, different categories of billing parameters are often adjusted according to changes in economic policies in different periods.
[0003] Therefore, it is a key task for power companies to implement billing parameters in place and accurately, avoid the loss of legitimate benefits of enterprises, effectively control abnormal situations in the implementation of billing parameters, ensure the accurate and timely implementation of billing parameters, form a complete billing parameter policy supervision mechanism, promote the optimal allocation of resources, improve the billing parameter execution capability, and ensure the accuracy of electricity consumption of electricity users.
[0004] Currently, the billing parameter execution rules are complex, the user volume is large, and the electricity usage is diverse. Currently, the billing parameter execution mainly relies on business personnel to manually select from hundreds of billing parameters, which is time-consuming and prone to errors. In addition, there is a lack of monitoring, positioning and other means to support the abnormal identification of billing parameter execution, resulting in a large workload, low efficiency and high cost for daily management. Summary of the invention
[0005] In order to address the deficiencies in the prior art, the present application provides a method for automatically identifying abnormal billing parameter execution, which uses big data analysis to analyze and apply abnormal billing parameter execution data, represents abnormal user label data as a vector, matches user basic information, and classifies and integrates data based on the matching user label library, and finally constructs and displays an overall user portrait.
[0006] In order to achieve the above object, the present invention adopts the following technical solution:
[0007] A method for automatically identifying abnormalities in billing parameter execution, comprising the following steps:
[0008] Step 1: Extract the billing parameters according to the billing unit to execute the user profile data details and user electricity consumption data of the abnormal user;
[0009] Step 2: Integrate the data in step 1 with the user information to obtain detailed user information;
[0010] Step 3: According to the detailed information of the user in step 2, match the billing parameter execution standard of the power supply company, classify the billing parameter execution exception types, and build a billing parameter execution exception rule library;
[0011] Step 4: extracting various user data of abnormal billing parameter execution in the billing parameter execution abnormality rule library and analyzing and classifying them to form a billing parameter execution abnormality analysis library;
[0012] Step 5: Based on the exception analysis library and user classification, set labels for various billing parameter execution exceptions in the execution exception rule library to form a user label library;
[0013] Step 6: According to the basic information of users, match the user tag library, classify the data, and integrate the standard billing parameter information executed by similar users;
[0014] Step 7: Based on the tag library and integrated data, build an overall user portrait and display the data.
[0015] The present invention further includes the following preferred embodiments:
[0016] Preferably, in step 1, the user profile data details include user classification, energy consumption category, industry classification, pressure bearing, service location identification, capacity, pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio quantitative value, fixed ratio deduction mark, and participation in power factor calculation method;
[0017] The user electricity consumption data includes power factor assessment standards, price code industry classification, time-sharing execution mark, catalog pricing name, and price code.
[0018] Preferably, step 2 is specifically as follows: the extracted user profile is assembled with the electricity consumption agreement and the billing parameter details are integrated into user detailed information, wherein the user detailed information includes profile data: household number, household name, user classification, energy consumption category, industry classification, pressure bearing, service location identification, capacity, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio and quantitative value, fixed ratio deduction mark, and participation in power factor calculation method; electricity consumption agreement data: pricing strategy type, basic electricity fee calculation method, demand verification value, and power factor assessment method; billing parameter detail data: user execution billing parameters and billing parameter names.
[0019] Preferably, in step 3, according to the detailed information of the user in step 2, the billing parameter execution standard of the power supply company is matched, the billing parameter execution abnormality type is classified, and a billing parameter execution abnormality rule base is constructed;
[0020] The charging parameter execution exception rule base includes various types of charging parameter execution exceptions and their corresponding charging parameter execution exception rules;
[0021] The types of billing parameter execution exceptions include two-part billing parameter execution exceptions, power factor standard execution errors, time-of-use billing parameter execution errors, step billing parameter execution errors, other file execution exceptions, and energy consumption category billing parameter classification execution exceptions.
[0022] Preferably, step 5 specifically includes the following steps:
[0023] Step 5.1: Data preprocessing: extract basic user information from the anomaly analysis database, use word segmentation to segment the data, perform spelling check correction, stem extraction, word form restoration, and stop word removal;
[0024] Step 5.2: Text representation: Represent the preprocessed user basic information as a vector, represent the entire corpus as a matrix, and implement keyword extraction to obtain a set of user basic information vectors;
[0025] Step 5.3: Concatenate the word vectors of each word in the user basic information vector set into a matrix to construct a bag-of-words model;
[0026] Step 5.4: Set multiple convolutional layers on the bag-of-words model data constructed in step 5.3, extract the common information representation between different words through convolution kernels of different sizes, and calculate the feature weights;
[0027] Step 5.5: Pool the information representation generated in step 5.4, further process the feature mapping results obtained by the convolution operation, and finally obtain the abnormal recognition model for various billing parameters;
[0028] Step 5.6: Archive the abnormal recognition models for various billing parameters to form a user tag library.
[0029] Preferably, in step 5.2, the TextRank algorithm is used to represent the entire corpus as a matrix, and keyword extraction is implemented to obtain a user basic information vector set.
[0030] Preferably, in step 5.5, the information representation generated in step 5.4 is pooled using the max_pooling algorithm, and the feature mapping result obtained by the convolution operation is further processed, and finally a model for identifying abnormalities in various billing parameters is obtained.
[0031] Preferably, step 6 specifically includes the following steps:
[0032] Step 6.1: Data normalization, so that the user basic data can be matched with the user tag library;
[0033] Step 6.2: Based on the normalization result of step 6.1, perform dimensionality reduction processing on the user basic data;
[0034] Step 6.3: Information gain: Optimize the feature items of the user's basic data to improve the recognition of the basic data to the user's tag library;
[0035] Step 6.4: Classify the data obtained in step 6.3, archive the classified data, and integrate the standard billing parameter execution information of similar users.
[0036] Preferably, in step 6.1, TF*IDF normalization is performed so that the user basic data can be matched with the user tag library.
[0037] Preferably, in step 6.4, the data obtained in step 6.3 is classified using a TextCNN algorithm.
[0038] Beneficial effects achieved by this application:
[0039] The present invention integrates natural language, data caching, memory computing, cluster services and other technologies to automatically identify billing parameter anomalies. For users who can execute multiple billing parameters, intelligent analysis is used to conduct in-depth mining and analysis of billing parameter anomalies. The billing parameter execution anomaly identification rule base is used to quickly retrieve the billing parameter execution status of users in any range, accurately lock in abnormal users, and intelligently analyze the causes of billing parameter execution anomalies.
[0040] The present invention can effectively identify whether there are abnormalities in the billing parameters executed by users of various dimensions from a large number of electricity user files by analyzing the different dimensional categories and electricity usage behaviors of users, greatly reduce the workload of personnel inspection and judgment, and improve work efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 is a flow chart of the method of the present invention;
[0042] Figure 2 Construct flow charts for the billing parameter execution anomaly identification rule base and the billing parameter execution anomaly analysis base;
[0043] Figure 3 Build and apply the flow chart for abnormal user labeling system for billing parameters;
[0044] Figure 4 Schematic diagram of the structure of a convolutional neural network used in an embodiment of the present invention;
[0045] Figure 5 This is a schematic diagram of the TextCNN algorithm flow. DETAILED DESCRIPTION
[0046] The present application is further described below in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and cannot be used to limit the protection scope of the present application.
[0047] like Figure 1 As shown, a method for automatically identifying abnormalities in billing parameter execution of the present invention comprises the following steps:
[0048] Step 1: Extract the billing parameters according to the billing unit to execute the user profile data details and user electricity consumption data of the abnormal user;
[0049] The user profile data details include user classification, energy consumption category, industry classification, pressure, service location identification, capacity, pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio and fixed quantity value, fixed ratio deduction mark, participating power factor calculation method and other data;
[0050] The user electricity consumption data includes power factor assessment standards, price code industry classification, time-sharing execution mark, catalog pricing name, price code, etc.
[0051] User classification includes high voltage, low voltage non-residential, and low voltage residential.
[0052] Step 2: Integrate the data in step 1 with the user information to obtain detailed user information;
[0053] The extracted user profile and electricity consumption agreement are assembled with the billing parameter details and integrated into user detailed information.
[0054] The user detailed information includes the account number, account name, user classification, energy consumption category, industry classification, pressure, service location identification, capacity, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio quantitative value, fixed ratio deduction mark, participating power factor calculation method and other archival data;
[0055] Power consumption agreement data such as pricing strategy type, basic electricity fee calculation method, demand assessment value, power factor assessment method, etc.
[0056] The billing parameter details such as the user's execution billing parameters and billing parameter names are integrated to form user detailed information.
[0057] Step 3: According to the detailed information of the user in step 2, match the billing parameter execution standard of the power supply company, classify the billing parameter execution exception types, and build a billing parameter execution exception rule library;
[0058] The charging parameter execution exception rule base includes various types of charging parameter execution exceptions and their corresponding charging parameter execution exception rules;
[0059] The types of billing parameter execution exceptions include two-part billing parameter execution exceptions, power factor standard execution errors, time-of-use billing parameter execution errors, step billing parameter execution errors, other file execution exceptions, and energy consumption category billing parameter classification execution exceptions.
[0060] In specific implementation, examples of various billing parameter execution exceptions are as follows:
[0061] Example 1: Two-part billing parameter execution exception
[0062] According to the billing parameter policy document No. 1638 of the power supply business rules, when the user is classified as a high-voltage user, the energy consumption category is large industry, the industry classification is industrial production and repair, etc., the pressure is 10kV, the service location identification, the capacity is 315, the catalog pricing name and price code are large industrial billing parameters, such users should implement the two-part pricing strategy and calculate the basic electricity fee;
[0063] If the pricing strategy type is not a two-part system, the basic electricity fee calculation method is not calculated, and the demand verification value is 0. At this time, the user's billing parameter execution exception is summarized as a two-part billing parameter execution exception.
[0064] Example 2: Power factor standard implementation error
[0065] According to the billing parameter policy document No. 1638 of the power supply business rules, when the user is classified as high voltage, the energy category is industrial, the industry classification is industrial production, the pressure is 10kV, the capacity is below 315 and above 100, the power factor assessment method is not no assessment, the installation point is marked, the installation point use type is the electricity sales side settlement, the metering method is high supply and low metering, the energy calculation method is real copy, the participating power factor calculation method is electricity participation and electricity fee participation, the price code industry classification is industrial, the catalog pricing name and price code are general industrial and commercial electricity, the filtering factor assessment standard for such users should be 0.85;
[0066] If the power factor assessment standard is not 0.85, the abnormality in the user's billing parameters is attributed to an error in the execution of the power factor standard;
[0067] Example 3: Time-of-use billing parameter execution error
[0068] According to the provisions of Sujiadianchuan
[2003] No. 40, the peak-valley time-of-use billing parameter policy for residential electricity consumption has been piloted. When the user is classified as a low-voltage resident, the energy category is a resident, the installation point identification, and the price code industry classification is a town resident, such users will implement the residential time-of-use billing parameters;
[0069] If the catalog pricing name and price code are for urban residential electricity use, and the time-of-use flag is "no", the user's billing parameter execution abnormality is summarized as a time-of-use billing parameter execution error;
[0070] Example 4: Tiered billing parameter execution error
[0071] According to the provisions of Document No. 2617 of the Development and Reform Commission
[2011] , a trial of tiered billing parameters will be implemented for the electricity consumption of residents in the province. When the user is classified as a low-voltage resident, the energy category, the industry classification is urban residents, the pressure is 200v-380v, the installation point is marked, and the price code industry classification is urban residents, such users will implement the tiered billing parameters for residents;
[0072] If the execution time-sharing flag is yes, and the catalog pricing name and price code do not implement the tiered billing parameters, the user's abnormal execution of the billing parameters is summarized as an error in the execution of the tiered billing parameters;
[0073] Example 5: Exception in execution of other files
[0074] According to the billing parameter policy document No. 1638 of the power supply business rules, when the user is classified as high voltage, the energy consumption category is large industry, the industry classification is industrial production, the pressure is 10kV, the installation point is marked, the metering method is high supply and low metering, the energy calculation method is quantitative, the fixed ratio deduction flag is no, the installation point use type is electricity sales side settlement, and the service location is marked, such users need to calculate line losses;
[0075] When the line loss billing flag is no and the active line loss calculation value is 0 or the fixed ratio and quantity value is less than 1, the user's billing parameter execution abnormality is summarized as other file execution abnormality;
[0076] Example 6: Abnormal execution of energy consumption category billing parameter classification
[0077] According to the provisions of Su Jia Gong
[2007] No. 421, when the user is classified as low-voltage residents, the energy category is residential electricity, the industry classification is nursing home, the pressure is 1kv, the installation point is marked, and the price code industry classification is nursing home, this type of user will implement the residential billing parameters;
[0078] If the catalog pricing name and price code implement non-residential billing parameters, the user's billing parameter execution exception is summarized as an energy consumption category billing parameter classification execution exception.
[0079] Step 4: extracting various user data of abnormal billing parameter execution in the billing parameter execution abnormality rule library and analyzing and classifying them to form a billing parameter execution abnormality analysis library;
[0080] Steps 1-4 are as follows Figure 2As shown in the figure, according to the billing parameter execution policy document, the billing parameter execution influencing factors are analyzed in multiple dimensions, and the user profile information of users with abnormal billing parameter execution (user classification, energy consumption category, industry classification, pressure bearing, service location identification, capacity, pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio quantitative value, fixed ratio deduction mark, participation in power factor calculation method, etc.) and user electricity consumption data (power factor assessment standard, price code industry classification, execution time-sharing mark, catalog pricing name, price code, etc.) are extracted to build a billing parameter anomaly identification rule base and generate a billing parameter execution anomaly analysis library. The various types of billing parameter execution anomalies in the billing parameter execution anomaly rule base and their corresponding billing parameter execution anomaly rules are shown in Table 1.
[0081] Step 5: Based on the exception analysis library and user classification, set labels for various billing parameter execution exceptions in the execution exception rule library to form a user label library;
[0082] Take the error label of the execution of abnormal power factor standard execution of two-part billing parameters as an example: extract the basic information of the user from the abnormal analysis library, classify the user as a high-voltage customer, the electricity customer category is a large industrial customer, the user status is a normal electricity customer, the power receiving capacity is 315kva and above, the billing parameters executed by the electricity consumption agreement are large industrial billing parameters, and the user pricing strategy is set to a single system (non-two-part system). Such users are uniformly set with the abnormal label "The power receiving capacity is above 315kva, and the two-part system should be implemented", and a user label library is generated at the same time.
[0083] Step 5 specifically includes the following steps:
[0084] Step 5.1: Data preprocessing: extract basic user information from the anomaly analysis database, use word segmentation to segment the data, perform spelling check correction, stem extraction, word form restoration, and remove stop words;
[0085] For example, after word segmentation and stop word removal, the extracted basic information of users can be used to obtain words such as "user classification", "high-voltage customers", "electricity customer category", "large industrial customer service", "user status", "normal electricity customers", "power receiving capacity above 315kva", and "large industrial billing parameters".
[0086] Step 5.2: Text representation: Represent the preprocessed user basic information as a vector, use the TextRank algorithm to represent the entire corpus as a matrix, and implement keyword extraction to obtain a set of user basic information vectors.
[0087] For example, user basic information is a set of all possible words, and the user data position of a certain label can be found. For example, the word "high-voltage customer" is at position 208 in the vocabulary. The text matrix is a two-dimensional matrix with a dimension of [label size, word vector length]. By inputting the position of the label in the set, the word vector corresponding to the word can be obtained through the word embedding text matrix. The word vector is a vector of fixed size, and each word in the vocabulary corresponds to a different word vector.
[0088] The TextRank algorithm can be separated from the context of the corpus and can extract keywords by only analyzing the abnormal labels of the billing parameters. The TextRank algorithm is based on PageRank and is used to generate keywords and summaries for text.
[0089] PageRank was originally used to calculate the importance of tags. The entire formula can be viewed as a directed graph, with the nodes being tags. If there is data for tag A to tag B, then there is a directed edge from tag A to tag B.
[0090]
[0091] S(V i ) is the importance (PR value) of label i. d is the damping coefficient, which is generally set to 0.85. In(Vi) is the data set that points to label i. Out(V j ) is the data-oriented set of charging parameter execution exception labels in label j. |Out(V j )| is the number of elements in the set. PageRank needs to use the above formula for multiple iterations to get the result. Initially, the importance of each weight can be set to 1. The result calculated on the left side of the equal sign in the above formula is the PR value of label i after iteration, and the PR values used on the right side of the equal sign are all before iteration.
[0092] The general model of TextRank can be represented as a directed weighted graph G = (V, E), which consists of a point set V and an edge set E, where E is a subset of V × V. i ,V j The weight of the edge between them is w ji , for a given point V i ,In(V i ) is the set of points pointing to this point, Out(V i ) is point V i The set of points pointed to. Point V i The score is defined as follows:
[0093]
[0094] Furthermore, the specific example steps of using the TextRank algorithm to extract keywords and keyword groups are as follows:
[0095] 1) Split the given user data into whole sentences, that is, T = [S1, S2, ..., S i , ..., S m ];
[0096] 2) For the i-th user data S i ∈T, perform word segmentation and part-of-speech tagging on it, then remove stop words and only keep words with specified part-of-speech, such as nouns, verbs, adjectives, etc., that is, S i =[t i,1 , t i,2 ,...,t i,j , ..., t i,n ], where t i,j is the i-th user data S i The jth word retained in ;
[0097] 3) Construct a word graph G = (V, E), where V is a node set consisting of the words generated in the above steps, and then use the co-occurrence relationship to construct an edge between any two nodes: an edge exists between two nodes only if their corresponding words co-occur in a window of length K, where K represents the window size, that is, at most K words co-occur, and K is generally 2;
[0098] 4) According to the above formula, iteratively calculate the weight of each node until convergence;
[0099] 5) Sort the weights of the nodes in reverse order and obtain the most important t words as the top-t keywords;
[0100] 6) The top-t keywords obtained are marked in the original text, and if they form adjacent phrases, they are extracted as keyword groups.
[0101] 7) When extracting key sentences from a given text, each sentence in the text is considered as a node. If two sentences are similar, it is considered that there is an undirected weighted edge between the nodes corresponding to the two sentences. The formula for measuring the similarity between sentences is as follows:
[0102]
[0103] S i , S p is the data of the i-th and p-th users, w k For the words in the sentence;
[0104] The numerator means the number of the same word that appears in two sentences at the same time, and the denominator is the sum of the logarithms of the number of words in the sentences. This design can curb the advantage of longer sentences in similarity calculation.
[0105] According to the above similarity calculation formula, the similarity between any two nodes is calculated cyclically, and a threshold is set to remove the edge connections with low similarity between the two nodes to construct a node connection graph. Then, the TextRank value of each node is iteratively calculated. After sorting, the sentences corresponding to the nodes with the highest TextRank values are selected as key sentences.
[0106] Step 5.3: Concatenate the word vectors of each word in the user basic information vector set into a matrix to construct a bag-of-words model. The data structure is as shown below;
[0107]
[0108] For example: all user basic information is considered as a word set. If the word set has NN words, each text is represented as an NN-dimensional vector, with elements of 0 / 1, indicating whether the user data contains the corresponding word. For example, (0,0,0,0,....,1,...0,0,0,0).
[0109] Step 5.4: Set multiple convolutional layers on the bag-of-words model data constructed in step 5.3, extract the common information representation between different words through convolution kernels of different sizes, and calculate the feature weights.
[0110] Furthermore, the specific steps of feature weight calculation are as follows:
[0111] 1) Set the convolutional layer based on the bag-of-words model data after integrating user data
[0112] The structure of convolutional neural network (CNN) consists of input layer, convolution layer, activation function, pooling layer, and fully connected layer, namely INPUT (input layer)-CONV (convolution layer)-RELU (activation function)-POOL (pooling layer)-FC (fully connected layer). The structure is as follows Figure 4 .
[0113] 2) Feature weight calculation
[0114] Extract various types of user billing parameter execution instance sets, use the instance sets to perform billing parameter compliance analysis, and for a given user billing parameter execution instance set (i.e., training set, with more than 1,000 instances), extract the positive (billing parameter execution is correct) and negative (billing parameter execution is incorrect) features of the user billing parameter execution to form a billing parameter execution abnormal user label system weight;
[0115] Step 5.5: Based on the weight of the abnormal user label system for billing parameter execution, the information representation generated in step 5.4 is pooled using the max_pooling algorithm, and the feature mapping results obtained by the convolution operation are further processed to finally obtain various billing parameter execution abnormality recognition models;
[0116] Step 5.6: Archive the abnormal recognition models for various billing parameters to form a user tag library.
[0117] Step 6: According to the basic information of users, match the user tag library, classify the data, and integrate the standard billing parameter information executed by similar users;
[0118] Take the abnormal power factor standard execution error label of the two-part billing parameters as an example: according to the user's basic information, the users are classified as high-voltage customers, the electricity customer category is large industrial customers, the user status is normal electricity customers, the power receiving capacity is 315kva and above, and the billing parameters executed by the electricity consumption agreement are large industrial billing parameters. Match the "power receiving capacity is above 315kva, and the two-part system should be implemented" label, and the user data of the same situation are collected and classified, and the standard billing parameter information executed by such users is integrated.
[0119] Step 6 specifically includes the following steps:
[0120] Step 6.1: Through TF*IDF normalization, the user basic data can be matched with the user tag library;
[0121] TF (term frequency) refers to the number of times a given word appears in the data. This number is usually normalized (the numerator is usually smaller than the denominator to distinguish it from IDF) to prevent it from being biased towards long documents.
[0122] For example, if a word or phrase appears in the data in the library with a high frequency TF and rarely appears in other tags, it is considered that this word or phrase has good category discrimination ability and is suitable for classification.
[0123] TFIDF is actually: TF*IDF, TF term frequency, IDF inverse document frequency. The main idea of IDF is: if there are fewer documents containing term t, that is, the smaller n is, the larger the IDF is (see the subsequent formula), it means that term t has a good ability to distinguish categories. If the number of documents containing term t in a certain category of data C is m, and the total number of documents containing t in other categories is k, it is obvious that the number of all tags containing t is n=m+k. When m is large, n is also large. The IDF value obtained according to the IDF formula will be small, which means that the term t has a poor ability to distinguish categories. (Another way of saying it: IDF inverse document frequency means that the fewer documents containing the term, the larger the IDF is, which means that the term has a good ability to distinguish categories.) If a term appears frequently in the data of a class, it means that the term can well represent the characteristics of the text of this class. Such terms should be given higher weights and selected as feature words of this class of text to distinguish it from other classes of documents. The specific algorithm expression is as follows:
[0124] Boolean weight: 1 if present, 0 if not present.
[0125]
[0126] TFIDF type weighting (Boolean weighting):
[0127] TF: Term Frequency
[0128] a ij =TF ij
[0129] TF*IDF: term frequency multiplied by inverse document frequency
[0130]
[0131] TFC: TF*IDF normalization, so that words in the same text can be compared with each other
[0132]
[0133] Step 6.2: Based on the TF*IDF normalization result of step 6.1, perform dimensionality reduction processing on the user basic data;
[0134] The original feature items (terms) are scored and sorted independently according to a certain weight index, and the feature items with the highest scores are selected, and the rest are filtered out, so as to achieve the purpose of dimensionality reduction;
[0135] Step 6.3: Information gain: Optimize the feature items of the user's basic data to improve the recognition of the basic data for the user tag library.
[0136] For example, feature selection is to independently score and sort the original feature items (terms) according to the power receiving capacity index, select some feature items with higher weights, and filter out the rest of the feature items, so as to achieve the purpose of dimensionality reduction.
[0137] Based on DF, those with DF less than a certain threshold are removed (too few, not representative), and those with DF greater than a certain threshold are removed (too many, no discrimination)
[0138] Based on entropy, the larger the value, the more uniform the distribution, and the more likely it is to appear in more categories (poor discrimination); the smaller the value, the more skewed the distribution, and the word is likely to appear in fewer categories (good discrimination)
[0139]
[0140] Realize information gain, which reflects the amount of information that a term can provide for the entire classification (the difference between the entropy without considering the term and the entropy after considering the term)
[0141]
[0142] Step 6.4: Use the TextCNN algorithm to classify the data obtained in step 6.3, archive the classified data, and integrate the standard billing parameter execution information of similar users.
[0143] like Figure 5 As shown, the detailed process of TextCNN:
[0144] 1. Embedding: The first layer is the 7 by 5 sentence matrix on the left of the figure. Each row is a word vector with a dimension of 5, which can be compared to the original pixels in the image.
[0145] 2. Convolution: Then it passes through a one-dimensional convolution layer with kernel_sizes=(2,3,4), and each kernel_size has two output channels.
[0146] 3.MaxPolling: The third layer is a 1-max pooling layer, so that sentences of different lengths can be converted into fixed-length representations after passing through the pooling layer.
[0147] 4.FullConnection and Softmax: Finally, a fully connected softmax layer is added to output the probability of each category.
[0148] An example of the label library established by the present invention is shown in Table 1.
[0149] Table 1
[0150]
[0151]
[0152] Step 7: Based on the tag library and integrated data, build an overall user portrait and display the data.
[0153] Take high voltage users as an example:
[0154] If the two-part billing parameters of high-voltage users are abnormally executed and the power receiving capacity is above 315kva, the two-part label should be implemented, and the integrated user basic information should be matched. The user is classified as a high-voltage customer, the power customer category is a large industrial customer, the user status is a normal power customer, the power receiving capacity is 315kva and above, the billing parameters executed by the power consumption agreement are large industrial billing parameters, and the user pricing strategy is set to a single system (non-two-part system). Build a user summary portrait and display specific data:
[0155] It includes the management unit code, customer number, customer name, metering year and month, customer classification, energy consumption category, industry classification, pressure bearing, service location identification, service location name, capacity, pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method, installation point identification, installation point name, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio and quantity value, fixed ratio deduction mark, participation in power factor calculation method, power factor assessment standard, price code industry classification, execution time mark, catalog pricing name, price code, record date, etc.
[0156] Steps 4-7 are as follows Figure 3 As shown, the present invention sorts out the billing parameter policy execution documents of previous years, summarizes the billing parameter policy adjustment characteristics, divides electricity users into three categories according to user classification (high voltage, low voltage non-residential, low voltage residential), and combines energy consumption category, industry classification, pressure bearing, capacity, pricing strategy type, basic electricity fee calculation method, power factor assessment method, installation point identification, installation point use type, metering method, participating power factor calculation method, power factor assessment standard, price code industry classification, execution time-sharing mark and other dimensions to extract various types of user billing parameter execution instance sets, use the instance sets to perform billing parameter compliance analysis, extract user billing parameter execution abnormal characteristics, and form a billing parameter execution abnormal user tag library. According to the user's enterprise attributes, electricity usage attributes, and user billing parameter execution status, it is judged whether the user's execution of the billing parameters is wrong, and the cause of the abnormality is analyzed. Provide standard billing parameters executed by users of the same dimension for business personnel to choose.
[0157] The applicant of the present invention has made a detailed explanation and description of the implementation examples of the present invention in conjunction with the drawings in the specification. However, those skilled in the art should understand that the above implementation examples are only preferred implementation schemes of the present invention, and the detailed description is only to help readers better understand the spirit of the present invention, but not to limit the scope of protection of the present invention. On the contrary, any improvements or modifications based on the inventive spirit of the present invention should fall within the scope of protection of the present invention.
Claims
1. A method for automatically identifying abnormalities in billing parameter execution, characterized in that: The method comprises the following steps: Step 1: Extract the billing parameters according to the billing unit to execute the user profile data details and user electricity consumption data of the abnormal user; The user profile data details include user classification, energy consumption category, industry classification, pressure bearing, service location identification, capacity, pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio and fixed quantity value, fixed ratio deduction mark, and participating power factor calculation method; The user electricity consumption data includes power factor assessment standards, price code industry classification, time-sharing mark, catalog pricing name, and price code; Step 2: Integrate the data in step 1 with the user information to obtain detailed user information, specifically: assemble the extracted user files with the electricity consumption agreement and the billing parameter details, and integrate them into user detailed information. The user detailed information includes file data: household number, household name, user classification, energy consumption category, industry classification, pressure, service location identification, capacity, installation point identification, installation point use type, metering method, line loss billing mark, active line loss calculation value, energy calculation method, fixed ratio quantitative value, fixed ratio deduction mark, and participation in power factor calculation method; electricity consumption agreement data: pricing strategy type, basic electricity fee calculation method, demand verification value, power factor assessment method; billing parameter details data: user execution billing parameters, billing parameter names; Step 3: According to the detailed information of the user in step 2, match the billing parameter execution standard of the power supply company, classify the billing parameter execution exception types, and build a billing parameter execution exception rule library; In step 3, according to the detailed information of the user in step 2, the billing parameter execution standard of the power supply company is matched, the billing parameter execution abnormality type is classified, and the billing parameter execution abnormality rule base is constructed; The charging parameter execution exception rule base includes various types of charging parameter execution exceptions and their corresponding charging parameter execution exception rules; The types of abnormal billing parameter execution include abnormal execution of two-part billing parameters, power factor standard execution error, time-of-use billing parameter execution error, tiered billing parameter execution error, and energy consumption category billing parameter classification execution error; Step 4: extracting various user data of abnormal billing parameter execution in the billing parameter execution abnormality rule library and analyzing and classifying them to form a billing parameter execution abnormality analysis library; Step 5: Based on the exception analysis library and user classification, set labels for various billing parameters in the exception rule library to form a user label library, which specifically includes the following steps: Step 5.1: Data preprocessing: extract basic user information from the anomaly analysis database, use word segmentation to segment the data, perform spelling check correction, stem extraction, word form restoration, and stop word removal; Step 5.2: Text representation: Represent the preprocessed user basic information as a vector, represent the entire corpus as a matrix, and implement keyword extraction to obtain a set of user basic information vectors; In step 5.2, the TextRank algorithm is used to represent the entire corpus as a matrix, and keyword extraction is implemented to obtain a set of user basic information vectors; The specific steps for extracting keywords and keyword phrases using the TextRank algorithm are as follows: 1) Split the given user data into whole sentences, that is, T = [S1, S2, ..., S i , ..., S m ] 2) For the i-th user data S i ∈T, perform word segmentation and part-of-speech tagging, then remove stop words and keep only words with specified part-of-speech, including nouns, verbs, and adjectives, i.e. S i =[t i,1 , t i,2 , ..., t i,j , ..., t i,n ], where t i,j is the i-th user data S i The jth word retained in ; 3) Construct a word graph G = (V, E), where V is a node set consisting of the words generated in the above steps, and then use the co-occurrence relationship to construct an edge between any two nodes: an edge exists between two nodes only if their corresponding words co-occur in a window of length K, where K represents the window size, that is, at most K words co-occur, and K is 2; 4) Iteratively calculate the weight of each node until convergence; 5) Sort the weights of the nodes in reverse order and obtain the most important t words as the top-t keywords; 6) For the obtained top-t keywords, mark them in the original text, and if they form adjacent phrases, they are extracted as keyword groups; 7) When extracting key sentences from a given text, each sentence in the text is considered as a node. If two sentences are similar, it is considered that there is an undirected weighted edge between the nodes corresponding to the two sentences. The formula for measuring the similarity between sentences is as follows: S i , S p is the i-th and p-th user data, w k For the words in the sentence; In the similarity formula, the numerator is the number of words that appear in both sentences, and the denominator is the sum of the logarithms of the number of words in the sentences; Step 5.3: Concatenate the word vectors of each word in the user basic information vector set into a matrix to construct a bag-of-words model; Step 5.4: Set multiple convolutional layers on the bag-of-words model data constructed in step 5.3, extract the common information representation between different words through convolution kernels of different sizes, and calculate the feature weights; The steps for calculating feature weights are as follows: 1) Set the convolutional layer based on the bag-of-words model data after integrating user data: The structure of convolutional neural network CNN consists of input layer, convolution layer, activation function, pooling layer, and fully connected layer, that is, it consists of input layer INPUT-convolution layer CONV-activation function RELU-pooling layer POOL-fully connected layer FC; 2) Feature weight calculation: Extract various types of user billing parameter execution instance sets, use the instance sets to perform billing parameter compliance analysis, for a given user billing parameter execution instance set, i.e., training set, with more than 1,000 instances, extract the positive and negative features of user billing parameter execution, and form the weight of the billing parameter execution abnormal user label system, where the positive feature refers to the feature of correct billing parameter execution, and the negative feature refers to the feature of incorrect billing parameter execution; Step 5.5: Use the max_pooling algorithm to pool the information representation generated in step 5.4, further process the feature mapping results obtained by the convolution operation, and finally obtain the abnormal recognition model for various billing parameters; Step 5.6: Archive various billing parameter execution anomaly recognition models to form a user tag library; Step 6: According to the basic information of users, match the user tag library, classify the data, and integrate the standard billing parameter information executed by similar users, which specifically includes the following steps: Step 6.1: Normalize the data through TF*IDF to match the user basic data with the user tag library; Step 6.2: Based on the normalization result of step 6.1, perform dimensionality reduction processing on the user basic data; Step 6.3: Information gain: Optimize the feature items of the user's basic data to improve the recognition of the basic data to the user's tag library; Step 6.4: Use the TextCNN algorithm to classify the data obtained in step 6.3, archive the classified data, and integrate the standard billing parameter execution information of similar users; Step 7: Based on the tag library and integrated data, build an overall user portrait and display the data.
Citation Information
Patent Citations
Method and device for analyzing power utilization behavior of user
CN106909676A
Electricity price execution abnormal user identification method and identification system
CN111275576A