CN117495128A - Power consumption data prediction method, device, computer equipment and storage medium - Google Patents

Power consumption data prediction method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN117495128A
CN117495128A CN202311460781.8A CN202311460781A CN117495128A CN 117495128 A CN117495128 A CN 117495128A CN 202311460781 A CN202311460781 A CN 202311460781A CN 117495128 A CN117495128 A CN 117495128A
Authority
CN
China
Prior art keywords
target
time point
observation time
feature
characteristic
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311460781.8A
Other languages
Chinese (zh)
Inventor
赵少东
黄志伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Power Supply Bureau Co Ltd
Original Assignee
Shenzhen Power Supply Bureau Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Power Supply Bureau Co Ltd filed Critical Shenzhen Power Supply Bureau Co Ltd
Priority to CN202311460781.8A priority Critical patent/CN117495128A/en
Publication of CN117495128A publication Critical patent/CN117495128A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0637Strategic management or analysis, e.g. setting a goal or target of an organisation; Planning actions based on goals; Analysis or evaluation of effectiveness of goals
    • G06Q10/06375Prediction of business process outcome or impact based on a proposed change
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/06Energy or water supply

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Economics (AREA)
  • Theoretical Computer Science (AREA)
  • Strategic Management (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Marketing (AREA)
  • Health & Medical Sciences (AREA)
  • Educational Administration (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Public Health (AREA)
  • Artificial Intelligence (AREA)
  • Operations Research (AREA)
  • Development Economics (AREA)
  • Water Supply & Treatment (AREA)
  • General Health & Medical Sciences (AREA)
  • Primary Health Care (AREA)
  • Game Theory and Decision Science (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Quality & Reliability (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The present application relates to a power consumption data prediction method, apparatus, computer device, storage medium and computer program product. The method comprises the following steps: determining an importance degree characterization value of each preset feature in a plurality of preset features; selecting at least one target feature from the plurality of preset features according to the importance degree characterization value; acquiring a characteristic value set corresponding to each observation time point of a target business district in an observation time period; the characteristic value set corresponding to the observation time point comprises characteristic values of the target business district under each target characteristic at the observation time point; predicting to obtain a target electricity data sequence based on the characteristic value set corresponding to each observation time point; the target electricity data sequence comprises predicted electricity data of each observation time point of the target business circle in the observation time period. By adopting the method, the accuracy of the electricity consumption data prediction result can be improved.

Description

Power consumption data prediction method, device, computer equipment and storage medium
Technical Field
The present application relates to the field of data processing technology, and in particular, to a method, an apparatus, a computer device, a storage medium, and a computer program product for predicting power consumption data.
Background
Along with the development of social economy, the influence of the business district is gradually enlarged, so that the research on the electricity consumption condition of the business district has important significance in the aspects of power supply planning, energy management and the like, and the electricity consumption trend of the business district in the future period can be predicted according to the research result.
In the traditional method, the commonly used electricity consumption data prediction method comprises an electric power elastic coefficient method, an electric power output benefit method, a metering economy prediction method, a time sequence analysis method and the like. Taking a time series analysis method as an example, the method predicts future electricity data by substituting an appropriate time series model based on the time correlation of the historical electricity data.
However, the conventional prediction method generally predicts based on only historical electricity consumption data, and is easy to ignore the influence of external factors, so that the accuracy of the electricity consumption data prediction result is low.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a power consumption data prediction method, apparatus, computer device, computer-readable storage medium, and computer program product that are capable of improving accuracy of a power consumption data prediction result.
In a first aspect, the present application provides a method for predicting electricity usage data. The method comprises the following steps: determining an importance degree characterization value of each preset feature in a plurality of preset features; the preset characteristic is a characteristic affecting electricity consumption of the target business district; selecting at least one target feature from a plurality of preset features according to the importance degree characterization value; acquiring a characteristic value set corresponding to each observation time point of a target business district in an observation time period; the feature value set corresponding to the observation time point comprises feature values of the target business circle under each target feature at the observation time point; predicting to obtain a target electricity data sequence based on the characteristic value set corresponding to each observation time point; a target electricity usage data sequence comprising predicted electricity usage data for each observation time point of the target business circle in the observation time period.
In a second aspect, the present application further provides an electricity consumption data prediction apparatus. Comprising the following steps: the first determining module is used for determining an importance degree representation value of each preset feature in the plurality of preset features; the preset characteristic is a characteristic affecting electricity consumption of the target business district; the feature selection module is used for selecting at least one target feature from a plurality of preset features according to the importance degree characterization value; the second determining module is used for acquiring a characteristic value set corresponding to each observation time point of the target business district in the observation time period; the feature value set corresponding to the observation time point comprises feature values of the target business circle under each target feature at the observation time point; the prediction module is used for predicting and obtaining a target electricity data sequence based on the characteristic value set corresponding to each observation time point; a target electricity usage data sequence comprising predicted electricity usage data for each observation time point of the target business circle in the observation time period.
In some embodiments, the prediction module is further configured to generate, for each observation time point, feature data corresponding to the observation time point based on a set of feature values corresponding to the observation time point; according to the sequence of each observation time point in the observation time period, the characteristic data corresponding to each observation time point are arranged to obtain a characteristic data sequence; and predicting and obtaining a target electricity utilization data sequence based on the characteristic data sequence.
In some embodiments, the device further includes a model training module, configured to count power consumption data generated by each merchant in the target business district at each historical time point in the historical time period, to obtain power consumption data of each merchant in the target business district at each historical time point in the historical time period, and generate a tag power consumption data sequence; acquiring a characteristic value set corresponding to each historical time point of a target business district in a historical time period; the characteristic value set corresponding to the historical time point comprises characteristic values of the target business circle under each target characteristic at the historical time point; generating a training sample according to the characteristic value set corresponding to each historical time point; inputting the training sample into a power consumption data prediction model to be trained to obtain a predicted power consumption data sequence; predicting a power consumption data sequence, including predicted power consumption data of each historical time point of the target business circle in the historical time period; and training the power consumption data prediction model to be trained based on the difference between the predicted power consumption data sequence and the label power consumption data sequence to obtain a trained power consumption data prediction model.
In some embodiments, the model training module is further configured to generate a first decision tree model from the training sample and the plurality of target features; and taking the first decision tree model as a power consumption data prediction model to be trained.
In some embodiments, the first determining module is further configured to generate a second decision tree model according to a plurality of preset features; and determining an importance degree characterization value of each preset feature aiming at the second decision tree model.
In some embodiments, the feature selection module is further configured to arrange each preset feature according to the magnitude of the importance degree representation value, so as to obtain a preset feature sequence; at least one target feature is selected from a preset feature sequence.
In a third aspect, the present application also provides a computer device. The computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor realizes the steps in the electricity consumption data prediction method when executing the computer program.
In a fourth aspect, the present application also provides a computer-readable storage medium. The computer readable storage medium has stored thereon a computer program which, when executed by a processor, implements the steps in the electricity consumption data prediction method described above.
In a fifth aspect, the present application also provides a computer program product. The computer program product comprises a computer program which, when executed by a processor, implements the steps of the electricity consumption data prediction method described above.
The method, the device, the computer equipment, the storage medium and the computer program product for predicting the power consumption data are characterized in that the target power consumption data sequence is predicted based on the characteristic value set corresponding to each observation time point, and the characteristic value set corresponding to each observation time point comprises the characteristic value of the target business under each target characteristic when each observation time point. Therefore, the reference factors of the target electricity consumption data sequence comprise all target characteristics, and the variety of the reference factors is enriched, so that the accuracy of the electricity consumption data prediction result is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the related art, the drawings that are required to be used in the embodiments or the related technical descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to the drawings without inventive effort for a person having ordinary skill in the art.
FIG. 1 is a diagram of an application environment for a method of predicting power usage data in one embodiment;
FIG. 2 is a flow chart of a method of predicting power consumption data in one embodiment;
FIG. 3 is a flow diagram of a sequence of acquisition feature data in one embodiment;
FIG. 4 is a block diagram of an electrical data prediction device in one embodiment;
FIG. 5 is an internal block diagram of a computer device in one embodiment;
fig. 6 is an internal structural view of a computer device in another embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The electricity consumption data prediction method provided by the embodiment of the application can be applied to an application environment shown in fig. 1. Wherein the computer device 102 collects electricity usage data from the data collection device over a historical period of time. The data storage system may store data that computer device 102 needs to process. The data storage system may be integrated on the computer device 102 or may be located on a cloud or other network server.
Specifically, the computer device 102 determines a importance level characterization value for each of a plurality of preset features and selects at least one target feature based on the importance level characterization value for each of the preset features. The computer device 102 obtains a set of feature values corresponding to each observation time point of the target business in the observation time period, wherein the set of feature values corresponding to each observation time point comprises the feature values of the target business under each target feature at the observation time point. Then, based on the feature value set corresponding to each observation time point, the computer device 102 predicts and obtains the electricity consumption data of each observation time point of the target business district in the observation time period, and then obtains the target electricity consumption data sequence.
The computer device 102 may be a terminal or a server. The terminal can be, but not limited to, various personal computers, notebook computers, smart phones, tablet computers, internet of things equipment and portable wearable equipment, and the internet of things equipment can be smart speakers, smart televisions, smart air conditioners, smart vehicle-mounted equipment and the like. The portable wearable device may be a smart watch, smart bracelet, headset, or the like. The server may be implemented as a stand-alone server or as a server cluster composed of a plurality of servers.
In an exemplary embodiment, as shown in fig. 2, a method for predicting electricity data is provided, and the method is applied to the computer device 102 in fig. 1, for example, and includes the following steps 202 to 208. Wherein:
step 202, determining an importance degree characterization value of each preset feature in a plurality of preset features, wherein the preset features are features affecting electricity utilization of a target business district.
The preset characteristics are preset characteristics which can influence the electricity consumption condition of the target business district. For example, the preset feature may be, but is not limited to, a location of the business turn, an area of the business turn, or a population density around the business turn, etc. The target business is an area in a city or region where a large number of businesses, shopping, or entertainment activities are concentrated.
The importance degree representation value is a numerical value used for representing the importance of the preset feature, namely, the larger the importance degree representation value is, the larger the influence degree of the corresponding preset feature on the electricity consumption condition of the target business district is. For example, the importance level representation value may be any value ranging from 0 to 10, that is, the importance level representation value of one preset feature may be 7, the importance level representation value of another preset feature may be 8.5, and the importance level representation value of the preset feature 8.5 affects the electricity consumption condition of the target business more greatly.
Specifically, the computer device obtains a plurality of preset features, the plurality referring to at least one. According to the obtained influence degree of the preset features on the electricity consumption condition of the target business, corresponding numerical values are given to each preset feature in the preset features, and the numerical values are used as importance degree representation values of each preset feature.
In some embodiments, the preset features may be pre-stored in the computer device. The computer device may have a feature set stored therein in advance, for example, the computer device may acquire a plurality of features from the feature set as preset features.
In some embodiments, the preset feature may be manually set. The computer equipment can display a feature setting interface, a feature input area can be displayed in the feature setting interface, and the computer equipment obtains the features input into the feature input area to obtain preset features.
In some embodiments, the importance level characterization value of each preset feature may be predicted based on a model or may be manually set.
Step 204, selecting at least one target feature from a plurality of preset features according to the importance degree characterization value.
Wherein the target feature is one or more of a plurality of preset features.
Specifically, after the computer device obtains the importance degree representation value of each preset feature in the plurality of preset features, sorting each preset feature according to the importance degree representation value based on the importance degree representation value of each preset feature, wherein the larger the importance degree representation value is, the more the corresponding preset feature sequence is. And then the computer equipment can preset a target value, and a preset characteristic with the importance degree representation value being greater than or equal to the target value is selected from a plurality of preset characteristics with the ordered importance degree representation values as the target characteristic. The target value is within a range of values that characterize the value of the degree of importance.
In some embodiments, the target value may be an average value of the importance level characterization value of each preset feature, or may be a value predicted by the computer device through a model.
Step 206, obtaining a feature value set corresponding to each observation time point of the target business district in the observation time period; and the feature value set corresponding to the observation time point comprises feature values of the target business circle under each target feature at the observation time point.
Wherein the observation period is a future period of time. The observation time point is a time point included in a future period of time. For example, the future time period may be a future week or a future month from the same day, and the future time point may be each day or each hour of a future week or a future month from the same day. The feature value set is a set of feature values of the target business under each target feature when the time point is observed. The feature value is information or data corresponding to the target feature. Assuming that the target feature is the area of the business circle, the feature value of the target feature may be 1.5 ten thousand square meters. Assuming that the target feature is the location of the business turn, the feature value of the target feature may be a street number 1.
Specifically, the computer equipment acquires a characteristic value under each target characteristic corresponding to each observation point in an observation time period according to at least one selected target characteristic, processes the characteristic value under each target characteristic, and then combines the processed characteristic values under each target characteristic to obtain a characteristic value set corresponding to each observation time point in the observation time period.
In some embodiments, the computer device may perform data normalization processing on the feature values of the target feature because the feature values of the target feature are not all in numerical form. For example, when the target feature is the location of the business turn, and the location of the business turn is street 1 a, some encoding means may be employed to convert the text information into a numeric format and store it in a computer device or data storage system.
Step 208, predicting and obtaining a target electricity data sequence based on the characteristic value set corresponding to each observation time point; a target electricity usage data sequence comprising predicted electricity usage data for each observation time point of the target business circle in the observation time period.
The target electricity consumption data sequence is a sequence formed by the electricity consumption data of each observation time point in the observation time period of the predicted target business circle. The electricity data is data related to the electricity load, for example, the electricity data may be data for calculating the electricity load, or the electricity data may be the electricity load.
Specifically, the computer device may input, based on the feature value set corresponding to each observation time point in the observation time period, the feature value under each target feature in the feature value set corresponding to each observation time point into the prediction model, to obtain the power consumption data corresponding to each observation time point by the target business district. And then counting the power utilization data corresponding to each observation time point to obtain a target power utilization data sequence.
In some embodiments, the computer device may perform a power usage analysis on the power usage data over the observation period based on the predicted target power usage data sequence. For example, the computer device may construct a power usage load curve for different observation periods composed of a plurality of observation time points based on the power usage load condition of each observation time point. The computer equipment can analyze the constructed electricity load curve, can compare the electricity load curve with the electricity load curves corresponding to other time periods except the observation time period, and is favorable for making an electricity strategy aiming at the target business district in the observation time period by combining the actual situation of the target business district.
In the electricity consumption data prediction method, the target electricity consumption data sequence is predicted based on the characteristic value set corresponding to each observation time point, and the characteristic value set corresponding to each observation time point comprises the characteristic value of the target business under each target characteristic when each observation time point. Therefore, the reference factors of the target electricity consumption data sequence comprise all target characteristics, and the variety of the reference factors is enriched, so that the accuracy of the electricity consumption data prediction result is improved.
In an exemplary embodiment, as shown in FIG. 3, step 208 includes steps 302 through 306.
Wherein:
step 302, for each observation time point, generating feature data corresponding to the observation time point based on the feature value set corresponding to the observation time point.
The feature data are feature information of all target features corresponding to the target business district at the observation time point.
Specifically, the computer device may splice the feature values under each target feature in the feature value set to obtain feature data, for example, there are 2 target features, which are the area of the target business district and the population density around the target business district, and the feature value set includes feature values corresponding to the area of the target business district and the population density around the target business district. Assuming that the characteristic value corresponding to the area of the target business district is 30 ten thousand square meters, the characteristic value corresponding to the population density around the target business district is 1 ten thousand people per square kilometer, and then, the characteristic values corresponding to the area of the target business district and the population density around the target business district are spliced to obtain the characteristic data corresponding to the target business district at the observation time point.
In some embodiments, for continuous feature values, normalization may be performed first to obtain normalized feature values, and then the normalized feature values are spliced with discrete feature values in the feature value set to obtain feature data.
And step 304, arranging the characteristic data corresponding to each observation time point according to the sequence of each observation time point in the observation time period to obtain a characteristic data sequence.
The sorting refers to the position of each observation time point after each observation time point is sorted according to a specified sequence in the observation time period. The feature data sequence is a sequence in which feature data are arranged in a specified order. For example, when the observation time point is each day in the observation period and the observation time point B is on the 6 th day in the observation period, the position of the feature data corresponding to the observation time point B in the feature data sequence is also the 6 th day.
Specifically, the computer device obtains the sequence of each observation time point in the observation time period, and arranges the feature data corresponding to each observation time point according to the same sequence, so as to obtain a feature data sequence.
In some embodiments, the ordering of each observation time point in the observation period is generally arranged in chronological order.
And 306, predicting and obtaining a target electricity utilization data sequence based on the characteristic data sequence.
Specifically, the computer device may input the feature data sequence into the prediction model based on the feature data sequence, to obtain a target electricity consumption data sequence with the same target business turn and feature data sequence ordering.
In this embodiment, the feature data sequence may be obtained by generating the feature data, so as to predict the target power consumption data sequence and improve the accuracy of the power consumption data prediction result.
In some embodiments, the target electrical data sequence is predicted by a trained electrical data prediction model, the method further comprising the step of training the electrical data prediction model, the step of training the electrical data prediction model comprising: counting the electricity consumption data respectively generated by each merchant in the target business district at each historical time point in the historical time period to obtain the electricity consumption data of each historical time point in the target business district in the historical time period, and generating a tag electricity consumption data sequence; acquiring a characteristic value set corresponding to each historical time point of a target business district in a historical time period; the characteristic value set corresponding to the historical time point comprises characteristic values of the target business circle under each target characteristic at the historical time point; generating a training sample according to the characteristic value set corresponding to each historical time point; inputting the training sample into a power consumption data prediction model to be trained to obtain a predicted power consumption data sequence; predicting a power consumption data sequence, including predicted power consumption data of each historical time point of the target business circle in the historical time period; and training the power consumption data prediction model to be trained based on the difference between the predicted power consumption data sequence and the label power consumption data sequence to obtain a trained power consumption data prediction model.
The electricity consumption data prediction model is a model for predicting the electricity consumption data of the target business district in the observation time period. The merchant is a merchant in the target business, and the electricity consumption data of the merchant is contained in the electricity consumption data of the target business. The history period is a history period, and the history time point is a time point included in the history period. For example, the historical time period may be one week or one month before the current day, and the historical time point may be each day or each hour of one week or one month before the current day.
The tag electricity data sequence is a sequence of electricity data of each historical time point in the historical time period of the target business circle. Training samples are data information over a historical period of time. The training sample comprises characteristic values under each target characteristic in the characteristic value set corresponding to each historical time point.
The predicted electricity data sequence is a sequence of electricity data at each historical time point in a historical time period of a target business circle predicted by the model.
Specifically, a data acquisition device is arranged in the target business district and is used for acquiring electricity utilization data of all businesses in the target business district. The data collection device may transmit the detected electricity data to the computer device, e.g., the data collection device may directly transmit the detected electricity data to the computer device, or may forward the detected electricity data to the computer device through other devices.
In some embodiments, the computer device obtains electricity data generated by each merchant in the target business district at each historical time point in the historical time period, counts the obtained data to obtain the electricity data of each historical time point in the historical time period, and sorts the electricity data according to the arrangement sequence of each historical time point in the historical time period to generate a tag electricity data sequence. The computer equipment obtains a characteristic value set corresponding to each historical time point of the target business district in the historical time period, and generates a training sample based on the characteristic value set corresponding to each historical time point. The computer equipment inputs the generated training sample into an electricity consumption data prediction model to be trained to obtain a predicted electricity consumption data sequence. And comparing the predicted electricity consumption data sequence with the tag electricity consumption data sequence, and updating parameters of the electricity consumption data prediction model by the computer equipment according to the difference between the predicted electricity consumption data sequence and the tag electricity consumption data sequence to obtain a trained electricity consumption data prediction model.
In this embodiment, the accuracy of the electricity consumption data prediction result can be improved by training the electricity consumption data prediction model.
In some embodiments, the at least one target feature is a plurality of target features, the method further comprising: generating a first decision tree model according to the training sample and the target features; and taking the first decision tree model as a power consumption data prediction model to be trained.
Wherein the first decision tree model is a supervised learning model.
Specifically, the computer device updates the initialized decision tree model based on the generated training sample and the obtained multiple target features, and may generate a first decision tree model, and uses the obtained first decision tree model as the electricity consumption data prediction model to be trained.
In this embodiment, by generating the first decision tree model, the power consumption data prediction model to be trained can be obtained, so that accuracy of a power consumption data prediction result is improved.
In some embodiments, determining a importance level characterization value for each of a plurality of preset features includes: generating a second decision tree model according to a plurality of preset features; determining importance degree characterization values of each preset feature aiming at a second decision tree model
Wherein the second decision tree model is a supervised learning model. The second decision tree model is different from the first decision tree model.
Specifically, the computer device may train the decision tree model to be trained based on a plurality of preset features, generating a second decision tree model.
In some embodiments, the computer device ranks all of the preset features and does not filter any of the preset features. And then the computer equipment counts the electricity consumption data generated by each merchant in the target business district at each historical time point in the historical time period to obtain the electricity consumption data of each historical time point in the target business district in the historical time period. The computer device processes the electricity consumption data in a manner including, but not limited to, data cleaning, abnormal data repair, missing value reconstruction and the like. And dividing the obtained electricity consumption data into two parts, namely a training set and a testing set. For example, 90% of the power up data is randomly selected as the training set, and the remaining 10% is the test set. Thus, the computer device may build a model using a decision tree algorithm and train the decision tree model to be trained on a training set. And after training, evaluating the decision tree model by using the data of the test set to obtain the difference between the training power consumption data and the power consumption data, and updating and optimizing the trained decision tree model to obtain a second decision tree model.
In some embodiments, after the training of the second decision tree model is completed, a feature_importances attribute of the second decision tree model may generate a feature importance value of each preset feature according to a training process of the second decision tree model.
In this embodiment, by generating the second decision tree model, the importance degree characterization value of each preset feature can be obtained, so that the efficiency of electricity consumption data prediction is improved.
In some embodiments, selecting at least one target feature from a plurality of preset features according to the importance level characterization value includes: arranging all preset features according to the magnitude of the importance degree representation value to obtain a preset feature sequence; at least one target feature is selected from a preset feature sequence.
The preset feature sequence is a sequence of preset feature components arranged according to a specified order.
Specifically, the computer device obtains the importance degree representation value corresponding to each preset feature, sorts the preset features according to the importance degree representation value of each preset feature, and can obtain a preset feature sequence. In the preset feature sequence, the larger the importance degree representation value is, the more the corresponding preset feature sequence is, the smaller the importance degree representation value is, and the more the corresponding preset feature sequence is, the more the importance degree representation value is. Therefore, the computer equipment selects at least one target feature from the arranged preset feature sequence to be used for predicting the electricity consumption condition of the target business district.
In this embodiment, by arranging each preset feature, a preset feature sequence can be obtained, so that the efficiency of electricity consumption data prediction is improved.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides an electricity data prediction device for realizing the above related electricity data prediction method. The implementation of the solution provided by the apparatus is similar to the implementation described in the above method, so the specific limitation in the embodiments of the one or more power consumption data prediction apparatus provided below may be referred to the limitation of the power consumption data prediction method hereinabove, and will not be repeated here.
In an exemplary embodiment, as shown in fig. 4, there is provided an electricity consumption data prediction apparatus including: a first determination module 402, a feature selection module 404, a second determination module 406, and a prediction module 408, wherein:
a first determining module 402, configured to determine an importance level characterization value of each of a plurality of preset features; the preset characteristics are characteristics affecting electricity consumption of the target business district;
the feature selection module 404 is configured to select at least one target feature from a plurality of preset features according to the importance level characterization value;
a second determining module 406, configured to obtain a feature value set corresponding to each observation time point in the observation time period for the target business district; the feature value set corresponding to the observation time point comprises feature values of the target business circle under each target feature at the observation time point;
a prediction module 408, configured to predict and obtain a target electricity data sequence based on the feature value set corresponding to each observation time point; a target electricity usage data sequence comprising predicted electricity usage data for each observation time point of the target business circle in the observation time period.
The prediction module is further used for generating feature data corresponding to the observation time points based on the feature value set corresponding to the observation time points for each observation time point; according to the sequence of each observation time point in the observation time period, the characteristic data corresponding to each observation time point are arranged to obtain a characteristic data sequence; and predicting and obtaining a target electricity utilization data sequence based on the characteristic data sequence.
In some embodiments, the device further includes a model training module, configured to count power consumption data generated by each merchant in the target business district at each historical time point in the historical time period, to obtain power consumption data of each merchant in the target business district at each historical time point in the historical time period, and generate a tag power consumption data sequence; acquiring a characteristic value set corresponding to each historical time point of a target business district in a historical time period; the characteristic value set corresponding to the historical time point comprises characteristic values of the target business circle under each target characteristic at the historical time point; generating a training sample according to the characteristic value set corresponding to each historical time point; inputting the training sample into a power consumption data prediction model to be trained to obtain a predicted power consumption data sequence; predicting a power consumption data sequence, including predicted power consumption data of each historical time point of the target business circle in the historical time period; and training the power consumption data prediction model to be trained based on the difference between the predicted power consumption data sequence and the label power consumption data sequence to obtain a trained power consumption data prediction model.
In some embodiments, the model training module is further configured to generate a first decision tree model from the training samples and the plurality of target features; and taking the first decision tree model as a power consumption data prediction model to be trained.
In some embodiments, the first determining module is further configured to generate a second decision tree model according to a plurality of preset features; and determining an importance degree characterization value of each preset feature aiming at the second decision tree model.
In some embodiments, the feature selection module is further configured to arrange each preset feature according to the magnitude of the importance degree representation value, so as to obtain a preset feature sequence; at least one target feature is selected from a preset feature sequence.
The above-described respective modules in the electricity consumption data prediction apparatus may be implemented in whole or in part by software, hardware, and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one exemplary embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 5. The computer device includes a processor, a memory, an Input/Output interface (I/O) and a communication interface. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface is connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is for storing session data. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a method of predicting electricity usage data.
In an exemplary embodiment, a computer device, which may be a terminal, is provided, and an internal structure diagram thereof may be as shown in fig. 6. The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input means. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a method of predicting electricity usage data. The display unit of the computer device is used for forming a visual picture, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be a key, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structures shown in fig. 5 and 6 are block diagrams of only portions of structures that are relevant to the present application and are not intended to limit the computer device on which the present application may be implemented, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In an exemplary embodiment, a computer device is provided, comprising a memory and a processor, the memory having stored therein a computer program, the processor performing the steps of the method embodiments described above when the computer program is executed.
In an exemplary embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which computer program, when being executed by a processor, carries out the steps of the method embodiments described above.
In an exemplary embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the steps of the method embodiments described above.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (10)

1. A method of predicting electricity usage data, the method comprising:
determining an importance degree characterization value of each preset feature in a plurality of preset features; the preset characteristic is a characteristic affecting electricity consumption of the target business district;
selecting at least one target feature from the plurality of preset features according to the importance degree characterization value;
acquiring a characteristic value set corresponding to each observation time point of the target business district in an observation time period; the characteristic value set corresponding to the observation time point comprises characteristic values of the target business district under each target characteristic at the observation time point;
predicting to obtain a target electricity data sequence based on the characteristic value set corresponding to each observation time point; the target electricity data sequence comprises predicted electricity data of each observation time point of the target business circle in the observation time period.
2. The method according to claim 1, wherein predicting the target electricity data sequence based on the feature value set corresponding to each observation time point includes:
for each observation time point, generating feature data corresponding to the observation time point based on a feature value set corresponding to the observation time point;
according to the sequence of each observation time point in the observation time period, the characteristic data corresponding to each observation time point are arranged to obtain a characteristic data sequence;
and predicting the target electricity utilization data sequence based on the characteristic data sequence.
3. The method of claim 2, wherein the target electrical data sequence is predicted by a trained electrical data prediction model, the method further comprising the step of training an electrical data prediction model, the step of training an electrical data prediction model comprising:
counting the electricity consumption data respectively generated by each merchant in a target business district at each historical time point in a historical time period to obtain the electricity consumption data of each historical time point in the historical time period of the target business district, and generating a tag electricity consumption data sequence;
acquiring a characteristic value set corresponding to each historical time point of the target business district in the historical time period; the characteristic value set corresponding to the historical time point comprises characteristic values of the target business district under each target characteristic at the historical time point;
generating a training sample according to the characteristic value set corresponding to each historical time point;
inputting the training sample into a power consumption data prediction model to be trained to obtain a predicted power consumption data sequence; the predicted electricity consumption data sequence comprises predicted electricity consumption data of each historical time point of the target business district in the historical time period;
and training the electricity consumption data prediction model to be trained based on the difference between the predicted electricity consumption data sequence and the label electricity consumption data sequence to obtain a trained electricity consumption data prediction model.
4. The method of claim 3, wherein the at least one target feature is a plurality of target features, the method further comprising:
generating a first decision tree model according to the training sample and the target features;
and taking the first decision tree model as an electricity utilization data prediction model to be trained.
5. The method of claim 1, wherein determining a significance level characterization value for each of a plurality of preset features comprises:
generating a second decision tree model according to the plurality of preset features;
and determining an importance degree characterization value of each preset feature aiming at the second decision tree model.
6. The method of claim 1, wherein the plurality of preset features comprises at least one of a location of the target business, an area of the target business, or a population density of the periphery of the target business.
7. An electricity consumption data prediction apparatus, the apparatus comprising:
the first determining module is used for determining an importance degree representation value of each preset feature in the plurality of preset features; the preset characteristic is a characteristic affecting electricity consumption of the target business district;
the feature selection module is used for selecting at least one target feature from the plurality of preset features according to the importance degree characterization value;
the second determining module is used for acquiring a characteristic value set corresponding to each observation time point of the target business district in the observation time period; the characteristic value set corresponding to the observation time point comprises characteristic values of the target business district under each target characteristic at the observation time point;
the prediction module is used for predicting and obtaining a target electricity data sequence based on the characteristic value set corresponding to each observation time point; the target electricity data sequence comprises predicted electricity data of each observation time point of the target business circle in the observation time period.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 6 when the computer program is executed.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
10. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
CN202311460781.8A 2023-11-03 2023-11-03 Power consumption data prediction method, device, computer equipment and storage medium Pending CN117495128A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311460781.8A CN117495128A (en) 2023-11-03 2023-11-03 Power consumption data prediction method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311460781.8A CN117495128A (en) 2023-11-03 2023-11-03 Power consumption data prediction method, device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117495128A true CN117495128A (en) 2024-02-02

Family

ID=89672102

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311460781.8A Pending CN117495128A (en) 2023-11-03 2023-11-03 Power consumption data prediction method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117495128A (en)

Similar Documents

Publication Publication Date Title
CN114757457B (en) Electric carbon emission overall process monitoring method and device based on electric power big data
CN114757602B (en) Supply side electric power carbon emission risk early warning method and device and computer equipment
CN115689018A (en) Material demand prediction method, device, equipment, storage medium and program product
CN115641019A (en) Index anomaly analysis method and device, computer equipment and storage medium
CN117078480A (en) Carbon emission monitoring method, device, equipment, storage medium and computer product
CN116191398A (en) Load prediction method, load prediction device, computer equipment and storage medium
CN117495128A (en) Power consumption data prediction method, device, computer equipment and storage medium
CN115471098A (en) Carbon emission acquisition method and device, computer equipment and storage medium
CN117495131A (en) Power consumption data prediction method, device, computer equipment and storage medium
Nusawat et al. Battery discharge rate prediction model for mobile phone using data mining
CN116090629A (en) Power consumption data processing method, device, computer equipment and storage medium
CN117764529A (en) Target item determining method, device, computer equipment, storage medium and product
CN117313952A (en) Load prediction method, device, equipment and storage medium
CN117390490A (en) Method, apparatus, device, storage medium and product for generating report for telecommunication
CN116629899A (en) Grading method, grading device and computer equipment based on grid engineering ESG (electronic service guide)
CN117828327A (en) Method and device for constructing safety early warning model of power system and computer equipment
CN117436974A (en) Product recommendation method, device, computer equipment and storage medium
CN117829892A (en) Three-dimensional model supply and demand analysis method, device, computer equipment and storage medium
CN117910777A (en) Energy storage system scheduling method, device, computer equipment and storage medium
CN117540915A (en) Big data technology-based selection scheme generation method, device, equipment and medium
CN117332970A (en) Planning task management method, device, computer equipment and storage medium
CN115936789A (en) Resource numerical value change data generation method and device considering nonlinear time constant
CN116681529A (en) Trajectory data display method and device and electronic equipment
CN117520743A (en) Method, device, equipment, storage medium and product for monitoring user electricity consumption risk
CN116596398A (en) Method, apparatus, device, storage medium and program product for selecting predictive model

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination