Data analysis method and system based on smart power grid

Through preprocessing of smart grid data, blockchain encryption and machine learning analysis, the confidentiality and integrity of smart grid data are solved, and user privacy protection and safe and stable operation of the power grid are achieved.

CN120372636APending Publication Date: 2025-07-25STATE GRID ANHUI ELECTRIC POWER CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510286798.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-12
Publication Date
2025-07-25

AI Technical Summary

Technical Problem

While ensuring the efficient use of smart grid data, the prior art is difficult to ensure that the confidentiality and integrity of the data are not damaged, and user privacy cannot be fully protected.

Method used

After collecting smart grid data, preprocessing, a data security and privacy protection module is built, blockchain technology and homomorphic encryption technology are used for encryption processing, and intelligent analysis is combined with machine learning algorithms to generate monitoring reports and early warning information.

Benefits of technology

It ensures the confidentiality and integrity of smart grid data while ensuring efficient use of data, protecting user privacy, and providing support for the safe and stable operation of smart grids.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120372636A_ABST
    Figure CN120372636A_ABST
Patent Text Reader

Abstract

The invention provides a data analysis method and system based on a smart power grid, and particularly relates to the technical field of smart power grid information security, and the method comprises the steps: firstly collecting original data, including smart power grid operation data and user power consumption data, in the smart power grid, and then carrying out the preprocessing of the original data; comprising the steps of removing noise, filling missing values and extracting key features. And then, constructing a data security and privacy protection module, and encrypting the preprocessed data by using a block chain technology and a homomorphic encryption technology to ensure data security. And then, carrying out deep intelligent analysis by using the encrypted data and combining a machine learning algorithm. And finally, according to an intelligent analysis result, automatically generating a monitoring report and early warning information of the intelligent power grid data. According to the method, the technical problem that confidentiality and integrity of smart power grid data are difficult to be ensured not to be damaged while efficient utilization of the data is ensured in the prior art is solved, so that user privacy is fully protected.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of smart grid information security. Specifically, it relates to a data analysis method and system based on a smart grid. Background Art

[0002] With the rapid development of smart grid technology, the power industry is undergoing unprecedented changes. The smart grid, with its characteristics of high efficiency, reliability, and security, has become a key force in promoting energy transformation and achieving energy conservation and emission reduction goals. However, during the construction and operation of the smart grid, system security and privacy protection issues have become increasingly prominent, becoming a technical bottleneck restricting its further development. The smart grid system needs to collect, process, and analyze a large amount of sensitive data. Once these data are leaked or maliciously used, it will pose a serious threat to the safe and stable operation of the power grid and user privacy. Therefore, how to ensure data security and privacy protection while guaranteeing the efficient operation of the smart grid has become an important issue that needs to be solved urgently.

[0003] Regarding the system security and privacy protection issues of the smart grid system, traditional technologies mainly rely on security measures such as data encryption, firewalls, and intrusion detection systems. These technologies have improved the system's security protection ability to a certain extent, but have not completely solved the risks of data leakage and privacy infringement. Although data encryption technology can protect the confidentiality of data, there are still challenges in ensuring data availability and processing efficiency. At the same time, traditional security protection means often focus on the defense against external threats and ignore the potential risks brought by internal management and personnel operations. In addition, with the wide application of big data and artificial intelligence technologies, how to effectively protect user privacy during the data analysis process and avoid the leakage of sensitive information has also become a problem that traditional technologies are difficult to completely solve.

[0004] In summary, the technical problem of how to ensure the confidentiality and integrity of smart grid data without being damaged while guaranteeing the efficient utilization of data is an urgent technical problem to be solved currently. Summary of the Invention

[0005] The main purpose of the present invention is to provide a data analysis method and system based on a smart grid, so as to at least solve the technical problem that in the prior art, it is difficult to ensure the confidentiality and integrity of smart grid data without being damaged while guaranteeing the efficient utilization of data, thereby fully protecting user privacy.

[0006] To achieve the above object, the present invention provides a data analysis method and system based on a smart grid.

[0007] In a first aspect, the present invention provides a data analysis method based on a smart grid, including:

[0008] Collect the original data in the smart grid, where the original data is used to indicate the operation data of the smart grid and the power consumption data of users;

[0009] Preprocess the original data, where the preprocessing is used to remove noise, fill in missing values, and extract key features from the original data;

[0010] Build a data security and privacy protection module, and use blockchain technology and homomorphic encryption technology to encrypt the preprocessed data;

[0011] Use the encrypted data and combine machine learning algorithms for intelligent analysis;

[0012] Generate a monitoring report and warning information for the data of the smart grid according to the results of the intelligent analysis.

[0013] Optionally, the preprocessing of the original data includes:

[0014] Clean the collected original data to eliminate the noise data in the original data;

[0015] For the missing values in the original data, use interpolation method, regression method or statistical-based filling method to fill in the missing data points in the original data;

[0016] Use feature selection algorithm or feature extraction algorithm to extract key features from the original data.

[0017] Optionally, after the preprocessing of the original data, it further includes:

[0018] Convert the preprocessed data into a unified data format;

[0019] Perform outlier detection on the preprocessed data, identify the data points that do not meet the preset conditions, and correct or remove the data points that do not meet the preset conditions.

[0020] Optionally, the data security and privacy protection module uses a data access control mechanism to restrict illegal access to the encrypted data.

[0021] Optionally, the machine learning algorithm includes at least one of support vector machine, random forest or neural network.

[0022] In a second aspect, the present invention provides a data analysis system based on a smart grid. The data analysis system uses the data analysis method described in the first aspect. The data analysis system includes:

[0023] A data acquisition unit, which is connected to the data acquisition devices of the smart grid and is used to acquire the original data in the smart grid;

[0024] A data preprocessing unit, which is connected to the data acquisition unit and is used to preprocess the original data. Among them, the preprocessing is used to remove noise, fill in missing values and extract key features from the original data;

[0025] A data security and privacy protection unit, which is connected to the data preprocessing unit and is used to build a data security and privacy protection module, and encrypt the preprocessed data by using blockchain technology and homomorphic encryption technology;

[0026] An intelligent analysis unit, which is connected to the data security and privacy protection unit and is used to perform intelligent analysis by using the encrypted data in combination with machine learning algorithms;

[0027] A report generation unit, which is connected to the intelligent analysis unit and is used to generate a monitoring report and early warning information of the data of the smart grid according to the results of the intelligent analysis.

[0028] Optionally, the data preprocessing unit includes:

[0029] A data cleaning module, which is connected to the data acquisition unit and is used to clean the acquired original data to eliminate the noise data in the original data;

[0030] A missing value filling module, which is connected to the data acquisition unit and is used to fill in the missing data points in the original data by using interpolation method, regression method or statistics-based filling method for the missing values existing in the original data;

[0031] A key feature extraction module, which is connected to the data acquisition unit and is used to extract key features from the original data by using feature selection algorithms or feature extraction algorithms.

[0032] Optionally, the intelligent analysis unit includes a machine learning model training module, which is used to train and optimize the machine learning algorithms.

[0033] Optionally, the data security and privacy protection unit includes a data backup and recovery module, which is used to back up or recover the data of the smart grid.

[0034] The data analysis method and system based on the smart grid provided by this application aim to efficiently and securely analyze the operation data of the smart grid and the electricity consumption data of users. This method first collects the original data in the smart grid, covering the detailed information of grid operation and user electricity consumption. Subsequently, the original data is preprocessed to ensure data quality by removing noise, filling in missing values, and extracting key features. Then, a data security and privacy protection module is constructed, and advanced blockchain technology and homomorphic encryption technology are used to encrypt the preprocessed data to ensure data security and user privacy. Using the encrypted data, combined with machine learning algorithms, intelligent analysis is carried out to deeply explore the data value. Finally, according to the analysis results, a monitoring report and warning information of the smart grid data are automatically generated to provide decision-making support for grid operation and ensure the stable and safe operation of the grid. This method solves the technical problem that it is difficult to ensure the confidentiality and integrity of smart grid data are not damaged while ensuring the efficient utilization of data in the prior art, thus fully protecting user privacy. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] The specification drawings forming a part of this application are used to provide a further understanding of the present invention. The schematic embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0036] Figure 1 It is a schematic flowchart of the data analysis method based on the smart grid provided by this application;

[0037] Figure 2 It is a schematic diagram of the data analysis system based on the smart grid provided by this application.

[0038] Through the above drawings, the clear embodiments of this application have been shown, and there will be more detailed descriptions later. These drawings and text descriptions are not intended to limit the scope of the concept of this application in any way, but to explain the concept of this application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0039] To make the purpose, technical solutions, and advantages of this application clearer, the technical solutions in this application will be clearly and completely described below in conjunction with the drawings in this application. Obviously, the described embodiments are part of the embodiments of this application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of this application.

[0040] In the description and claims of the present invention and the above-mentioned drawings, the terms "first", "second", "third", "fourth", etc. (if any) are used to distinguish similar objects and do not necessarily describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein.

[0041] In the present invention, words such as "exemplary" or "for example" are used to represent examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present relevant concepts in a specific manner.

[0042] The data analysis method and system based on the smart grid provided in this application are aimed at collecting the original data of the smart grid operation and user power consumption. After preprocessing such as denoising, filling in missing values, and extracting key features, a data security and privacy protection module is constructed, and blockchain and homomorphic encryption technologies are used to encrypt the data. Subsequently, intelligent analysis is performed using the encrypted data in combination with machine learning algorithms, and finally a monitoring report and warning information are generated. The present invention solves the technical problem that in the prior art, while ensuring the efficient utilization of data, it is difficult to ensure that the confidentiality and integrity of smart grid data are not damaged, thereby fully protecting user privacy.

[0043] The following uses specific embodiments to elaborate in detail on the technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems. These several specific embodiments below can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of this application will be described below in conjunction with the drawings.

[0044] Figure 1 It is a schematic flow chart of the data analysis method based on the smart grid provided for this application, aiming to elaborate in detail on the data analysis method based on the smart grid. As Figure 1 shown, the data analysis method based on the smart grid provided in this embodiment includes:

[0045] S101: Collect the original data in the smart grid.

[0046] Among them, the original data is used to indicate the smart grid operation data and user power consumption data.

[0047] The following is a detailed description of the specific embodiment of this step:

[0048] 1. Implementation details

[0049] Collect the original data in the smart grid:

[0050] Data collection scope: Smart grid operation data: These data cover all aspects of the smart grid, including but not limited to grid voltage, current, frequency, power factor, load distribution, line loss, etc. These data are usually collected in real time through devices such as sensors, smart meters, and remote terminal units (RTUs) installed at various nodes of the grid.

[0051] User electricity consumption data: These data mainly reflect the electricity consumption behavior of users, including the electricity consumption volume, electricity consumption period, electricity load, electricity bill, etc. of users. These data are usually recorded in real time by users' smart meters or home energy management systems and uploaded to the smart grid system.

[0052] Data collection methods: Real-time collection: Using sensors and smart meters installed at various nodes of the grid and user terminals, data is collected in real time through wired or wireless means. These sensors and smart meters usually have high precision and high stability, ensuring the accuracy and reliability of the data.

[0053] Periodic collection: For some data that does not need to be updated in real time, a fixed collection period can be set, such as once per hour, once per day, or once per week. This can reduce the pressure of data transmission and storage while ensuring the timeliness of the data.

[0054] Data format and storage: Data format: The collected raw data is usually represented in digital form, such as integers, floating-point numbers, etc. For subsequent data processing and analysis, these data need to be stored in a unified data format, such as CSV, JSON, or database format, etc.

[0055] Data storage: The raw data is usually stored in the data center of the smart grid system or a cloud storage platform. These platforms have powerful data storage and processing capabilities, capable of supporting the real-time storage and access of large-scale data.

[0056] Data verification and preprocessing: During the data collection process, preliminary verification and preprocessing of the data are required to ensure the integrity and accuracy of the data. For example, the integrity (whether missing), correctness (whether within the expected range), and consistency (whether data from different sources is consistent) of the data can be checked, etc.

[0057] For data that does not meet the requirements, corresponding measures can be taken for correction or elimination to avoid adverse effects on subsequent data processing and analysis.

[0058] 2. Implementation example

[0059] Suppose the smart grid system needs to collect the grid operation data and user electricity consumption data of a region. The specific steps are as follows:

[0060] Configure sensors and smart meters: Install sensors and smart meters at each node of the power grid and the user side, and configure corresponding data acquisition parameters, such as acquisition frequency, data format, etc.

[0061] Collect data in real time: The sensors and smart meters collect data in real time according to the set acquisition frequency and transmit the data to the data center of the smart grid system.

[0062] Data storage and verification: The data center receives and stores the collected raw data, and at the same time performs preliminary verification and preprocessing on the data, such as checking the integrity, correctness, and consistency of the data.

[0063] Data output: The raw data after verification and preprocessing is output to subsequent processing steps for subsequent data preprocessing, encryption processing, intelligent analysis, and report generation, etc.

[0064] Through the above steps, the present invention can efficiently collect the raw data in the smart grid and provide accurate and reliable data support for subsequent data processing and analysis.

[0065] S102: Preprocess the raw data.

[0066] Wherein, the preprocessing is used to remove noise, fill in missing values, and extract key features from the raw data.

[0067] Specifically, this step specifically includes:

[0068] Clean the collected raw data to eliminate the noise data in the raw data;

[0069] For the missing values in the raw data, use interpolation method, regression method or statistics-based filling method to fill in the missing data points in the raw data;

[0070] Use feature selection algorithm or feature extraction algorithm to extract key features from the raw data.

[0071] Optionally, after preprocessing the raw data, it further includes:

[0072] Convert the preprocessed data into a unified data format;

[0073] Perform outlier detection on the preprocessed data, identify the data points that do not meet the preset conditions, and correct or eliminate the data points that do not meet the preset conditions.

[0074] The following is a detailed description of the implementation examples of this step and the optional part:

[0075] I. Preprocessing steps

[0076] 1. Data cleaning

[0077] Purpose: To eliminate noisy data in the original data and improve data quality.

[0078] Method: Filtering technology: Digital filters are used to smooth time series data, such as moving average filters, exponential smoothing filters, etc., to reduce random noise.

[0079] Statistical method: Using statistical principles, such as the 3σ principle, to identify and remove outliers outside the normal range.

[0080] Data deduplication: Check and delete duplicate data records to avoid data redundancy.

[0081] 2. Missing value imputation

[0082] Purpose: To fill in the missing values in the original data and ensure data integrity.

[0083] Method: Interpolation method: Such as linear interpolation, polynomial interpolation, etc., to estimate missing values based on the values of adjacent data points.

[0084] Regression method: Using regression models (such as linear regression, non - linear regression) to predict missing values.

[0085] Statistical - based imputation methods: Such as mean imputation, median imputation, mode imputation, etc., to fill in missing values according to the statistical characteristics of the data.

[0086] 3. Key feature extraction

[0087] Purpose: To extract key features from the original data that have an important impact on subsequent analysis.

[0088] Method: Feature selection algorithms: Such as Recursive Feature Elimination (RFE), model - based feature selection (such as feature importance evaluation based on decision trees, random forests), etc., to select key features according to the impact of features on model performance.

[0089] Feature extraction algorithms: Such as Principal Component Analysis (PCA), Linear Discriminant Analysis (LDA), etc., to extract the main features in the data through dimensionality reduction techniques.

[0090] 4. Data format unification

[0091] Purpose: To convert the pre - processed data into a unified data format for easy subsequent processing and analysis.

[0092] Method: According to the analysis requirements, convert the data into a specific data format, such as CSV, JSON, database tables, etc.

[0093] 5. Outlier detection and correction

[0094] Objective: To identify and process the outliers still existing in the preprocessed data and ensure the accuracy of the data.

[0095] Method: Statistical detection methods such as box plot method, Z-score method, etc. are used to identify the outliers that do not meet the preset conditions.

[0096] Correction or elimination: For the identified outliers, processing methods such as correction (e.g., replacing with the mean or median of adjacent data points) or elimination (directly deleting the outliers) can be adopted.

[0097] II. Implementation Example

[0098] Suppose a batch of original data is collected by the smart grid system, including operation data such as grid voltage, current, frequency, etc. and user data such as user power consumption. The following are the specific implementations of the preprocessing steps:

[0099] Data cleaning: A moving average filter is used to smooth the time series data to eliminate random noise; the 3σ principle is used to identify and eliminate outliers; duplicate data records are checked and deleted.

[0100] Missing value filling: For the missing grid voltage data, linear interpolation is used to estimate the missing values based on the voltage values at adjacent time points; for the missing user power consumption data, a decision tree-based regression model is used to predict the missing values.

[0101] Key feature extraction: A recursive feature elimination algorithm is used to extract the key features from the original data that have important impacts on the grid operation status and user power consumption behavior, such as the grid voltage fluctuation range, user power consumption peak, etc.

[0102] Data format unification: The preprocessed data is converted into the CSV format for subsequent data analysis and visualization.

[0103] Outlier detection and correction: The box plot method is used to identify the outliers still existing in the preprocessed data, and the mean of adjacent data points is used to replace the outliers for correction.

[0104] Through the above preprocessing steps, the original data has been effectively cleaned, filled, and feature extracted, providing a high-quality data basis for subsequent data encryption, intelligent analysis, and report generation.

[0105] S103: Construct a data security and privacy protection module, and use blockchain technology and homomorphic encryption technology to encrypt the preprocessed data.

[0106] Among them, the data security and privacy protection module uses a data access control mechanism to restrict the illegal access to the encrypted data.

[0107] The following is a detailed example description of this step:

[0108] I. Construction of Data Security and Privacy Protection Module

[0109] 1. Technology Selection

[0110] Blockchain technology: Blockchain technology is adopted to ensure the immutability of data and the security of distributed storage. Blockchain technology links data in the form of blocks and uses cryptographic methods to ensure the immutability of each block, thus guaranteeing the integrity and security of data.

[0111] Homomorphic encryption technology: Homomorphic encryption technology is used to encrypt data, enabling specific computational operations such as addition, multiplication, etc. to be performed in the encrypted state without decrypting the data. This not only protects the privacy of data but also supports the analysis and processing of data.

[0112] 2. Module Construction

[0113] Encryption processing: For the preprocessed data, homomorphic encryption technology is first used for encryption processing. Homomorphic encryption technology allows specific computations to be performed on encrypted data, such as inner product calculations in support vector machines and decision tree splitting condition calculations in random forests, without decrypting the data.

[0114] The encrypted data is stored on the blockchain, leveraging the distributed storage and immutability of the blockchain to ensure data security.

[0115] Data access control mechanism: A data access control module is constructed, which is implemented based on the smart contract technology of the blockchain. A smart contract is an automatically executable contract that will automatically execute preset operations when specific conditions are met.

[0116] The data access control module defines data access permissions and rules through smart contracts, such as which users or systems can access which data and what operations they can perform, etc.

[0117] When a user or system attempts to access data, the data access control module will verify its identity and permissions and decide whether to allow access according to the rules of the smart contract.

[0118] 3. Specific Implementation

[0119] Selection of homomorphic encryption algorithm: Select a homomorphic encryption algorithm suitable for smart grid data analysis, such as Gentry's fully homomorphic encryption (FHE) scheme or Paillier's additive homomorphic encryption scheme, etc. These algorithms can perform specific mathematical operations in the encrypted state, meeting the requirements of smart grid data analysis.

[0120] Blockchain Platform Selection: Select a blockchain platform suitable for the storage and transmission of smart grid data, such as Ethereum, Hyperledger Fabric, etc. These platforms provide rich smart contract development tools and interfaces, facilitating the implementation of data access control mechanisms.

[0121] Smart Contract Development: Develop corresponding smart contracts according to the requirements of smart grid data analysis. The smart contracts should include functions such as data access permissions and rules, authentication mechanisms, and data access log records.

[0122] System Integration and Testing: Integrate the data security and privacy protection module with the smart grid data analysis system and conduct comprehensive testing. The testing should include functional testing, performance testing, security testing, etc., to ensure the correctness and stability of the module.

[0123] II. Implementation Example

[0124] Suppose the smart grid system needs to analyze users' electricity consumption data to predict future power demand. To protect users' privacy and data security, the system adopts the following data security and privacy protection strategies:

[0125] After preprocessing the users' electricity consumption data, use the Paillier additive homomorphic encryption scheme to encrypt the data.

[0126] Store the encrypted data on the Ethereum blockchain and utilize the distributed storage and immutability of the blockchain to ensure data security.

[0127] Develop smart contracts to define data access permissions and rules, such as only allowing specific data analysts to access the encrypted data and restricting them to perform specific calculation operations.

[0128] When a data analyst needs to access the data, the data access control module will verify their identity and permissions and decide whether to allow access according to the rules of the smart contract. If access is allowed, the data analyst can perform calculation operations on the prediction model (such as support vector machine) in the encrypted state without decrypting the data.

[0129] Through the above embodiments, the smart grid data analysis system can ensure data security and privacy while supporting efficient data analysis and processing.

[0130] S104: Use the encrypted data and combine machine learning algorithms for intelligent analysis.

[0131] Among them, the machine learning algorithms include at least one of support vector machine, random forest, or neural network.

[0132] In the data analysis method based on the smart grid, step S104 is a key step for intelligent analysis by combining the encrypted data with machine learning algorithms. The following is a detailed description of the implementation of this step, covering the applications of three machine learning algorithms: Support Vector Machine (SVM), Random Forest (RF), and Neural Network (NN).

[0133] 1. Application of Support Vector Machine (SVM) Algorithm

[0134] Algorithm Introduction:

[0135] Support Vector Machine is a binary classification model. Its basic idea is to find a hyperplane to maximize the margin between two types of samples. For non-linear problems, SVM can map them to a high-dimensional space for solution through the kernel function technique.

[0136] Implementation Steps:

[0137] Data Preparation: Obtain the encrypted data from the data security and privacy protection module and decrypt it (note that here the decryption means decrypting within the calculation range allowed by homomorphic encryption to obtain the plaintext data form that can be used for SVM calculation, rather than completely decrypting it into the original plaintext data).

[0138] Feature Selection: Select the feature inputs suitable for the SVM algorithm according to the key features extracted in the preprocessing step.

[0139] Model Training: Use the selected feature data and combine the SVM algorithm for model training. During the training process, appropriate kernel functions (such as linear kernel, Gaussian kernel, etc.) and regularization parameters can be selected to optimize the model performance.

[0140] Prediction and Analysis: Apply the trained SVM model to new encrypted data (also within the calculation range allowed by homomorphic encryption) for prediction and analysis to obtain the classification results of the operation status of the smart grid or the electricity consumption behavior of users.

[0141] 2. Application of Random Forest (RF) Algorithm

[0142] Algorithm Introduction:

[0143] Random Forest is an ensemble learning method that improves the accuracy and robustness of the model by constructing multiple decision trees and integrating their prediction results.

[0144] Implementation Steps:

[0145] Data Preparation: Similarly, obtain the encrypted data from the data security and privacy protection module and perform decryption (the same as SVM).

[0146] Feature Selection: Select feature inputs suitable for the RF algorithm, which should be able to fully reflect the operating status of the smart grid and user electricity consumption behavior.

[0147] Model Training: Use the selected feature data and combine with the RF algorithm for model training. During the training process, parameters such as the number of decision trees and the maximum depth can be adjusted to optimize the model performance.

[0148] Prediction and Analysis: Apply the trained RF model to new encrypted data for prediction and analysis to obtain the prediction results of the operating status of the smart grid or user electricity consumption behavior.

[0149] 3. Application of Neural Network (NN) Algorithm

[0150] Algorithm Introduction:

[0151] A neural network is a machine learning algorithm that simulates the structure of human brain neurons and has powerful non-linear fitting ability and generalization ability.

[0152] Implementation Steps:

[0153] Data Preparation: Obtain the encrypted data from the data security and privacy protection module and perform decryption processing (same as SVM and RF).

[0154] Feature Selection and Preprocessing: Select feature inputs suitable for the NN algorithm and perform necessary preprocessing operations such as normalization and standardization to improve the training efficiency and performance of the model.

[0155] Model Construction: Build a suitable neural network model according to the requirements of smart grid data analysis. The model can include an input layer, hidden layers, and an output layer, where the number of hidden layers and the number of neurons in each layer can be adjusted according to actual needs.

[0156] Model Training: Use the selected feature data and the neural network model for training. During the training process, suitable optimization algorithms (such as gradient descent method, Adam algorithm, etc.) and loss functions (such as mean square error, cross-entropy loss, etc.) can be selected to optimize the model performance.

[0157] Prediction and Analysis: Apply the trained neural network model to new encrypted data for prediction and analysis to obtain the prediction results of the operating status of the smart grid or user electricity consumption behavior.

[0158] It should be noted that when using the encrypted data for machine learning algorithm training, attention needs to be paid to the limitations and computational overhead of the homomorphic encryption algorithm. Homomorphic encryption allows specific mathematical operations to be performed on encrypted data, but not all operations are supported. Therefore, when choosing a machine learning algorithm, it is necessary to ensure that its computational process can be carried out within the scope permitted by homomorphic encryption. For large-scale data sets and complex models, distributed computing or high-performance computing technologies may need to be adopted to improve computational efficiency and accuracy.

[0159] From the description of the above embodiments, it can be seen that in the data analysis method based on the smart grid, it is feasible to perform intelligent analysis by using the encrypted data in combination with machine learning algorithms. By selecting appropriate machine learning algorithms and parameter configurations, accurate analysis and prediction of the operation data of the smart grid and the electricity consumption data of users can be achieved, providing strong support for the optimization and management of the smart grid.

[0160] S105: Generate a monitoring report and warning information for the data of the smart grid according to the results of the intelligent analysis.

[0161] In the data analysis method based on the smart grid, step S105 is a key step to convert the results of the intelligent analysis into practical and operable information, that is, to generate a monitoring report and warning information for the data of the smart grid. The following is a detailed description of the embodiments of this step:

[0162] I. Generation of the monitoring report

[0163] Data summarization and collation: Obtain the analysis results from the intelligent analysis module, which usually include the operating status of the smart grid, user electricity consumption behavior patterns, anomaly detection, etc.

[0164] Compare the analysis results with the original data to ensure the accuracy and integrity of the data.

[0165] Summarize and collate the analysis results to form a structured data report.

[0166] Report content design: Operating status of the smart grid: including key indicators such as grid load, voltage stability, current distribution, etc.

[0167] Analysis of user electricity consumption behavior: including the change trend of user electricity consumption, peak electricity consumption periods, abnormal electricity consumption behaviors, etc.

[0168] Anomaly detection and diagnosis: List the detected abnormal events, including the type of anomaly, occurrence time, scope of influence, etc., and provide possible diagnostic results and suggestions.

[0169] Report format and presentation: Select an appropriate report format, such as tables, charts, text descriptions, etc., to clearly display the analysis results.

[0170] Use professional report generation tools or software to ensure that the report has beautiful typesetting and accurate content.

[0171] II. Early Warning Information Generation

[0172] Set early warning rules According to the actual situation and requirements analysis of the smart grid, set early warning rules. These rules can be based on the grid operation status, user electricity consumption behavior, historical data, etc.

[0173] The early warning rules should clarify the triggering conditions of the early warning, the early warning level, the sending method of the early warning information, etc.

[0174] Early warning information generation and sending When the result of the intelligent analysis meets the triggering conditions set by the early warning rules, early warning information is automatically generated.

[0175] The early warning information should include key information such as the early warning level, the early warning content, the occurrence time, and the recommended measures.

[0176] Send the early warning information to relevant personnel or systems via text messages, emails, APP push, etc., so as to take measures in a timely manner.

[0177] Early warning response and tracking The personnel or systems receiving the early warning information should take corresponding measures according to the early warning content, such as adjusting the grid operation parameters, notifying users to check their electricity consumption equipment, etc.

[0178] Track and evaluate the effect of the early warning response to ensure the accuracy and effectiveness of the early warning information.

[0179] III. Embodiment Details

[0180] Intelligent analysis algorithm: In step S104, the specific implementation and parameter settings of the machine learning algorithms (such as support vector machines, random forests, neural networks, etc.) adopted should be selected according to the actual situation and requirements of the smart grid.

[0181] Data access control: The data security and privacy protection module constructed in step S103 should ensure that only authorized personnel or systems can access and analyze data when generating monitoring reports and early warning information.

[0182] Timeliness of reports and early warnings: The generation of monitoring reports and early warning information should be timely to ensure that relevant personnel or systems can obtain the latest analysis results and early warning information in a timely manner.

[0183] IV. Implementation Example

[0184] Suppose that the smart grid detects a sudden increase in user power consumption within a certain period, and it exceeds the preset threshold. According to the results of intelligent analysis, the system determines that there may be abnormal user power consumption behavior. At this time, the system can automatically generate a monitoring report, which details the change trend of user power consumption, the time period when the abnormality occurred, and the possible reasons for the abnormality, etc. At the same time, the system can also generate a warning message, set the warning level to "high", and suggest that relevant personnel check the user's power consumption equipment. The warning message is sent to relevant personnel via text message so that they can take measures in a timely manner.

[0185] From the description of the above embodiments, it can be seen that in the data analysis method based on the smart grid, the generation of the monitoring report and warning message in step S105 is an important link to ensure the safe and stable operation of the smart grid. Through reasonable report content design, warning rule setting, and the generation and sending of warning messages, real-time monitoring and warning of the operating state of the smart grid can be achieved, providing strong support for the management and maintenance of the smart grid.

[0186] A data analysis method based on the smart grid provided in this embodiment covers a complete process from data collection to intelligent analysis and then to the generation of monitoring reports and warning messages. First, the original data in the smart grid, including operation data and user power consumption data, is collected through step S101. Then, in step S102, these original data are preprocessed, including cleaning, filling missing values, and extracting key features, to ensure the accuracy and availability of the data. Subsequently, in step S103, a data security and privacy protection module is constructed, and blockchain technology and homomorphic encryption technology are used to encrypt the preprocessed data to ensure data security. In step S104, using the encrypted data, intelligent analysis is carried out in combination with machine learning algorithms such as support vector machines, random forests, or neural networks to mine potential information and rules in the data. Finally, in step S105, according to the results of intelligent analysis, a data monitoring report and warning message for the smart grid are generated, providing decision-making support for the operation and maintenance of the power grid. The entire analysis method has clear logic and closely connected steps, ensuring the accuracy, security, and availability of smart grid data, and providing strong technical support for the intelligent management and operation and maintenance of the smart grid. Through this method, the technical problem that it is difficult to ensure the confidentiality and integrity of smart grid data are not damaged while ensuring the efficient utilization of data in the prior art is solved, so that user privacy is fully protected.

[0187] Figure 2 The schematic diagram of the data analysis system based on the smart grid provided in this application is as Figure 2 shown. The data analysis system based on the smart grid provided in this embodiment uses the data analysis method described in Figure 1 the embodiment. The system includes:

[0188] A data acquisition unit, which is connected to the data acquisition device of the smart grid, and is used to acquire the original data in the smart grid;

[0189] A data preprocessing unit, which is connected to the data acquisition unit, and is used to preprocess the original data, wherein the preprocessing is used to remove noise, fill in missing values and extract key features from the original data;

[0190] A data security and privacy protection unit, which is connected to the data preprocessing unit, and is used to construct a data security and privacy protection module, and encrypt the preprocessed data by using blockchain technology and homomorphic encryption technology;

[0191] An intelligent analysis unit, which is connected to the data security and privacy protection unit, and is used to perform intelligent analysis by using the encrypted data in combination with machine learning algorithms;

[0192] A report generation unit, which is connected to the intelligent analysis unit, and is used to generate a monitoring report and early warning information of the data of the smart grid according to the results of the intelligent analysis.

[0193] Specifically, the data preprocessing unit includes:

[0194] A data cleaning module, which is connected to the data acquisition unit, and is used to clean the acquired original data to eliminate the noise data in the original data;

[0195] A missing value filling module, which is connected to the data acquisition unit, and is used to fill in the missing values in the original data by using interpolation method, regression method or statistics-based filling method to fill in the missing data points in the original data;

[0196] A key feature extraction module, which is connected to the data acquisition unit, and is used to extract key features from the original data by using feature selection algorithms or feature extraction algorithms.

[0197] Specifically, the intelligent analysis unit includes a machine learning model training module, which is used to train and optimize the machine learning algorithm.

[0198] Specifically, the data security and privacy protection unit includes a data backup and recovery module, which is used to backup or recover the data of the smart grid.

[0199] This embodiment describes a data analysis system based on a smart grid. This system adopts Figure 1 the data analysis method described in the embodiment, and details the connection methods and functions between each unit and module.

[0200] The system includes a data acquisition unit, which is directly connected to the data acquisition devices of the smart grid and is responsible for acquiring the original data in the smart grid, including power grid operation data and user power consumption data.

[0201] Connected to the data acquisition unit is a data preprocessing unit, which includes a data cleaning module, a missing value filling module, and a key feature extraction module. The data cleaning module is used to eliminate the noise data in the original data to ensure the purity of the data; the missing value filling module targets the missing values in the original data and uses interpolation methods, regression methods, or statistics-based filling methods to fill them to ensure the integrity of the data; the key feature extraction module uses feature selection algorithms or feature extraction algorithms to extract the features that have a key impact on the analysis from the original data.

[0202] The data security and privacy protection unit is connected to the data preprocessing unit. The data security and privacy protection unit constructs a data security and privacy protection module, which uses blockchain technology and homomorphic encryption technology to encrypt the preprocessed data to ensure the security and privacy of the data. In addition, this unit also includes a data backup and recovery module, which is used to backup or recover the data of the smart grid to prevent data loss or damage.

[0203] The intelligent analysis unit is connected to the data security and privacy protection unit. The intelligent analysis unit includes a machine learning model training module and an intelligent analysis module. The machine learning model training module is used to train and optimize machine learning algorithms, such as support vector machines, random forests, or neural networks, etc., to improve the accuracy and efficiency of the analysis. The intelligent analysis module then uses the encrypted data and the trained machine learning model to perform intelligent analysis and mine the potential information and rules in the data.

[0204] Finally, the report generation unit is connected to the intelligent analysis unit. This unit generates a data monitoring report and warning information for the smart grid based on the results of the intelligent analysis, providing decision support for the operation and management of the power grid.

[0205] In summary, for the data analysis system based on the smart grid provided in this embodiment, the connection methods between each unit and module are clear and definite, the functions are complete, and it can realize the comprehensive, accurate, and secure analysis and processing of the smart grid data.

[0206] Those skilled in the art will readily conceive of other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any variations, uses, or adaptations of the present application, which follow the general principles of the present application and include the common general knowledge or conventional technical means in the technical field not disclosed in the present application. The specification and examples are only regarded as exemplary, and the true scope and spirit of the present application are pointed out by the claims.

[0207] It should be understood that the present application is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present application is only limited by the appended claims.

Claims

1. A data analysis method based on a smart grid, characterized in that, Including: Collecting the original data in the smart grid, where the original data is used to indicate the operation data of the smart grid and the power consumption data of users; Preprocessing the original data, where the preprocessing is used to remove noise, fill in missing values and extract key features from the original data; Constructing a data security and privacy protection module, and using blockchain technology and homomorphic encryption technology to encrypt the preprocessed data; Using the encrypted data and combining machine learning algorithms for intelligent analysis; Generating a monitoring report and warning information for the data of the smart grid according to the results of the intelligent analysis.

2. The data analysis method according to claim 1, wherein The preprocessing of the original data includes: Cleaning the collected original data to eliminate the noise data in the original data; For the missing values in the original data, using interpolation method, regression method or filling method based on statistics to fill in the missing data points in the original data; Using feature selection algorithm or feature extraction algorithm to extract key features from the original data.

3. The data analysis method according to claim 1, wherein After the preprocessing of the original data, it also includes: Converting the preprocessed data into a unified data format; Performing outlier detection on the preprocessed data, identifying the data points that do not meet the preset conditions, and correcting or removing the data points that do not meet the preset conditions.

4. The data analysis method according to claim 1, wherein The data security and privacy protection module uses a data access control mechanism to restrict illegal access to the encrypted data.

5. The data analysis method according to claim 1, wherein The machine learning algorithm includes at least one of support vector machine, random forest or neural network.

6. A data analysis system based on a smart grid, characterized in that, The data analysis system uses the data analysis method described in any one of claims 1-5. The data analysis system includes: A data collection unit, which is connected to the data collection device of the smart grid, and the data collection unit is used to collect the original data in the smart grid; A data preprocessing unit, which is connected to the data collection unit, and the data preprocessing unit is used to preprocess the original data, where the preprocessing is used to remove noise, fill in missing values and extract key features from the original data; A data security and privacy protection unit, which is connected to the data preprocessing unit, and the data security and privacy protection unit is used to construct a data security and privacy protection module and use blockchain technology and homomorphic encryption technology to encrypt the preprocessed data; An intelligent analysis unit, which is connected to the data security and privacy protection unit, and the intelligent analysis unit is used to use the encrypted data and combine machine learning algorithms for intelligent analysis; A report generation unit, which is connected to the intelligent analysis unit, and the report generation unit is used to generate a monitoring report and warning information for the data of the smart grid according to the results of the intelligent analysis.

7. The data analysis system according to claim 6, wherein The data preprocessing unit includes: Data cleaning module, the data cleaning module is connected to the data acquisition unit, and the data cleaning module is used to clean the collected raw data to eliminate the noise data in the raw data; Missing value filling module, the missing value filling module is connected to the data acquisition unit, and the missing value filling module is used to fill the missing data points in the raw data by using interpolation method, regression method or statistics-based filling method for the missing values existing in the raw data; Key feature extraction module, the key feature extraction module is connected to the data acquisition unit, and the key feature extraction module is used to extract key features from the raw data by using feature selection algorithm or feature extraction algorithm.

8. The data analysis system according to claim 6, wherein The intelligent analysis unit includes a machine learning model training module, and the machine learning model training module is used to train and optimize the machine learning algorithm.

9. The data analysis system according to claim 6, wherein The data security and privacy protection unit includes a data backup and recovery module, and the data backup and recovery module is used to backup or recover the data of the smart grid.