Indoor heating and ventilation distributed control method for high-speed service area building
Through distributed control architecture and reinforcement learning model, combined with edge computing and heterogeneous federated learning, the problems of regional differences and privacy protection in HVAC control in high-speed service areas are solved, and refined, adaptive, low-latency HVAC control is achieved, improving user comfort and system reliability.
Patent Information
- Application Number
- CN202510380058.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-28
- Publication Date
- 2025-08-15
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The traditional centralized HVAC control method is difficult to take into account the differentiated needs of different functional areas of the high-speed service area, and there is a risk of single point of failure, high communication delay, large data transmission volume, and difficult to achieve real-time control. The existing distributed control method has failed to effectively solve the needs of data heterogeneity and privacy protection.
Adopt a distributed control architecture, using reinforcement learning models and edge computing nodes, combining heterogeneous federated learning, collect environmental and personnel data in real time, perform refined control, and adapt to the characteristics of each region through model compression and knowledge distillation technology to protect data privacy.
It realizes refined and adaptive HVAC control in high-speed service areas, reduces energy consumption, improves user comfort, enhances system reliability, protects data privacy, and responds to environmental changes quickly, with good scalability.
Smart Images

Figure CN120488451A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of heating and ventilation engineering, and in particular to a distributed control method for indoor heating and ventilation in buildings in high-speed service areas. Background Art
[0002] Highway service areas, as important supporting facilities at transportation hubs, provide drivers and passengers with rest, dining, and shopping services. The performance of the indoor HVAC systems in service area buildings directly impacts passenger comfort and energy consumption. Traditional HVAC control methods typically employ centralized control, where a central controller manages HVAC equipment in all areas. This approach has several drawbacks: First, centralized control struggles to accommodate the diverse needs of different functional areas. For example, areas like restaurants, rest areas, and restrooms vary in occupancy density, activity types, and environmental requirements, making it difficult to achieve precise adjustments using a unified control strategy. Second, centralized control places high demands on the reliability of the central controller; a failure of the central controller can paralyze the entire HVAC system. Furthermore, centralized control requires all sensor data to be transmitted to the central controller, resulting in high communication latency, making real-time control difficult. Furthermore, the large data volume requires high network bandwidth.
[0003] In recent years, with the development of the Internet of Things, edge computing, and artificial intelligence technologies, distributed control and intelligent control have become new trends in the development of HVAC systems. Some studies have attempted to apply machine learning algorithms to HVAC control to improve control accuracy and energy efficiency. However, most of these methods are based on supervised learning and require a large amount of labeled data, while obtaining high-quality labeled data (such as occupant comfort) is costly. In addition, existing methods rarely consider the particularities of service area buildings, such as the differences between different functional areas, the uncertainty of personnel flow, and the need to protect data privacy. Traditional federated learning usually assumes that data is independently distributed and the model structure is the same, which is difficult to meet the actual situation of service areas where both data and models are heterogeneous. Summary of the Invention
[0004] In response to the shortcomings of the above-mentioned existing technologies, the present invention aims to provide a distributed HVAC control method that can adapt to the characteristics of high-speed service areas, balance user comfort and energy efficiency, protect data privacy, and adapt to heterogeneous environments.
[0005] In order to achieve the above-mentioned object of the invention, the technical solution provided by the present invention includes:
[0006] A distributed control method for indoor HVAC in a highway service area building includes the following steps:
[0007] S1. Collect environmental data, personnel data, equipment data, and personnel comfort perceptions of various functional areas in the highway service area buildings during a preset time period to construct an initial data set;
[0008] S2. Preprocessing the initial data set to obtain a first training set; dividing the first training set into multiple second training data sets according to the functional area type;
[0009] S3. Build an initial reinforcement learning model on the central server, use the HVAC equipment control parameters as output, and complete the pre-training of the initial reinforcement learning model using the first training set;
[0010] S4. Copy multiple trained initial reinforcement learning models, and use the second training data set to fine-tune the trained initial reinforcement learning models to obtain a target model for each functional area;
[0011] S5. Compressing the target model and deploying it to the edge computing nodes of each functional area;
[0012] S6. The edge computing node collects environmental data, personnel data, and equipment data of each functional area in real time, inputs the compressed target model to obtain control parameters of each HVAC equipment, and sends the control parameters to the HVAC equipment control module for execution.
[0013] Preferably, the method for preprocessing the initial data set includes:
[0014] Noise is added to the environmental data, personnel data, and equipment data at the same time to keep the personnel's comfort level unchanged and generate several new data samples;
[0015] A time window of preset length is slid on the original time series of the initial data set, a number of window samples are intercepted, and the samples of different windows are spliced to generate a number of new data samples.
[0016] Preferably, the reward function of the initial reinforcement learning model includes:
[0017] Where t is the time step; r t is the immediate reward obtained at time step t; s t is the state at time step t; a t is the action taken at time step t; w1, w2, w3 are the weight coefficients of comfort, energy consumption and equipment loss respectively; The current state s t and action a t Comfort reward function, energy consumption cost function and equipment loss cost function.
[0018] Preferably, the method of fine-tuning the trained initial reinforcement learning model using the second training data set includes:
[0019] Freeze the feature extraction layers of the environmental data and personnel data of the initial reinforcement learning model, and fine-tune the feature extraction layer of the device data using the second training dataset.
[0020] Preferably, the target model compression method includes:
[0021] Perform weight pruning on the target model, and use the second training data set as a test set to test the performance of the pruned model, repeating the above steps to gradually increase the pruning sparsity until the model performance drops below a first preset threshold;
[0022] Samples are extracted from the second training data set to construct a calibration data set, the pruned target model is statically quantized, and the second training data set is used as a test set to test the performance of the quantized model. When the performance of the quantized model drops within a second preset threshold range, the compression of the target model is completed.
[0023] Preferably, the target model compression method further includes: using a trained initial reinforcement learning model as a teacher model to perform knowledge distillation on the compressed target model.
[0024] Preferably, the method further includes: step S7. maintaining the target model of each edge computing node using a heterogeneous federated learning method.
[0025] Preferably, step S7 includes:
[0026] Step S71: The initial reinforcement learning model trained on the central server is used as the global model, and several edge computing nodes are selected to participate in the global training in each round of communication;
[0027] Step S72. Each edge computing node performs prediction and iterative training of the target model based on the real-time collected environmental data, personnel data, and equipment data, and uploads the current target model Q value when participating in global training;
[0028] Step S73. The central server updates the global model based on all received uploaded Q values and sends the updated global model's environmental data and personnel data feature extraction layer parameters to all edge computing nodes;
[0029] Step S74. The edge computing node updates the target model based on the feature extraction layer parameters of the sent environmental data and personnel data.
[0030] Beneficial effects
[0031] 1. Improved Control Precision and User Comfort: This invention utilizes a distributed control architecture, deploying independent edge computing nodes in each functional area. This allows for real-time control based on local sensor data, enabling a more precise response to dynamic changes in the regional environment and individual needs. Furthermore, by introducing a reinforcement learning model and incorporating a user comfort feedback mechanism, this system achieves refined, adaptive regulation of the HVAC system, significantly enhancing user comfort within the service area.
[0032] 2. Reduced Energy Consumption: The reinforcement learning model employed in this invention can autonomously learn and execute optimal control strategies, minimizing overall HVAC system energy consumption while ensuring user comfort. Independent control of each functional area effectively avoids unnecessary energy waste. Furthermore, the application of model compression technology further reduces the energy consumption of the edge computing nodes themselves.
[0033] 3. Enhanced system reliability: The distributed control architecture effectively mitigates single-point failure risks. Even if a single edge computing node fails, it will not affect the normal operation of HVAC systems in other areas. The introduction of a federated learning mechanism enables edge computing nodes to work together to improve the robustness of the entire system.
[0034] 4. Protect data privacy: This invention adopts a federated learning method. Each edge computing node does not need to upload original data, but only needs to upload model parameters or processed Q values, thereby effectively protecting user data privacy.
[0035] 5. Adaptability to Heterogeneous Environments: This invention supports heterogeneous federated learning, allowing different functional areas to adopt different model structures, thereby better adapting to the specific needs and hardware conditions of each area. The application of technologies such as model fine-tuning and knowledge distillation further improves the control performance of the model in various areas.
[0036] 6. Fast response and low latency: The deployment of edge computing nodes enables control decisions to be generated quickly locally without transmitting data to the cloud, thereby significantly reducing control latency and achieving rapid response to environmental changes.
[0037] 7. Good scalability: This distributed control method has good scalability and can flexibly increase or decrease the area that needs to be controlled. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 The present invention is a flowchart of a method for distributed control of indoor HVAC in a highway service area building provided in a preferred embodiment of the present invention. DETAILED DESCRIPTION
[0039] In order to make the objectives, technical solutions and advantages of the present invention more clear, the present invention is further described below with reference to the accompanying drawings. In the description of the present invention, it should be understood that the terms "upper", "lower", "front", "back", "left", "right", "top", "bottom", "inner", "outer", etc., indicating directions or positional relationships, are based on the directions or positional relationships shown in the accompanying drawings and are only for the convenience of describing the present invention and simplifying the description. They do not indicate or imply that the devices or components referred to must have a specific direction, be constructed and operate in a specific direction. Therefore, they should not be understood as limiting the present invention.
[0040] Example 1
[0041] like Figure 1 As shown, this embodiment provides a method for distributed control of indoor HVAC in buildings in a highway service area, including the following steps:
[0042] S1. Collect environmental data, personnel data, equipment data, and personnel comfort perceptions of various functional areas in highway service area buildings during a preset time period to construct an initial dataset.
[0043] This step collects multi-source heterogeneous data, mainly including the following four dimensions: 1) Environmental parameters: covering key indicators such as temperature, humidity, CO2 concentration, and light intensity, which are used to characterize the physical state of the indoor environment. 2) Personnel activities: including data such as personnel density and personnel flow, which are used to reflect the distribution and activities of personnel in the service area. 3) Equipment status: recording the switch status, operating mode (cooling, heating, ventilation), wind speed, set temperature and other parameters of the heating, ventilation and air conditioning (HVAC) system to reflect the real-time operating status of the HVAC equipment. 4) Personnel thermal comfort: obtained through active feedback (such as questionnaires, interactive evaluation systems) or passive perception (such as computer vision-based behavioral analysis, physiological signal monitoring of wearable devices), etc., to quantify the user's subjective perception of the indoor environment.
[0044] To ensure the timeliness and accuracy of data analysis, all data must be time-synchronized. This means accurately recording the acquisition timestamp of each data point to ensure a one-to-one correspondence between data of different dimensions. The construction of the initial dataset is the foundation for subsequent model training, and its quality and completeness directly impact model performance. Therefore, the data collection process requires the use of high-precision, high-reliability sensors, with a scientifically and rationally distributed distribution to ensure representative data. Furthermore, effective methods must be employed to collect and accurately label occupant thermal comfort data.
[0045] It should be understood that the preset time period refers to a time range that is pre-set based on actual needs and conditions before data collection. The selection of this time range requires comprehensive consideration of multiple factors: first, it must be representative and able to cover various typical operating conditions of the HVAC system in the service area, such as daytime, nighttime, weekdays, holidays, different seasons, etc.; second, the cost and feasibility of data collection must be considered. A time period that is too long will increase the cost of data collection and storage, while a time period that is too short may not be able to obtain enough data; finally, the training requirements of the model must be considered. Too little data may lead to underfitting of the model, while too much data will increase the training time. Preferably, the preset time period can be a few consecutive days, weeks, or even months, or a combination of multiple discontinuous time periods. For example, it can be set to "7 consecutive days, 24 hours a day" or "4 consecutive weeks, Friday, Saturday, and Sunday, 24 hours a day". The specific preset time period needs to be determined based on actual conditions before the project is implemented.
[0046] There are significant differences in the uses, personnel activities and environmental requirements of different functional areas in highway service area buildings. For example, restaurants have a high density of people during peak meal times, and have high requirements for ventilation and temperature; people stay in rest areas for a long time, and have high requirements for temperature stability; bathrooms have high requirements for ventilation and dehumidification; and stores need to maintain appropriate temperature and humidity to attract customers. Traditional centralized HVAC control systems usually adopt a unified control strategy, which cannot take into account these differentiated needs, resulting in some areas being overcooled or overheated, causing energy waste and a decline in user experience. The present invention adopts a distributed control method based on reinforcement learning in subsequent steps, which can automatically optimize the control strategy according to real-time data to achieve smarter and more efficient HVAC control.
[0047] S2. Preprocess the initial dataset to obtain a first training dataset; then divide the first training dataset into multiple second training datasets based on functional area type. Dividing the first training dataset into multiple second training datasets based on functional area type (e.g., restaurant, rest area, store, restroom, etc.) facilitates subsequent training of different models tailored to the characteristics of different areas, thereby improving the model's relevance and accuracy. Each second training dataset contains environmental data, personnel data, equipment data, and comfort data for a specific functional area.
[0048] It should be understood that the specific operations of the preprocessing include missing value processing (such as interpolation and deletion), outlier processing (such as statistical methods and clustering methods), data smoothing (such as mean filtering and median filtering), feature engineering (such as extracting new features and combining features), data standardization / normalization (such as scaling data to a uniform range), and data enhancement (such as adding noise, sliding window cropping, and splicing). These operations can be selectively used according to the specific circumstances of the data.
[0049] The conventional preprocessing methods in the prior art focus on data cleaning and conversion, but rarely involve data generation. Conventional data enhancement techniques, such as rotation, cropping, and flipping in the image field, are mainly applicable to data such as images and text, and rarely consider the characteristics of time series data. In some preferred embodiments, a method for preprocessing the initial data set is provided, specifically including:
[0050] S21. Synchronously add noise to the environmental data, personnel data, and equipment data at the same moment to keep the personnel's comfort level unchanged and generate several new data samples. Synchronously adding noise simulates sensor measurement errors or small fluctuations in the environment. During specific operations, it is necessary to select the appropriate noise type (such as Gaussian noise, uniform noise) and noise amplitude based on the characteristics of different types of data and the actual fluctuation range. For example, Gaussian noise of ±0.5°C can be added to temperature data, and uniform noise of ±2%RH can be added to humidity data. The key is to keep the personnel's comfort level unchanged while adding noise, because the amplitude of the noise is small and not enough to cause significant changes in comfort.
[0051] S22. Slide a time window of preset length across the original time series of the initial dataset, extracting several window samples and concatenating the samples from different windows to generate several new data samples. This step exploits the characteristics of time series data. By sliding the window, the original time series can be divided into multiple subsequences, each of which can serve as an independent sample. Concatenating samples from different windows can generate longer samples with more varied patterns.
[0052] The above preprocessing method is specifically designed for the data characteristics of this scheme (time series data, multivariate data, one-to-one correspondence), taking into account the correlation between data, ensuring that the enhanced data still conforms to physical laws and actual conditions. It is relatively simple to implement and has low computational overhead, but it can effectively expand the data set and improve model performance.
[0053] S3. Build an initial reinforcement learning model on the central server, use the HVAC equipment control parameters as output, and use the first training set to complete pre-training of the initial reinforcement learning model.
[0054] The reinforcement learning model refers to a model that can learn the optimal strategy by interacting with the environment. It is different from the supervised learning model (which requires labeled data) and the unsupervised learning model (which looks for patterns in the data). The reinforcement learning model learns by trial and error based on the feedback (rewards) from the environment. Such as the deep Q network (DQN), the Actor-Critic model, etc. The input of the model is the environmental data (temperature, humidity, CO2 concentration, lighting) of each functional area in the service area, personnel data (personnel density, personnel flow), equipment data (current status) and time information, and the output is the control parameters of the HVAC equipment (switch, mode, wind speed, set temperature). The choice of model needs to be determined based on actual conditions and computing resources, and the present invention does not make further limitations.
[0055] The pre-training refers to the use of a large-scale data set to perform preliminary training on the model before formally training the model. The purpose of pre-training is to allow the model to learn some common features or knowledge, thereby speeding up the subsequent training process and improving model performance. Pre-training is widely used in fields such as natural language processing and computer vision. In the present invention, pre-training refers to the use of a first training set (containing data from all functional areas) to train the initial reinforcement learning model so that it learns a preliminary, general HVAC control strategy. Completion of pre-training means that the performance of the model has reached a certain level and can be used for subsequent fine-tuning or deployment. Usually, whether pre-training is completed can be determined by setting the number of training rounds, the reward value threshold, or observing the model performance curve.
[0056] In reinforcement learning, the design of the reward function is crucial because it directly determines the learning goal and final behavior of the agent. The reward function defines the immediate reward that the agent obtains from the environment at each time step. This reward can be positive (reward), negative (penalty), or zero. The goal of the agent is to maximize the cumulative reward, so the design of the reward function needs to accurately reflect the goal of the task. In some preferred embodiments, taking into account multiple factors such as comfort, energy consumption, and equipment loss costs, the following reward function is designed:
[0057] Where t is the time step; r t is the immediate reward obtained at time step t; s t is the state at time step t; a t is the action taken at time step t; w1, w2, w3 are the weight coefficients of comfort, energy consumption and equipment loss respectively; The current state s t and action a tComfort reward function, energy consumption cost function and equipment loss cost function. The comfort reward reflects the comfort level of the personnel in the current state. The higher the comfort level, the greater the reward. The energy consumption cost function reflects the energy consumption of the HVAC system in the current state. It can be calculated based on the power and operating time of the equipment. The higher the energy consumption, the greater the cost (the reward is negative). The equipment loss cost reflects the loss of the HVAC equipment in the current state. It is usually calculated based on the number of starts and stops, the number of mode switches and the operating time of the equipment. The greater the loss, the greater the cost (the reward is negative). By adjusting the weight coefficient, the optimization goal of the model can be changed. For example, more emphasis can be placed on comfort, energy saving or equipment life. The design of the entire reward function needs to comprehensively consider multiple factors and be optimized according to actual operating conditions.
[0058] S4. Copy multiple trained initial reinforcement learning models, and use the second training data set to fine-tune the trained initial reinforcement learning models respectively to obtain a target model for each functional area.
[0059] The "multiple" here refers to the same number as the functional areas of the service area, with one model copy corresponding to each functional area. Fine-tuning refers to continuing to train the model using a new dataset based on the pre-trained model, but usually only training some layers or using a smaller learning rate. The purpose of fine-tuning is to adapt the model to the new data distribution while retaining the general knowledge learned by the pre-trained model. In this solution, the purpose of fine-tuning is to adapt the model to the environmental characteristics, personnel behavior, and equipment configuration of each functional area. The fine-tuning process still uses the reinforcement learning algorithm for training, but a smaller exploration rate can be used to make greater use of the learned strategy. After fine-tuning is completed, each functional area obtains a target model specifically optimized for that area.
[0060] It should be understood that although there are differences in the environmental data and personnel data (such as temperature, humidity, and personnel density) in different functional areas of the highway service area, the basic relationship between them and HVAC control is similar. For example, cooling is required when the temperature rises, and ventilation needs to be strengthened when the personnel density increases. These basic relationships have been learned in the pre-training stage and do not need to be repeated in the fine-tuning stage. However, there may be large differences in the equipment data (such as equipment type and performance parameters) in different areas. These differences are region-specific and need to be learned in the fine-tuning stage. Furthermore, the initial reinforcement learning model uses a deep neural network, and different network layers are responsible for extracting different types of features. The feature extraction layers of environmental data and personnel data are usually located at the lower layers of the network, and they extract more general features; while the feature extraction layers of equipment data are usually located at the upper layers of the network, and they extract more task-specific features.
[0061] Therefore, in some preferred embodiments, consideration is given to freezing the feature extraction layers for environmental and personnel data in the initial reinforcement learning model, and fine-tuning the feature extraction layer for equipment data using the second training dataset. During the pre-training phase, the model has already learned some common relationships between environmental and personnel data and HVAC control using the first training dataset, which contains data from all functional areas. These common relationships are similar across different functional areas, so the corresponding feature extraction layers can be frozen to preserve this common knowledge. However, the equipment configuration and performance of different functional areas may vary significantly, so the second training dataset (divided by functional area) is needed to fine-tune the feature extraction layer for equipment data to adapt the model to the specific equipment conditions in each area. Specifically, freezing the feature extraction layers for environmental and personnel data means that the parameters of these layers remain unchanged during the fine-tuning process; however, the parameters of the feature extraction layer for equipment data are updated based on the second training dataset. This differentiated fine-tuning strategy preserves the common knowledge of the pre-trained model while adapting the model to the specificities of different areas, achieving a balance between model performance and training efficiency.
[0062] S5. Compress the target model and deploy it to the edge computing nodes of each functional area.
[0063] Edge computing nodes refer to computing devices deployed in various functional areas, responsible for receiving sensor data, running target models, generating control strategies and sending them to HVAC equipment. Edge computing nodes have certain computing, storage and network connection capabilities, and can process data locally without transmitting all data to cloud servers (data centers). Due to the limited computing power, memory and storage space of edge computing nodes, directly deploying the original model may cause the model to run slowly, occupy too many resources, or even fail to run. Therefore, the target model needs to be compressed. Model compression refers to reducing the size of the model and reducing the computational complexity of the model while ensuring that the model performance remains basically unchanged. Common compression methods include pruning, quantization, knowledge distillation, etc. The compressed model is smaller, faster, and more suitable for deployment on edge computing nodes.
[0064] In some preferred embodiments, a target model compression method is provided including:
[0065] S51. Perform weight pruning on the target model, and use the second training data set as a test set to test the performance of the pruned model. Repeat the above steps to gradually increase the pruning sparsity until the model performance drops below a first preset threshold. This step removes connections with smaller weights in the model. These connections have little effect on the output of the model. Removing them can reduce the model size without significantly affecting the model performance. The first preset threshold is a hyperparameter used to control the degree of pruning and can be set by a person skilled in the art according to actual needs.
[0066] S52. Extract samples from the second training data set to construct a calibration data set, perform static quantization on the pruned target model, and use the second training data set as a test set to test the performance of the quantized model. When the performance of the quantized model drops within a second preset threshold, the compression of the target model is completed. Wherein, the static quantization refers to converting the weights and activation values in the model from floating point numbers (usually 32-bit floating point numbers) to low-precision integers (usually 8-bit integers). Static quantization requires the use of a calibration data set to determine the quantization parameters (scaling factor and zero point). The second preset threshold is also a hyperparameter used to control the degree of quantization.
[0067] In other preferred embodiments, it is also possible to consider using the knowledge distillation technology commonly used in supervised learning tasks to compress the model, or as a supplement to the above compression method, specifically including:
[0068] S53. Use the trained initial reinforcement learning model as the teacher model to perform knowledge distillation on the compressed target model. Specifically, the teacher model (pre-trained model) is used to predict the input state to obtain the Q value of each action (or the soft Q value after softmax and temperature coefficient processing). These Q values represent the knowledge of the teacher model. The student model (compressed model) is trained not only according to the rewards of the environment (the standard training process of reinforcement learning), but also according to the Q value of the teacher model.
[0069] Those skilled in the art will recognize that in conventional knowledge distillation, the teacher model is typically a high-performance model trained on a large dataset. In this solution, the teacher model is a pre-trained reinforcement learning model trained on data covering all functional areas, learning a universal HVAC control strategy. Furthermore, in conventional knowledge distillation, the student model is typically a model with a simpler structure and fewer parameters. In this solution, the student model is the target model that has undergone pruned and quantized processing, and is already a compressed model.
[0070] S6. The edge computing node collects environmental data, personnel data, and equipment data from each functional area in real time, inputs the compressed target model to obtain the control parameters of each HVAC device, and sends the control parameters to the HVAC equipment control module for execution. Specifically, the edge computing node performs inference calculations based on the input data and outputs the control parameters of each HVAC device (i.e., actions in reinforcement learning), such as: on / off, cooling / heating / ventilation mode, wind speed level, set temperature value, and further converts the control parameters into control instructions, which are sent to the HVAC equipment control module. After receiving the instructions, the control module performs the corresponding operations to adjust the operating status of the HVAC equipment.
[0071] In other preferred embodiments, in order to enable the target model of each edge computing node to continuously adapt to environmental changes and changes in user needs, while at the same time being able to learn useful knowledge from data in other areas, it is considered to use heterogeneous federated learning methods to continuously maintain and update the target models deployed on each edge computing node. It should be understood that conventional federated learning usually assumes that all user terminals use the same model structure. However, the present invention uses different model structures for different edge computing nodes (after fine-tuning, the models of each area may be different). This is because the equipment configuration and environmental characteristics of different functional areas may vary greatly, and using the same model structure may not achieve the best results. Therefore, it is considered to use a heterogeneous federated learning method to maintain the target model of each edge computing node, which specifically includes the following steps:
[0072] Step S71: The initial reinforcement learning model trained on the central server is used as the global model, and several edge computing nodes are selected to participate in the global training in each round of communication.
[0073] Step S72: Each edge computing node performs prediction (i.e., selecting actions based on the current state) and iterative training of the target model (i.e., updating model parameters based on environmental rewards) based on the real-time collected environmental, personnel, and device data. It also uploads the current target model Q-value when participating in global training. Uploading Q-values instead of model parameters is an application of knowledge distillation, which can better handle model heterogeneity, reduce communication overhead, and protect data privacy.
[0074] Step S73. The central server updates the global model based on all the uploaded Q values received, and sends the feature extraction layer parameters of the updated global model's environmental data and personnel data to all edge computing nodes. The specific updating method may be to calculate the average Q value, and then use the average Q value to guide the training of the global model (similar to the teacher model in knowledge distillation). It should be understood that this step only sends down some parameters in order to retain the general knowledge of the global model while allowing each edge computing node to retain the characteristics of its region-specific model. This strategy of partial parameter sharing can ensure that the model learns general knowledge while adapting to the particularities of different regions.
[0075] Step S74. The edge computing node updates the target model based on the feature extraction layer parameters of the sent environmental data and personnel data.
[0076] The above steps are repeated continuously. The core idea is that each edge computing node uses local data for training and communicates with the central server regularly to share knowledge but not data, thereby achieving continuous improvement of the model while protecting data privacy.
[0077] The basic principles, main features, and advantages of the present invention are shown and described above. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The above embodiments and descriptions are merely illustrative of the principles of the present invention. Various changes and modifications may be made to the present invention without departing from the spirit and scope of the present invention. Such changes and modifications are intended to fall within the scope of the present invention. The scope of protection claimed in the present invention is defined by the appended claims and their equivalents.
Claims
1. A distributed control method for indoor HVAC in a high-speed service area building, characterized in that: Including steps: S1. Collect environmental data, personnel data, equipment data, and personnel comfort perceptions of various functional areas in the highway service area buildings during a preset time period to construct an initial data set; S2. Preprocessing the initial data set to obtain a first training set; dividing the first training set into multiple second training data sets according to the functional area type; S3. Build an initial reinforcement learning model on the central server, use the HVAC equipment control parameters as output, and complete the pre-training of the initial reinforcement learning model using the first training set; S4. Copy multiple trained initial reinforcement learning models, and use the second training data set to fine-tune the trained initial reinforcement learning models to obtain a target model for each functional area; S5. Compressing the target model and deploying it to the edge computing nodes of each functional area; S6. The edge computing node collects environmental data, personnel data, and equipment data of each functional area in real time, inputs the compressed target model to obtain control parameters of each HVAC equipment, and sends the control parameters to the HVAC equipment control module for execution.
2. The distributed control method for indoor HVAC in a highway service area building according to claim 1, characterized in that: The method for preprocessing the initial data set includes: Noise is added to the environmental data, personnel data, and equipment data at the same time to keep the personnel's comfort level unchanged and generate several new data samples; A time window of preset length is slid on the original time series of the initial data set, a number of window samples are intercepted, and the samples of different windows are spliced to generate a number of new data samples.
3. The distributed control method for indoor HVAC in a highway service area building according to claim 1, characterized in that: The reward function of the initial reinforcement learning model includes: Where t is the time step; r t is the immediate reward obtained at time step t; s t is the state at time step t; a t is the action taken at time step t; w1, w2, w3 are the weight coefficients of comfort, energy consumption and equipment loss respectively; The current state s t and action a t Comfort reward function, energy consumption cost function and equipment loss cost function.
4. The distributed control method for indoor HVAC in a highway service area building according to claim 1, characterized in that: The method of fine-tuning the trained initial reinforcement learning model using the second training data set includes: Freeze the feature extraction layers of the environmental data and personnel data of the initial reinforcement learning model, and fine-tune the feature extraction layer of the device data using the second training dataset.
5. The distributed control method for indoor HVAC in a highway service area building according to claim 1, characterized in that: The compression method of the target model includes: Perform weight pruning on the target model, and use the second training data set as a test set to test the performance of the pruned model, repeating the above steps to gradually increase the pruning sparsity until the model performance drops below a first preset threshold; Samples are extracted from the second training data set to construct a calibration data set, the pruned target model is statically quantized, and the second training data set is used as a test set to test the performance of the quantized model. When the performance of the quantized model drops within a second preset threshold range, the compression of the target model is completed.
6. The distributed control method for indoor HVAC in a highway service area building according to claim 5, characterized in that: The target model compression method further includes: using a trained initial reinforcement learning model as a teacher model to perform knowledge distillation on the compressed target model.
7. The distributed control method for indoor HVAC in a highway service area building according to claim 1, characterized in that: It also includes: step S7. using heterogeneous federated learning method to maintain the target model of each edge computing node.
8. The distributed control method for indoor HVAC in a highway service area building according to claim 7, characterized in that: The step S7 comprises: Step S71: The initial reinforcement learning model trained on the central server is used as the global model, and several edge computing nodes are selected to participate in the global training in each round of communication; Step S72. Each edge computing node performs prediction and iterative training of the target model based on the real-time collected environmental data, personnel data, and equipment data, and uploads the current target model Q value when participating in global training; Step S73. The central server updates the global model based on all received uploaded Q values and sends the updated global model's environmental data and personnel data feature extraction layer parameters to all edge computing nodes; Step S74. The edge computing node updates the target model based on the feature extraction layer parameters of the sent environmental data and personnel data.