WO2021179447A1 - 基于分布式计算的能源数据处理方法和系统 - Google Patents

基于分布式计算的能源数据处理方法和系统 Download PDF

Info

Publication number
WO2021179447A1
WO2021179447A1 PCT/CN2020/094016 CN2020094016W WO2021179447A1 WO 2021179447 A1 WO2021179447 A1 WO 2021179447A1 CN 2020094016 W CN2020094016 W CN 2020094016W WO 2021179447 A1 WO2021179447 A1 WO 2021179447A1
Authority
WO
WIPO (PCT)
Prior art keywords
minimum
maximum
data
value
dimension
Prior art date
Application number
PCT/CN2020/094016
Other languages
English (en)
French (fr)
Inventor
张立
杨少春
刘万龙
刘德强
朱传晶
张海涛
李鹏程
Original Assignee
天津市普迅电力信息技术有限公司
国网信息通信产业集团有限公司
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 天津市普迅电力信息技术有限公司, 国网信息通信产业集团有限公司 filed Critical 天津市普迅电力信息技术有限公司
Publication of WO2021179447A1 publication Critical patent/WO2021179447A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • G06F16/215Improving data quality; Data cleansing, e.g. de-duplication, removing invalid entries or correcting typographical errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries
    • G06F16/2462Approximate or statistical queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases
    • 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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • This application belongs to the field of big data processing, and in particular relates to an energy data processing method and system based on distributed computing.
  • State Grid is vigorously promoting the development of the energy Internet, accelerating the application of big data and artificial intelligence in integrated energy.
  • the table relationship is chaotic. When the tables for various businesses increase in a large amount, the relationship between the tables becomes intricate, and various related information tables are difficult to reuse, difficult to maintain in the later stage, and it seriously affects the data reading performance;
  • the front-end page cannot obtain the latest data in real time. There are two reasons for this result. One is that the relational database query takes too long, and the other is that the data is not processed in time.
  • the technical purpose of the embodiments of the present application is to overcome the above-mentioned shortcomings in the prior art, and to provide an energy data processing method and system based on distributed computing, which can effectively support the analysis and processing of large amounts of power data.
  • By collecting a large number of collected point data and using a distributed big data processing engine it is possible to quickly and accurately calculate and generate statistical data in various dimensions, find out the value needs of users, achieve the digitization of user characteristics, and form statistical data in various dimensions, so as to provide different types of users Provide "customized package" energy service to realize the intelligence of integrated energy service.
  • the embodiment of the present application provides an energy data processing method based on distributed computing, which is applied to an energy data processing system based on distributed computing, and the system includes a data acquisition system and a data processing system;
  • the data collection system collects raw data from a database, where the raw data includes at least one of enterprise information, power station information, collector information, physical collection point information, virtual collection point information, and historical power consumption data ;
  • the data processing system uses the Spark distributed computing engine to perform data cleaning on the raw data collected by the data collection system, and calculates the cleaned raw data to generate statistical data of at least one dimension.
  • the data processing system adopts the Spark distributed computing engine, and uses the cleaned raw data as the historical electricity consumption data. Based on the cleaned historical electricity consumption data, it is based on the hours, days, and months for each enterprise. , Year, physical collection point, and virtual collection point are dimensions for data statistics, and statistical results of each dimension are generated.
  • the historical electricity consumption data after cleaning is used as the basis for data statistics for each enterprise in the dimensions of hour, day, month, year, physical collection point, and virtual collection point to generate statistical results in each dimension.
  • the energy data processing system based on distributed computing further includes: a data storage system;
  • the data stored in the data storage system can be queried in real time.
  • the data collection system reads data from relational database management systems MySQL, Oracle, distributed file storage-based databases MongoDB, and relational database management system PostgreSQL, and reads data from the database connection information configured in the configuration file. Pull the original data from the corresponding data source.
  • the specific method for the above-mentioned data processing system to clean the original data is:
  • the collection point collects electricity consumption data at certain time intervals. Some data is the incremental data within the time interval, and some data is the historical cumulative data, for the cumulative data Need to calculate the incremental data in this interval;
  • the method further includes:
  • d Based on the day dimension result set of the physical collection point, using the month as the dimension, calculate the monthly cumulative value of the electricity, the maximum and minimum average of the electricity, the time point of the maximum and minimum electricity, the maximum and the minimum average of the voltage of each phase, The time when the maximum and minimum voltages of each phase appear, the minimum and average values of the maximum and minimum currents of each phase, the time when the maximum and minimum currents of each phase occur, the maximum and minimum values of total reactive power, and the maximum and minimum values of total reactive power. The time point when the value appears, the average value of the maximum value and the minimum value of the total power factor, and the time point when the minimum value and the maximum value of the total power factor appear, generate a monthly dimensional statistical result set of the physical collection point;
  • g Based on the hourly dimension result set of the virtual collection point, with the day as the dimension, calculate the cumulative value of the electric power in each day, the average of the maximum and minimum electric power, the peak and valley values of the electric power by season and time period, and the appearance time of the maximum and minimum electric power Point, the maximum value of each phase voltage, the minimum value of the average value, the time point of the maximum value and the minimum value of the voltage of each phase, the minimum value and the average value of the maximum value of each phase current, the time point of the minimum value of the maximum value of each phase current, the maximum value of total reactive power
  • the minimum and average values, the maximum and minimum values of total reactive power, the minimum and the average values of the total power factor, and the minimum and maximum values of the total power factor generate a virtual collection point day-dimensional statistical result set.
  • h Based on the result set of the day dimension of the virtual collection point, using the month as the dimension, calculate the cumulative value of the monthly electricity, the average of the maximum and minimum electricity, the time point of the minimum and maximum electricity, the average of the maximum and minimum voltages of each phase, The time when the maximum and minimum voltages of each phase appear, the minimum and average values of the maximum and minimum currents of each phase, the time when the maximum and minimum currents of each phase occur, the maximum and minimum values of total reactive power, and the maximum and minimum values of total reactive power.
  • a monthly dimension statistical result set of the virtual collection point is generated;
  • the data storage system adopts the distributed file storage system HDFS, and the data interaction adopts the native SQL query engine HAWQ SQL query engine based on HDFS.
  • the embodiment of the present application also provides an energy data processing system based on distributed computing.
  • the system includes a data acquisition system and a data processing system; wherein,
  • the data collection system is configured to collect raw data from a database, where the raw data includes at least enterprise information, power station information, collector information, physical collection point information, virtual collection point information, and historical power consumption data. At least one
  • the data processing system utilizes the Spark distributed computing engine and is configured to perform data cleaning on the raw data collected by the data collection system, perform calculations on the cleaned raw data, and generate statistical data of at least one dimension.
  • system further includes: a data storage system configured to store statistical data of the at least one dimension; the data stored in the data storage system can be queried in real time.
  • the embodiment of this application adopts a wide table structure. Enterprise information, power station information, collector information, collection point information, and electricity consumption data are integrated into one table, avoiding various association relationships that need to be considered when inquiring, and each table has a clear meaning. Avoid the problem of confusion caused by a large number of tables.
  • the embodiment of the present application adopts single-table partition storage, with unlimited data volume and scalability, while ensuring read and write performance.
  • the embodiment of the application uses Spark distributed computing to process data to ensure fast and reliable data processing.
  • the computing power can be increased by adding computing nodes, and the expansion is convenient.
  • the embodiment of the application can schedule tasks at a fixed time without human intervention, deploy once and run for a long time.
  • Fig. 1 is an implementation flowchart of an energy data processing method based on distributed computing according to an embodiment of the application.
  • FIG. 2 is a schematic diagram 1 of the composition structure of an energy data processing system based on distributed computing according to an embodiment of the application;
  • FIG. 3 is a schematic diagram 2 of the composition structure of an energy data processing system based on distributed computing according to an embodiment of the application.
  • the embodiment of the present application provides an energy data processing method based on distributed computing, and the method is applied to an energy data processing system based on distributed computing.
  • the processing system includes a data acquisition system 21, a data processing system 22 and a data storage system 23.
  • databases such as relational database management system (MySQL), Oracle, database based on distributed file storage (MongoDB), and relational database management system (PostgreSQL).
  • MySQL relational database management system
  • Oracle database based on distributed file storage
  • PostgreSQL relational database management system
  • Each database stores data according to its own inherent format.
  • the data collection system 21 can read data from databases such as MySQL, Oracle, MongoDB, and PostgreSQL, and pull original data from corresponding data sources according to the database connection information configured in the configuration file.
  • the raw data pulled mainly includes enterprise information, power station information, collector information, physical collection point information, virtual collection point information, and historical power consumption data.
  • the data processing system 22 adopts the Spark distributed computing engine based on memory.
  • the Spark distributed computing engine can directly analyze the original data, quickly and accurately calculate and generate statistical data of various dimensions, find out the value needs of users, and realize The intelligence of integrated energy service. You can also clean the original data first, analyze the cleaned data, and generate statistical data in various dimensions.
  • the engine since the Spark distributed computing engine is used, the engine uses Spark distributed computing to process data, which can ensure fast and reliable data processing, and the addition of computing nodes can increase the computing power, and the expansion is convenient. It can effectively support the analysis and processing of large-scale power data.
  • the engine uses Spark distributed computing to process data, which can ensure fast and reliable data processing, and the addition of computing nodes can increase the computing power, and the expansion is convenient. It can effectively support the analysis and processing of large-scale power data.
  • By collecting a large number of collected point data and using a distributed big data processing engine it is possible to quickly and accurately calculate and generate statistical data in various dimensions, find out the value needs of users, achieve the digitization of user characteristics, and form statistical data in various dimensions, so as to provide different types of users Provide "customized package" energy service to realize the intelligence of integrated energy service.
  • the original data is cleaned first, and the specific method of cleaning is:
  • the collection point collects the electricity consumption data at regular intervals. Some data in the collected electricity consumption data are the incremental data within the time interval, and some data are Historical cumulative data. Identify the historical cumulative data, and calculate the incremental data in the interval for the cumulative data;
  • the data storage system 23 adopts the HDFS (Hadoop Distributed File System) distributed file storage system, the data interaction adopts the HAWQ SQL (Apache Hadoop Native SQL) query engine based on HDFS, and the dimensions generated by the 22 parts of the data processing system
  • the result set is stored in HDFS, and the data stored in HDFS can be queried in real time.
  • the data stored in HDFS adopts a wide table structure, which integrates enterprise information, power station information, collector information, collection point information and electricity consumption data into one table, avoiding various association relationships that need to be considered when querying, and each table has a clear meaning , To avoid the problem of confusion caused by a large number of tables.
  • single-table partition storage is adopted, with unlimited data volume and scalability, while ensuring read and write performance.
  • the embodiment of the present application is also equipped with a task scheduling system, which implements automatic data processing through Linux Crontab to execute timing tasks.
  • the processing process is shown in the relevant content, and the repetitions are not described in detail. Scheduled tasks can be scheduled without human intervention, one-time deployment, long-term operation.
  • the Spark distributed computing engine associates enterprise information, power station information, collector information, collection point information, and electricity consumption data through the join operation of the Dataset, and integrates them into a wide table of data, and then uses mapPartitions to analyze the data in each partition Perform the processing of null values, special characters, abnormal values, and format errors and calculate the incremental value within the collection time interval to generate cleaned and integrated electricity consumption data.
  • mapPartitions to analyze the data in each partition Perform the processing of null values, special characters, abnormal values, and format errors and calculate the incremental value within the collection time interval to generate cleaned and integrated electricity consumption data.
  • the integration into a table can avoid various association relationships that need to be considered when querying, and the problem of query changing disorder.
  • the hourly dimension statistical result set of physical collection points is generated through the mapToPair, reduceByKey, and map operations of the Dataset.
  • the daily dimensional statistical result set of the physical collection point is generated through the mapPartitions, mapToPair, reduceByKey and map operations of the Dataset.
  • the monthly dimensional statistical result set of physical collection points is generated through the mapPartitionsToPair, reduceByKey and map operations of the Dataset.
  • the annual dimensional statistical result set of physical collection points is generated through the mapPartitionsToPair, reduceByKey and map operations of the Dataset.
  • a virtual collection point hourly dimension statistical result set is generated through the mapToPair, reduceByKey, mapPartitionsToPair, reduceByKey, and map operations of the Dataset.
  • the daily dimension statistical result set of the virtual collection point is generated through the mapPartitions, mapToPair, reduceByKey and map operations of the Dataset.
  • the monthly dimension statistical result set of the virtual collection point is generated through the mapPartitionsToPair, reduceByKey and map operations of the Dataset.
  • the annual dimensional statistical result set of the virtual collection point is generated through the mapPartitionsToPair, reduceByKey and map operations of the Dataset.
  • the embodiment of the present application provides an energy data processing system based on distributed computing, as shown in FIG. 2 or FIG. Oracle, MongoDB, PostgreSQL and other databases read raw data;
  • the data processing system 22 uses a memory-based Spark distributed computing engine to directly analyze the original data, quickly and accurately calculate and generate statistical data in various dimensions; the original data can also be cleaned first, and the cleaned data can be calculated , To generate statistics for each dimension.
  • the embodiment of the present application also includes a data storage system 23, which adopts the HDFS (Hadoop Distributed File System) distributed file storage system, and uses the HDFS-based HAWQ SQL (Apache Hadoop Native SQL) query engine for data interaction.
  • the result sets of each dimension generated by the data processing system 22 are all stored in HDFS, and the data stored in HDFS has the function of being queried in real time.
  • the data stored in HDFS adopts a wide table structure, which integrates enterprise information, power station information, collector information, collection point information and electricity consumption data into one table, avoiding various association relationships that need to be considered when querying, and each table has a clear meaning , To avoid the problem of confusion caused by a large number of tables.
  • single-table partition storage is adopted, with unlimited data volume and scalability, while ensuring read and write performance.
  • An embodiment of the present application provides a computer storage medium in which computer-executable instructions are stored, and the computer-executable instructions are used to execute the aforementioned energy data processing method based on distributed computing.
  • the storage medium of the embodiment of the present application includes volatile random access memory (RAM), read only memory (ROM), electrically erasable programmable read only memory (EEPROM), flash memory or other memory technologies, and read-only optical disk (CD-ROM). ROM), Digital Versatile Disk (DVD) or other media being accessed.
  • this application can be provided as methods, systems, or computer program products. Therefore, this application may adopt the form of hardware embodiments, software embodiments, or embodiments combining software and hardware. Moreover, this application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, optical storage, etc.) containing computer-usable program codes.
  • These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing equipment to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction device.
  • the device implements the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
  • These computer program instructions can also be loaded on a computer or other programmable data processing equipment, so that a series of operation steps are executed on the computer or other programmable equipment to produce computer-implemented processing, so as to execute on the computer or other programmable equipment.
  • the instructions provide steps for implementing the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
  • the engine since the Spark distributed computing engine is used, the engine uses Spark distributed computing to process data, which can ensure fast and reliable data processing.
  • the addition of computing nodes can increase the computing power, and the expansion is convenient. It can effectively support the analysis and processing of large-scale power data.
  • By collecting a large number of collected point data and using a distributed big data processing engine it is possible to quickly and accurately calculate and generate statistical data in various dimensions, find out the value needs of users, achieve the digitization of user characteristics, and form statistical data in various dimensions, so as to provide different types of users Provide "customized package" energy service to realize the intelligence of integrated energy service.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Economics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Mathematical Physics (AREA)
  • Fuzzy Systems (AREA)
  • Quality & Reliability (AREA)
  • Public Health (AREA)
  • Water Supply & Treatment (AREA)
  • Software Systems (AREA)
  • Human Resources & Organizations (AREA)
  • Marketing (AREA)
  • Primary Health Care (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

一种基于分布式计算的能源数据自动化处理方法和系统,包括数据采集系统(21)、和数据处理系统(22);其中,所述方法包括:所述数据采集系统(21)从数据库中采集原始数据,其中,所述原始数据至少包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息和历史用电数据中的至少一种;所述数据处理系统(22)利用Spark分布式计算引擎,配置为对所述数据采集系统(21)采集的原始数据进行数据清洗,对清洗后的原始数据进行计算,生成至少一个维度的统计数据。

Description

基于分布式计算的能源数据处理方法和系统
相关申请的交叉引用
本申请基于申请号为202010161552.6、申请日为2020年03月10日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此以引入方式并入本申请。
技术领域
本申请属于大数据处理领域,特别涉及一种基于分布式计算的能源数据处理方法和系统。
背景技术
随着信息化的发展,国家电网正在大力推进能源互联网的发展,加速大数据、人工智能在综合能源方面的应用。
目前国家电网大部分信息化系统采用传统的关系型数据库,数据处理采用数据库存储过程或编程实现,该种实现方案在早期数据量不大、实时性要求不高的情况下基本可以满足需求,但随着用能数据大量增加,现有方案已经逐渐无法满足业务需求,主要体现在如下方面:
1、表数量过多,需要存储的各种信息如企业信息、用户信息、采集点信息、用电数据等等都单独成表,还有涉及各表关系的关联信息表,随着电力业务的发展,会新增各种新业务,针对各种业务的数据还需要增加独立的表结构进行存储,表数量过多,难于管理和维护;
2、表关系混乱,当针对各种业务的表大量增加时,表之间的关联关系变得错综复杂,各种关联信息表难以重用,后期难以维护,同时严重影响数据的读取性能;
3、数据量达到TB(万亿字节)级别时,关系型数据库单表无法存储;关系型数据库单表在数据量低于一定水平的情况下,读写性能在毫秒级别,完全满足需求,但高于一定水平之后,读写性能会严重下降,查询数据耗时会达到分钟级别,对于前端数据展示来说无法接受。
4、采用存储过程或编程的方式实现数据处理在数据量小的情况下能够满足需求,但随着数据量增大,该种方式已经无法在可接受时间范围内完成数据处理,甚至可能会由于数据量过大计算机资源不足直接导致处理程序崩溃。
5、前端页面无法实时获取最新数据,造成这种结果的原因存在两个方面,一是关系型数据库查询耗时过长,二是数据处理不及时。
发明内容
本申请实施例的技术目的就在于克服上述现有技术中存在的不足,而提供一种基于分布式计算的能源数据处理方法和系统,该处理方法可有效支撑大数据量电力数据分析处理。通过采集大量采集点数据且采用分布式大数据处理引擎,可以快速准确地计算生成各维度统计数据,找出用户的价值需求,达到用户特征数字化,形成各维度统计数据,从而为不同类别的用户提供“定制化套餐”的用能服务,实现综合用能服务的智能化。
如上构思,本申请实施例的技术方案是:
本申请实施例提供一种基于分布式计算的能源数据处理方法,应用于基于分布式计算的能源数据处理系统中,该系统包括数据采集系统、和数据处理系统;
所述数据采集系统从数据库中采集原始数据,其中,所述原始数据至少包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息和历史用电数据中的至少一种;
所述数据处理系统利用Spark分布式计算引擎对所述数据采集系统采 集的原始数据进行数据清洗,对清洗后的原始数据进行计算,生成至少一个维度的统计数据。
在前述方案中,所述数据处理系统采用Spark分布式计算引擎,将清洗后的原始数据作为历史用电数据,以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点为维度进行数据统计,生成各维度的统计结果。
在前述方案中,所述以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点为维度进行数据统计生成各维度的统计结果,包括以下操作:①基于历史用电数据,以小时和物理采集点为维度,生成物理采集点小时维度统计结果集;②基于历史用电数据,以企业为维度,计算各个企业下所有物理采集点在每个采集时间点上的电量累加值、一天之内电量最大值最小值及一天之内电量最大值最小值出现时间点;③基于物理采集点小时维度统计结果集,以天为维度,生成物理采集点天维度统计结果集;④基于物理采集点天维度结果集,以月为维度,生成物理采集点月维度统计结果集;⑤基于物理采集点月维度结果集,以年为维度,生成物理采集点年维度统计结果集;⑥基于历史用电数据,按设备属性或区域属性划分物理采集点并以四则运算公式将具有相同属性的物理采集点表达为虚拟采集点,以小时和虚拟采集点为维度,生成虚拟采集点小时维度统计结果集;⑦基于虚拟采集点小时维度结果集,以天为维度,生成虚拟采集点天维度统计结果集;⑧基于虚拟采集点天维度结果集,以月为维度,生成虚拟采集点月维度统计结果集;⑨基于虚拟采集点月维度结果集,以年为维度,生成虚拟采集点年维度统计结果集。
在前述方案中,所述基于分布式计算的能源数据处理系统还包括:数据存储系统;
将生成的所述至少一个维度的统计数据存储至所述数据存储系统;
存储在所述数据存储系统的数据能够被实时查询。
在前述方案中,所述数据采集系统从关系型数据库管理系统MySQL、Oracle、基于分布式文件存储的数据库MongoDB及关系型数据库管理系统PostgreSQL读取数据,根据配置文件中配置的数据库连接信息,从相应的数据源中拉取原始数据。
在一个可选的方案中,上述数据处理系统对所述各原始数据进行清洗的具体方法是:
①对各原始数据中的空值、特殊字符、非正常值、格式错误的数据分别进行处理:空值及非正常值数据取近三天数据的平均值;对包含非法字符及格式错误的数据进行过滤处理;
②计算各个采集时间段内的增量数据,采集点每隔一定时间间隔采集一次用电数据,有的数据为该时间间隔内的增量数据,有的数据则为历史累计数据,针对累计数据需要计算出该间隔内的增量数据;
③整合企业信息、电能站信息、采集器信息、采集点信息及用电数据作为清洗后的历史用电数据;
④以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点点为维度进行数据统计。
在前述方案中,所述方法还包括:
a.基于历史用电数据,以小时和物理采集点为维度,计算各个物理采集点每小时内电量累计值、电量最大值和最小值平均值、电量最大值和最小值出现的时间点、各相电压整点瞬时值、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值和最小值的平均值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值平均值、总功率 因数最大值最小值出现时间点,生成物理采集点小时维度统计结果集;
b,基于历史用电数据,以企业为维度,计算各个企业下所有物理采集点在每个采集时间点上的电量累加值、一天之内电量最大值最小值及一天之内电量最大值最小值出现时间点;
c,基于物理采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点天维度统计结果集;
d,基于物理采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点月维度统计结果集;
e,基于物理采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点年维度统计结果集;
f,基于历史用电数据,按设备属性或区域属性划分物理采集点并以四则运算公式将具有相同属性的物理采集点表达为虚拟采集点,计算出各个企业下所有虚拟采集点每小时内电量累计值、电量最大值最小值、电量最大值最小值出现时间点、各相电压整点瞬时值、各相电压最大值最小值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大值最小值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值最小值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值、总功率因数最大值最小值出现时间点,生成虚拟采集点小时维度统计结果集;
g,基于虚拟采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点天维度统计结果集。
h,基于虚拟采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点月维度统计结果集;
i,基于虚拟采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大 值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点年维度统计结果集。
在前述方案中,所述数据存储系统采用分布式文件存储系统HDFS,数据交互采用基于HDFS的原生SQL查询引擎HAWQ SQL查询引擎。
本申请实施例还提供一种基于分布式计算的能源数据处理系统,所述系统包括数据采集系统、和数据处理系统;其中,
所述数据采集系统,配置为从数据库中采集原始数据,其中,所述原始数据至少包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息和历史用电数据中的至少一种;
所述数据处理系统利用Spark分布式计算引擎,配置为对所述数据采集系统采集的原始数据进行数据清洗,对清洗后的原始数据进行计算,生成至少一个维度的统计数据。
其中,所述系统还包括:数据存储系统,配置为存储所述至少一个维度的统计数据;存储在所述数据存储系统的数据能够被实时查询。
本申请实施例具有如下的优点和积极效果:
1、本申请实施例采用宽表结构,企业信息、电能站信息、采集器信息、采集点信息及用电数据整合到一张表中,避免查询时需要考虑的各种关联关系,各表意义明确,避免大量表导致混乱的问题。
2、本申请实施例采用单表分区存储,数据量无限制,可扩展,同时保证读写性能。
3、本申请实施例采用Spark分布式计算处理数据,保证数据处理快速可靠,增加计算节点即可增加计算能力,扩展便捷。
4、本申请实施例可定时任务调度,无需人为介入,一次部署,长期运行。
附图说明
图1为本申请实施例的基于分布式计算的能源数据处理方法的实现流程图。
图2为本申请实施例的基于分布式计算的能源数据处理系统的组成结构示意图一;
图3为本申请实施例的基于分布式计算的能源数据处理系统的组成结构示意图二。
具体实施方式
本申请实施例提供一种基于分布式计算的能源数据处理方法,该方法应用于基于分布式计算的能源数据处理系统中。如图2和图3所示,从组成上来看,该处理系统包括数据采集系统21、数据处理系统22和数据存储系统23。
一、本申请实施例中提供多种类型的数据库,如关系型数据库管理系统(MySQL)、Oracle、基于分布式文件存储的数据库(MongoDB)及关系型数据库管理系统(PostgreSQL)。每种数据库按照自身固有的格式进行数据的存储。所述数据采集系统21可从MySQL、Oracle、MongoDB及Post greSQL等数据库读取数据,根据配置文件中配置的数据库连接信息,从相应的数据源中拉取原始数据。所拉取的原始数据主要包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息及历史用电数据。
二、所述数据处理系统22采用基于内存的Spark分布式计算引擎,Spark分布式计算引擎可直接对原始数据进行分析,快速准确地计算并生成各维度统计数据,找出用户的价值需求,实现综合用能服务的智能化。还 可以先对原始数据进行清洗,针对清洗后的数据进行分析,生成各维度的统计数据。
本申请实施例中,由于采用了Spark分布式计算引擎,该引擎采用Spark分布式计算处理数据,可保证数据处理快速可靠,增加计算节点即可增加计算能力,扩展便捷。可有效支撑大数据量电力数据分析处理。通过采集大量采集点数据且采用分布式大数据处理引擎,可以快速准确地计算生成各维度统计数据,找出用户的价值需求,达到用户特征数字化,形成各维度统计数据,从而为不同类别的用户提供“定制化套餐”的用能服务,实现综合用能服务的智能化。
对所述各原始数据首先进行清洗,清洗的具体方法是:
①对各原始数据中的空值、特殊字符、非正常值、格式错误的数据分别进行处理:其中,对空值及非正常值数据取近三天数据的平均值;对包含非法字符及格式错误的数据进行过滤处理;
②计算各个采集时间段内的增量数据,采集点每隔一定时间间隔采集一次用电数据,在采集的用电数据中有的数据为该时间间隔内的增量数据,有的数据则为历史累计数据。识别出历史累计数据,针对累计数据需要计算出该间隔内的增量数据;
③整合企业信息、电能站信息、采集器信息、采集点信息及用电数据作为清洗后的历史用电数据;
④以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点点为维度进行数据统计:
a、基于历史用电数据,以小时和物理采集点为维度,计算各个物理采集点每小时内电量累计值、电量最大值和最小值平均值、电量最大值和最小值出现的时间点、各相电压整点瞬时值、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大 值最小值平均值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值和最小值的平均值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点小时维度统计结果集;
b、基于历史用电数据,以企业为维度,计算各个企业下所有物理采集点在每个采集时间点上的电量累加值、一天之内电量最大值最小值及一天之内电量最大值最小值出现时间点;
c、基于物理采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点天维度统计结果集;
d、基于物理采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点月维度统计结果集;
e、基于物理采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小 值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点年维度统计结果集;
f、基于历史用电数据,按设备属性或区域属性划分物理采集点并以四则运算公式将具有相同属性的物理采集点表达为虚拟采集点,计算出各个企业下所有虚拟采集点每小时内电量累计值、电量最大值最小值、电量最大值最小值出现时间点、各相电压整点瞬时值、各相电压最大值最小值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大值最小值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值最小值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值、总功率因数最大值最小值出现时间点,生成虚拟采集点小时维度统计结果集;
g、基于虚拟采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点天维度统计结果集;
h、基于虚拟采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点月维度 统计结果集;
i、基于虚拟采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点年维度统计结果集。
三、所述数据存储系统23采用HDFS(Hadoop Distributed File System)分布式文件存储系统,数据交互采用基于HDFS的HAWQ SQL(Apache Hadoop Native SQL)查询引擎,所述数据处理系统22部分生成的各维度结果集均保存在HDFS中,存储在HDFS中的数据具有可被实时查询的功能。存储在HDFS中的数据采用宽表结构,将企业信息、电能站信息、采集器信息、采集点信息及用电数据整合到一张表中,避免查询时需要考虑的各种关联关系,各表意义明确,避免大量表导致混乱的问题。此外,采用单表分区存储,数据量无限制,可扩展,同时保证读写性能。
三、本申请实施例还配有任务调度系统,该系统通过Linux Crontab执行定时任务的方式,实现数据的自动化处理,处理过程如相关内容所示,重复之处不做具体赘述。可定时任务调度,无需人为介入,一次部署,长期运行。
参见附图1,本申请实施例数据处理流程的具体步骤如下:
(1)首先读取存放于固定路径下的配置文件中数据库连接信息,包括网际协议地址ip、用户名userName、密码password、数据源database,然后通过JDBC(数据库一种连接)方式读取各数据源数据,转换成Spark内部Dataset对象。
(2)Spark分布式计算引擎通过Dataset的join操作将企业信息、电能站信息、采集器信息、采集点信息及用电数据关联,整合为一条宽表数据,然后通过mapPartitions对各个分区内的数据进行空值、特殊字符、非正常值、格式错误的处理并计算采集时间间隔内的增量值,生成清洗和整合后的用电数据。其中,整合到一张表中,能够避免查询时需要考虑的各种关联关系,查询换乱的问题。
(3)基于清洗和整合后的用电数据,通过Dataset的mapToPair、reduceByKey及map操作生成物理采集点小时维度统计结果集。
(4)基于清洗和整合后的用电数据,通过Dataset的mapToPair、reduceByKey、mapPartitionsToPair、reduceByKey及map操作生成物理采集点企业维度统计结果集。
(5)基于物理采集点小时维度统计结果集,通过Dataset的mapPartitions、mapToPair、reduceByKey及map操作生成物理采集点天维度统计结果集。
(6)基于物理采集点天维度统计结果集,通过Dataset的mapPartitionsToPair、reduceByKey及map操作生成物理采集点月维度统计结果集。
(7)基于物理采集点月维度统计结果集,通过Dataset的mapPartitionsToPair、reduceByKey及map操作生成物理采集点年维度统计结果集。
(8)基于清洗和整合后的用电数据,通过Dataset的mapToPair、reduceByKey、mapPartitionsToPair、reduceByKey及map操作生成虚拟采集点小时维度统计结果集。
(9)基于虚拟采集点小时维度统计结果集,通过Dataset的mapPartitions、mapToPair、reduceByKey及map操作生成虚拟采集点天维 度统计结果集。
(10)基于虚拟采集点天维度统计结果集,通过Dataset的mapPartitionsToPair、reduceByKey及map操作生成虚拟采集点月维度统计结果集。
(11)基于虚拟采集点月维度统计结果集,通过Dataset的mapPartitionsToPair、reduceByKey及map操作生成虚拟采集点年维度统计结果集。
(12)通过调用Spark分布式计算引擎的JDBCWriter及分布式系统基础架构(Hadoop)原生SQL查询引擎HAWQ提供的JDBC接口将以上生成的各维度结果集写入HDFS进行存储。
(13)将Spark处理程序打成任务压缩Jar包,并配置(嵌入式任务调度)Linux Crontab定时提交任务Jar包到Spark集群,执行数据处理。
本申请实施例提供一种基于分布式计算的能源数据处理系统,如图2或图3所示,包括:数据采集系统21和数据处理系统22;其中,所述数据采集系统21可从MySQL、Oracle、MongoDB及PostgreSQL等数据库读取原始数据;
所述数据处理系统22采用基于内存的Spark分布式计算引擎,直接对原始数据进行分析,快速准确地计算并生成各维度统计数据;还可先对原始数据进行清洗,对清洗后的数据进行计算,生成各维度统计数据。
如图3所示,本申请实施例中还包括数据存储系统23,采用HDFS(Hadoop Distributed File System)分布式文件存储系统,数据交互采用基于HDFS的HAWQ SQL(Apache Hadoop Native SQL)查询引擎,所述数据处理系统22部分生成的各维度结果集均保存在HDFS中,存储在HDFS中的数据具有可被实时查询的功能。存储在HDFS中的数据采用宽表结构,将企业信息、电能站信息、采集器信息、采集点信息及用电数据整合到一张表 中,避免查询时需要考虑的各种关联关系,各表意义明确,避免大量表导致混乱的问题。此外,采用单表分区存储,数据量无限制,可扩展,同时保证读写性能。
本申请实施例提供一种计算机存储介质,所述计算机存储介质中存储有计算机可执行指令,所述计算机可执行指令用于执行前述的基于分布式计算的能源数据处理方法。本申请实施例的存储介质包括易挥发性随机存取存储器(RAM)、只读存储器(ROM)、电可擦可编程只读存储器(EEPROM)、闪存或其他存储器技术、只读光盘(CD-ROM)、数字通用盘(DVD)或其他被访问的他介质。
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用硬件实施例、软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个 流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。
以上所述,仅为本申请的较佳实施例而已,并非用于限定本申请的保护范围。
工业实用性
本申请实施例中,由于采用了Spark分布式计算引擎,该引擎采用Spark分布式计算处理数据,可保证数据处理快速可靠,增加计算节点即可增加计算能力,扩展便捷。可有效支撑大数据量电力数据分析处理。通过采集大量采集点数据且采用分布式大数据处理引擎,可以快速准确地计算生成各维度统计数据,找出用户的价值需求,达到用户特征数字化,形成各维度统计数据,从而为不同类别的用户提供“定制化套餐”的用能服务,实现综合用能服务的智能化。

Claims (10)

  1. 一种基于分布式计算的能源数据处理方法,应用于基于分布式计算的能源数据处理系统中,所述系统包括数据采集系统、和数据处理系统;其中,
    所述数据采集系统从数据库中采集原始数据,其中,所述原始数据至少包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息和历史用电数据中的至少一种;
    所述数据处理系统利用Spark分布式计算引擎对所述数据采集系统采集的原始数据进行数据清洗,对清洗后的原始数据进行计算,生成至少一个维度的统计数据。
  2. 根据权利要求1所述的方法,其中,
    所述数据处理系统采用Spark分布式计算引擎,将清洗后的原始数据作为历史用电数据,以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点为维度进行数据统计,生成各维度的统计结果。
  3. 根据权利要求2所述的方法,其中,所述数据处理系统利用Spark分布式计算引擎对所述数据采集系统采集的原始数据进行数据清洗,包括:
    ①对各原始数据中的空值、特殊字符、非正常值、格式错误的数据分别进行处理:其中,对空值及非正常值数据取近三天数据的平均值;对包含非法字符及格式错误的数据进行过滤处理;
    ②计算各个采集时间段内的增量数据,采集点每隔一定时间间隔采集一次用电数据,识别该时间间隔内的增量数据和历史累计数据,针对累计数据需要计算出该间隔内的增量数据;
    ③整合企业信息、电能站信息、采集器信息、采集点信息及用电数据作为清洗后的历史用电数据;
    ④以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点为维度进行数据统计,生成各维度的统计结果。
  4. 根据权利要求3所述的方法,其中,所述以清洗后的历史用电数据为基础,针对各个企业,以小时、天、月、年、物理采集点、虚拟采集点为维度进行数据统计生成各维度的统计结果,包括以下操作:
    ①基于历史用电数据,以小时和物理采集点为维度,生成物理采集点小时维度统计结果集;②基于历史用电数据,以企业为维度,计算各个企业下所有物理采集点在每个采集时间点上的电量累加值、一天之内电量最大值最小值及一天之内电量最大值最小值出现时间点;③基于物理采集点小时维度统计结果集,以天为维度,生成物理采集点天维度统计结果集;④基于物理采集点天维度结果集,以月为维度,生成物理采集点月维度统计结果集;⑤基于物理采集点月维度结果集,以年为维度,生成物理采集点年维度统计结果集;⑥基于历史用电数据,按设备属性或区域属性划分物理采集点并以四则运算公式将具有相同属性的物理采集点表达为虚拟采集点,以小时和虚拟采集点为维度,生成虚拟采集点小时维度统计结果集;⑦基于虚拟采集点小时维度结果集,以天为维度,生成虚拟采集点天维度统计结果集;⑧基于虚拟采集点天维度结果集,以月为维度,生成虚拟采集点月维度统计结果集;⑨基于虚拟采集点月维度结果集,以年为维度,生成虚拟采集点年维度统计结果集。
  5. 根据权利要求1至4任一项所述的方法,其中,所述基于分布式计算的能源数据处理系统还包括:数据存储系统;
    将生成的所述至少一个维度的统计数据存储至所述数据存储系统;
    存储在所述数据存储系统的数据能够被实时查询。
  6. 根据权利要求5所述的方法,其特征在于:所述数据采集系统从关 系型数据库管理系统MySQL、Oracle、基于分布式文件存储的数据库Mon goDB及关系型数据库管理系统PostgreSQL读取数据,根据配置文件中配置的数据库连接信息,从相应的数据源中拉取原始数据。
  7. 根据权利要求4所述的方法,其中,所述方法还包括:
    a.基于历史用电数据,以小时和物理采集点为维度,计算各个物理采集点每小时内电量累计值、电量最大值和最小值平均值、电量最大值和最小值出现的时间点、各相电压整点瞬时值、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值和最小值的平均值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点小时维度统计结果集;
    b、基于历史用电数据,以企业为维度,计算各个企业下所有物理采集点在每个采集时间点上的电量累加值、一天之内电量最大值最小值及一天之内电量最大值最小值出现时间点;
    c、基于物理采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点天维度统计结果集;
    d、基于物理采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最 小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点月维度统计结果集;
    e、基于物理采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成物理采集点年维度统计结果集;
    f、基于历史用电数据,按设备属性或区域属性划分物理采集点并以四则运算公式将具有相同属性的物理采集点表达为虚拟采集点,以小时和虚拟采集点为维度,计算出各个企业下所有虚拟采集点每小时内电量累计值、电量最大值最小值、电量最大值最小值出现时间点、各相电压整点瞬时值、各相电压最大值最小值、各相电压最大值最小值出现时间点、各相电流整点瞬时值、各相电流最大值最小值、各相电流最大值最小值出现时间点、总无功功率整点瞬时值、总无功功率最大值最小值、总无功功率最大值最小值出现时间点、总功率因数瞬时值、总功率因数最大值最小值、总功率因数最大值最小值出现时间点,生成虚拟采集点小时维度统计结果集;
    g、基于虚拟采集点小时维度结果集,以天为维度,计算每一天内电量累计值、电量最大值最小值平均值、分季节和时间段的电量峰平谷值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值 最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点天维度统计结果集;
    h、基于虚拟采集点天维度结果集,以月为维度,计算每月电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点月维度统计结果集;
    i、基于虚拟采集点月维度结果集,以年为维度,计算每年电量累计值、电量最大值最小值平均值、电量最大值最小值出现时间点、各相电压最大值最小值平均值、各相电压最大值最小值出现时间点、各相电流最大值最小值平均值、各相电流最大值最小值出现时间点、总无功功率最大值最小值平均值、总无功功率最大值最小值出现时间点、总功率因数最大值最小值平均值、总功率因数最大值最小值出现时间点,生成虚拟采集点年维度统计结果集。
  8. 根据权利要求5所述的方法,其中,所述数据存储系统采用分布式文件存储系统HDFS,数据交互采用基于HDFS的原生SQL查询引擎HA WQ SQL查询引擎。
  9. 一种基于分布式计算的能源数据处理系统,所述系统包括数据采集系统、和数据处理系统;其中,
    所述数据采集系统,配置为从数据库中采集原始数据,其中,所述原始数据至少包括企业信息、电能站信息、采集器信息、物理采集点信息、虚拟采集点信息和历史用电数据中的至少一种;
    所述数据处理系统利用Spark分布式计算引擎,配置为对所述数据采集 系统采集的原始数据进行数据清洗,对清洗后的原始数据进行计算,生成至少一个维度的统计数据。
  10. 根据权利要求9所述的系统,其中,所述系统还包括:数据存储系统;所述数据存储系统,配置为存储所述至少一个维度的统计数据;存储在所述数据存储系统的数据能够被实时查询。
PCT/CN2020/094016 2020-03-10 2020-06-02 基于分布式计算的能源数据处理方法和系统 WO2021179447A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010161552.6 2020-03-10
CN202010161552.6A CN111241087A (zh) 2020-03-10 2020-03-10 一种基于分布式计算的能源数据自动化处理方法

Publications (1)

Publication Number Publication Date
WO2021179447A1 true WO2021179447A1 (zh) 2021-09-16

Family

ID=70875243

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/094016 WO2021179447A1 (zh) 2020-03-10 2020-06-02 基于分布式计算的能源数据处理方法和系统

Country Status (2)

Country Link
CN (1) CN111241087A (zh)
WO (1) WO2021179447A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112749473B (zh) * 2020-09-14 2023-11-28 万洲电气股份有限公司 基于实时在线分析和模拟离线分析的能效安全诊断系统

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107807961A (zh) * 2017-10-10 2018-03-16 国网浙江省电力公司丽水供电公司 一种基于Spark计算引擎的配电网大数据分区处理方法
CN107832876A (zh) * 2017-10-27 2018-03-23 国网江苏省电力公司南通供电公司 基于MapReduce框架的分区最大负荷预测方法
US20180165333A1 (en) * 2015-05-18 2018-06-14 Zte Corporation Big data calculation method and system
CN108492134A (zh) * 2018-03-07 2018-09-04 国网四川省电力公司 基于多周期回归树集成的大数据用户用电行为分析系统
CN109492002A (zh) * 2018-10-19 2019-03-19 浙江大学华南工业技术研究院 一种智能电网大数据存储与分析系统及处理方法

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100484017C (zh) * 2004-09-08 2009-04-29 大唐移动通信设备有限公司 网元管理系统中海量性能数据的统计方法
CN104361110B (zh) * 2014-12-01 2016-01-20 广东电网有限责任公司清远供电局 海量用电数据分析系统及其实时计算、数据挖掘方法
CN106202566A (zh) * 2016-08-02 2016-12-07 山东鲁能软件技术有限公司 一种基于大数据的海量用电数据混合存储系统及方法

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180165333A1 (en) * 2015-05-18 2018-06-14 Zte Corporation Big data calculation method and system
CN107807961A (zh) * 2017-10-10 2018-03-16 国网浙江省电力公司丽水供电公司 一种基于Spark计算引擎的配电网大数据分区处理方法
CN107832876A (zh) * 2017-10-27 2018-03-23 国网江苏省电力公司南通供电公司 基于MapReduce框架的分区最大负荷预测方法
CN108492134A (zh) * 2018-03-07 2018-09-04 国网四川省电力公司 基于多周期回归树集成的大数据用户用电行为分析系统
CN109492002A (zh) * 2018-10-19 2019-03-19 浙江大学华南工业技术研究院 一种智能电网大数据存储与分析系统及处理方法

Also Published As

Publication number Publication date
CN111241087A (zh) 2020-06-05

Similar Documents

Publication Publication Date Title
CN107402976B (zh) 一种基于多元异构模型的电网多源数据融合方法及系统
CN104820670B (zh) 一种电力信息大数据的采集和存储方法
CN103092840B (zh) 多源自增海量数据文件实时采集方法
Arenas-Martínez et al. A comparative study of data storage and processing architectures for the smart grid
CN107943831B (zh) 一种基于HBase的电网历史数据集中存储方法
CN106503276A (zh) 一种用于实时监控系统的时间序列数据库的方法与装置
CN104317800A (zh) 一种海量智能用电数据混合存储系统及方法
CN107748766B (zh) 一种基于Presto和Elasticsearch的大数据快速查询方法
CN108415964A (zh) 数据表查询方法、装置、终端设备及存储介质
CN111159180A (zh) 一种基于数据资源目录构建的数据处理方法及系统
CN104572856A (zh) 一种服务起源数据的融合存储方法
CN104036029A (zh) 大数据一致性对比方法和系统
CN107895017A (zh) 一种基于大数据技术的电能质量监测系统构建方法
Prasad et al. Application of polyglot persistence to enhance performance of the energy data management systems
CN103116595A (zh) 面向电网的scada历史数据分布式存储的实现方法
WO2021179447A1 (zh) 基于分布式计算的能源数据处理方法和系统
CN109446230A (zh) 一种光伏发电影响因素的大数据分析系统及方法
CN110941617A (zh) 一种基于版本控制的电网gis数据存储方法
CN110727684A (zh) 一种用于大数据统计分析的增量数据同步的方法
CN106599190A (zh) 基于云计算的动态Skyline查询方法
CN103593486A (zh) 一种电能质量海量数据存储及读取方法
CN115934856A (zh) 一种构造综合能源数据资产的方法和系统
CN112527857A (zh) 基于智能电表的多角度线损可视化数据分析平台
CN111159154A (zh) 一种能源数据仓库系统
CN110825744B (zh) 一种基于集群环境的空气质量监测大数据分区存储方法

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20923764

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20923764

Country of ref document: EP

Kind code of ref document: A1