A deep learning-based intelligent building adaptive comprehensive management and control method and system
By using deep learning technology, combined with neural clustering, Transformer models and LSTM models, high-precision prediction of the state of smart building environments and accurate prediction of user behavior are achieved. This solves the problems of insufficient fusion of multi-source data and poor adaptability of prediction models, and improves the system's adaptive optimization capabilities and user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- LONG TECH CO LTD
- Filing Date
- 2025-05-19
- Publication Date
- 2026-05-08
AI Technical Summary
Existing smart building environmental management solutions suffer from strong spatiotemporal heterogeneity of multi-source sensing data, limited prediction accuracy and generalization ability, lack of comprehensive utilization of local spatial aggregation patterns and frequency domain information, and lack of linkage consideration for complex environmental evolution and user behavior response at the system control level, resulting in lagging regulation, high energy consumption and poor user experience.
A deep learning-based approach is adopted, which combines neural clustering and Transformer models with frequency domain compression technology to predict the state of the building environment. The LSTM model is used to predict the future path of users, and deep reinforcement learning and meta-learning mechanisms are combined to adjust control actions, monitor abnormal situations in real time, and optimize control strategies.
It improves data fusion capabilities, enhances prediction accuracy and behavioral adaptability, enables adaptive optimization and continuous adjustment of the model, and improves the system's response speed and robustness.
Smart Images

Figure CN120540074B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of smart building technology, and in particular to a method and system for adaptive integrated management and control of smart buildings based on deep learning. Background Technology
[0002] With the rapid development of information technology and intelligent sensing technology, smart buildings, as an important component of new urban construction, have become a key means to improve building operational efficiency, energy utilization, and human comfort. However, traditional building automation systems mainly rely on rule presets or static scheduling methods for environmental control, lacking real-time perception and dynamic response capabilities of building space status, making it difficult to adapt to the development trend of diversified usage scenarios and complex human behaviors. In recent years, the integrated application of technologies such as Building Information Modeling (BIM), the Internet of Things (IoT), edge computing, and artificial intelligence has provided new ideas for the comprehensive management and control of smart buildings.
[0003] However, existing smart building environment management solutions still have many limitations. First, the strong spatiotemporal heterogeneity and inconsistent quality of multi-source sensing data make environmental state modeling difficult. Traditional methods often ignore the topological characteristics of building spaces and the patterns of personnel flow, making it difficult to capture the dynamic relationships between nodes. Second, existing models, when performing building environment prediction and behavior modeling, usually focus on time series data, lacking comprehensive utilization of local spatial clustering patterns and frequency domain information, resulting in limited prediction accuracy and generalization ability. Furthermore, the system control layer generally adopts control methods based on predefined strategies or linear optimization, lacking consideration of the linkage between complex environmental evolution and user behavior responses. In actual operation, this may lead to problems such as control lag, high energy consumption, or poor user experience. Especially in abnormal scenarios such as sudden changes in user behavior or model mismatch, the lack of effective anomaly diagnosis and policy adaptation mechanisms restricts the security and robustness of smart building systems. Therefore, there is an urgent need for a new comprehensive building management method that features sufficient data fusion, high prediction accuracy, strong behavioral adaptability, and sustainable self-optimization. Summary of the Invention
[0004] In view of the aforementioned existing problems, the present invention is proposed.
[0005] Therefore, this invention provides a smart building adaptive integrated management and control method based on deep learning, which solves the problems of insufficient data fusion, poor adaptability of prediction models, weak behavioral adaptability, and static and rigid optimization.
[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:
[0007] In a first aspect, the present invention provides a smart building adaptive integrated management and control method based on deep learning, which includes,
[0008] Multi-source data is collected and preprocessed to construct a building space map structure. Building environment status is predicted based on neural clustering and Transformer model combined with frequency domain compression technology.
[0009] The multi-source data includes environmental sensor data and video surveillance data;
[0010] Based on the prediction results, the LSTM model is used to predict the user's future path, and deep reinforcement learning is used to output control actions based on the environmental state and the user's future path.
[0011] Real-time monitoring of abnormal situations in the implementation of control measures; adjustment of control actions based on meta-learning mechanism; and uploading and storage of the adjusted control actions.
[0012] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method of the present invention, the step of predicting building environment status based on neural clustering and Transformer model combined with frequency domain compression technology includes:
[0013] Using the architectural spatial graph structure G, a graph neural network is used to fuse the feature vectors of each node in the graph structure with those of its surrounding nodes to obtain an enhanced feature vector representation x. i (t)′, forming the enhanced time series matrix B i The structure is divided into multiple dynamically similar clusters using neural clustering. k cluster centers are initialized using k-means++, and the state x after structural enhancement is calculated. i (t)′ and cluster center C l membership degree u ij Assign the cluster center with the highest membership degree to form a cluster sequence set H. Transform the cluster sequence set to the frequency domain, compress it, and then restore it to obtain the reconstructed compressed time series H′.
[0014] The compressed time series H' is input into the Transformer model encoder structure. The dependency relationship between states at each time step is modeled through the temporal self-attention mechanism to generate the building environment state prediction result sequence Y. The total loss function L is calculated based on the prediction result to optimize the Transformer model parameters and obtain the final building environment state prediction result Y′.
[0015] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method of the present invention, wherein: based on the prediction results, the prediction of the user's future path using an LSTM model refers to inputting the building environment state prediction result sequence Y′ into an attention weighting module to obtain an attention score a. t ;
[0016] Attention score sequences are obtained by calculating the attention score of the environment state at each time step and then converted into standardized weights p. t To obtain a new weighted state sequence Y * The hidden state h at each step is obtained by inputting it into a variant LSTM unit. t ;
[0017] After selecting the hidden state at the last time step as the overall prediction environment perceived by the user, the resulting internal state vector U is input to the fully connected layer, which outputs the predicted user behavior value P. t ;
[0018] The loss function between the predicted user behavior and the actual observed behavior is calculated. The gradient of the loss function with respect to the model parameters is calculated through backpropagation. The parameters are iteratively updated using the Adam optimizer for gradient descent.
[0019] Treating the model parameters in a neural network as individuals, we optimize the model parameters using an adaptive genetic algorithm and retain the individuals with the best fitness. The final optimal parameter solution is obtained by global optimization using the APSO algorithm. Predicting user behavior by combining environmental state prediction results
[0020] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method of the present invention, wherein: the control action is output based on environmental state prediction and user future path through deep reinforcement learning, and the environmental state prediction result Y′ is compared with the user behavior prediction result. Combine to construct state vector Define the target control variables of the required control equipment and construct the continuous value action space Ψ. t Calculate the joint reward function The weighted environment state vector y * t As input, control action As output, the SAC algorithm is used to train the control policy, and the expected target value of the policy parameter π is obtained by maximizing the expected reward function.
[0021] Continuously optimize the desired target value during training. Get the current strategy parameters The state vector As the policy function π * The input and output are the probability distributions of control actions in this state. Select the action with the highest probability density using the highest probability method. After the control action is generated, the instruction is converted into an MQTT protocol structure according to the control parameter format of each device, and sent to the target execution device through the device gateway. After the control is executed, the entire process log of the current round of control strategy is automatically recorded.
[0022] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method of the present invention, wherein: the real-time monitoring of abnormal situations in the implementation of management and control, and the adjustment of management and control actions in conjunction with a meta-learning mechanism, refers to the use of an anomaly deviation metric to dynamically detect abnormal values. When an abnormal deviation is detected, the MAML fast adjustment mechanism is used to automatically migrate from the current control task to the output of the new scenario control and update the obtained parameter ω'.
[0023] The probability distribution of action selection is calculated by inputting the current building environment state and using the updated policy network parameters ω′. By sampling to select the optimal action, executing the selected action, and receiving a reward from the environment, the next decision is made based on the new state.
[0024] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method described in this invention, the step of uploading and storing the adjustment and control actions refers to converting the control parameters of each device into a unified control instruction structure format and binding metadata, encapsulating the triggering background information of each action together with the action, forming an "action + context data packet" as a control execution unit, and synchronously organizing each stage of the control process into a structured record unit and pushing it to the event log module, and then batch uploading it to the central database after being uniformly organized by the data management module.
[0025] As a preferred embodiment of the deep learning-based intelligent building adaptive integrated management and control method of the present invention, the step of collecting multi-source data and preprocessing it to construct a building spatial structure diagram refers to extracting room units and connection relationships from the building's BIM model, constructing a node set, an edge set ε, and obtaining an adjacency matrix.
[0026] Multi-source data is collected via temperature and humidity sensors, noise sensors, and high-definition cameras. Data is uploaded and controlled via the MQTT protocol, encoded in a unified format through a central data platform, and node state vectors are extracted. A sliding window mechanism is used for time synchronization and alignment to form a feature vector X(t). Missing data is repaired using nearest-neighbor imputation, and Z-score standardization is performed to construct a standardized feature matrix.
[0027] Construct time series matrix B based on the standardized feature vectors. i Combined with adjacency matrix Establish the spatial graph structure G.
[0028] Secondly, this invention provides a deep learning-based intelligent building adaptive integrated management and control system, comprising:
[0029] The graph construction and preprocessing module is used to parse building structures and multi-source data to generate standardized graph structures and feature sequences.
[0030] The feature enhancement and compression modeling module is used to extract key trend features of dynamic environments using graph neural networks and clustering compression.
[0031] The state prediction modeling module is used to predict environmental states based on Transformer and model time dependencies and sequence relationships.
[0032] The behavior-aware prediction module is used to fuse attention and LSTM to model user paths and output behavior probability distributions.
[0033] The intelligent control and execution module is used to make decisions on equipment control using the SAC algorithm, and combines state and behavior prediction optimization strategies to generate the optimal control scheme for real-time regulation.
[0034] Thirdly, the present invention provides a computer device, including a memory and a processor, wherein the memory stores a computer program, wherein: when the computer program is executed by the processor, it implements any step of the deep learning-based intelligent building adaptive integrated management and control method described in the first aspect of the present invention.
[0035] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements any step of the deep learning-based adaptive integrated management and control method for smart buildings as described in the first aspect of the present invention.
[0036] The beneficial effects of this invention are as follows: This invention effectively reduces the time series dimension and removes redundant trend information through neural clustering and DCT frequency domain compression mechanisms, enhancing the model's prediction stability and generalization ability over long time spans. By using adaptive genetic algorithms and APSO algorithms to globally optimize the LSTM model parameters, it achieves optimal model search that escapes local minima and converges faster, thereby enhancing the model's generalization ability and prediction accuracy for changes in user behavior, significantly improving the performance and adaptive optimization ability of the user behavior prediction model. Through the MAML fast parameter update mechanism, policy transfer is achieved, enabling the control model to adapt instantly under abnormal conditions, improving response speed, and giving it continuous optimization capabilities in dynamic scenarios. Attached Figure Description
[0037] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0038] Figure 1 This is a flowchart of a deep learning-based adaptive integrated management and control method for smart buildings in Example 1.
[0039] Figure 2 This is a structural diagram of a deep learning-based intelligent building adaptive integrated management and control system in Example 1.
[0040] Figure 3 This is a diagram illustrating the anomaly adjustment mechanism of a deep learning-based adaptive integrated management and control method for smart buildings in Example 1. Detailed Implementation
[0041] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
[0042] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.
[0043] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.
[0044] Example 1, referring to Figures 1-3 This is the first embodiment of the present invention, which provides a smart building adaptive integrated management and control method based on deep learning, including the following steps:
[0045] S1. Collect multi-source data, preprocess it to construct the building space map structure, and predict the building environment status based on neural clustering and Transformer model combined with frequency domain compression technology.
[0046] Specifically, collecting multi-source data and preprocessing it to construct an architectural spatial structure diagram refers to extracting room units and their connections from the building's BIM model, and constructing a set of nodes (rooms) I = {i1, i2, ..., i...}. n}, where n is the total number of nodes, and each node corresponds to a room unit;
[0047] The physical pathways between node pairs are obtained through the BIM model, an edge set ε is constructed, and the edge connection relationships between regions are constructed based on the reachability principle to obtain the adjacency matrix. Where n is the total number of nodes;
[0048] Temperature, lighting, and noise levels within the building space are collected using temperature, humidity, and noise sensors. High-definition cameras monitor personnel movement, and image recognition technology extracts personnel density and distribution. Data is uploaded and controlled via the MQTT protocol. The collected data is transmitted to a central data platform for unified encoding (device ID, timestamp, data type, sample value) to ensure data parsing and scalability. Node state vectors are extracted, and a sliding window mechanism is employed with a set window length. Time synchronization and alignment are performed. Each node generates a feature vector X(t) (temperature, illumination, noise, and number of people) at each time step. Missing data is repaired using nearest-neighbor imputation to ensure data integrity at each time step. Z-score standardization is then performed, and the standard feature vectors of all nodes are combined into a feature matrix. Where n is the total number of nodes, and d is the number of feature dimensions of each node at time t;
[0049] Construct a time series matrix based on the standardized feature vectors. Where, x i (t) is the standardized feature vector of node i at time t, a is the number of historical time steps, and d is the number of feature dimensions of node i at time t;
[0050] Combined with adjacency matrix Establish a spatial graph structure G, and use a graph attention mechanism to calculate the attention weights between node i and its neighbor node j to enhance the node state representation ability:
[0051]
[0052] Where, α ij Let N(i) be the attention weight of node i to node j, and let N(i) be the set of neighbors of node i. ij It is the attention score of node i to its node j, representing the strength of the relationship between the two;
[0053] e ij The calculation formula is:
[0054]
[0055] Where c is a learnable vector, || denotes the concatenation operation, and W is a linear transformation matrix.
[0056] By leveraging the structured spatial information in BIM, a structured abstract model of building space is achieved, providing a standardized spatial reference for the unified mapping of multi-source heterogeneous sensor data. Multi-source data within the building space is acquired through various sensors and cameras, enabling multi-dimensional perception of the spatiotemporal state within the building. This allows each node to express real-time environmental and behavioral data. Through a sliding window mechanism and missing data repair, the system's ability to handle data timeliness, continuity, and anomaly robustness is improved. Simultaneously, standardized processing enhances the consistency of feature distribution, improving model training stability and generalization ability. A graph attention mechanism dynamically adjusts the influence weights of adjacent nodes on the state of the target node, breaking through the static assumptions of traditional graph convolution methods regarding adjacency relationships and significantly improving the system's accuracy in modeling complex spatial interactions and influence paths.
[0057] Furthermore, the prediction of built environment status based on neural clustering and Transformer models combined with frequency domain compression techniques includes,
[0058] By using the architectural spatial graph structure G, a graph neural network is employed to fuse the feature vectors of each node in the graph structure with those of its surrounding nodes, thereby enhancing its spatial expressive power.
[0059]
[0060] Where, x i (t)′ is the enhanced feature vector representation, N(i) is the set of neighboring nodes of node i, and x j (t) is the feature vector of node j at time t, α ij These are the attention weights, and σ is the activation function.
[0061] The enhanced feature vector x i (t)′ is replaced into the time series matrix to form the enhanced time series matrix B. i ′, through neural clustering, the enhanced sequence B i The clusters are divided into multiple dynamically similar cluster blocks to improve modeling efficiency and expressiveness. k-means++ is used to initialize k cluster centers, and the state x after structural enhancement is calculated. i (t)′ and cluster center C l Membership degree:
[0062]
[0063] Among them, u ij It is the eigenvector x i (t)′ belongs to the membership degree of the cluster center, C lIt is the l-th cluster center, ||x i (t)′-C l || 2 It is the eigenvector x i The squared Euclidean distance from (t)′ to the cluster center;
[0064] Assign the cluster center with the highest membership degree to each feature vector to form a set of cluster sequences. The cluster sequence is transformed to the frequency domain, compressed, and then restored to reduce redundant features while retaining the main trends. A discrete cosine transform is then performed on each cluster block.
[0065]
[0066] in, is the low-frequency component of the l-th cluster center, and f is the frequency domain sub-label;
[0067] The first r low-frequency components are retained using the cumulative energy retention method. Recover the sequence length using inverse transform:
[0068]
[0069] Where H′ is the reconstructed compressed time series;
[0070] The compressed time series H' is input into the Transformer model encoder structure to capture long-term dependencies. A temporal self-attention mechanism is used to model the dependencies between states at each time step. For each time step, each sequence is embedded as Q (query), K (key), and V (value) using three sets of weight matrices.
[0071] Q = H'W Q K = H′W K V=H′W V
[0072] Where H′ is the compressed time series, W Q W K W V It is a learnable linear transformation matrix;
[0073] A weighted representation is obtained by performing scaled dot product attention:
[0074]
[0075] Here, Attention(Q,K,V) is the weighted value vector, where Q,K,V are the query vector, key vector, and value vector, respectively. It is the square root of the dimension of the key vector, used to scale the dot product result to prevent the value from becoming too large. K TIt is the transpose of the key vector K, QK T It is the dot product of the query vector Q and the key vector K;
[0076] A multi-head attention mechanism is employed, concatenating the outputs of all attention heads together and outputting a mapping matrix. Perform a linear transformation to obtain the overall output of the attention mechanism:
[0077]
[0078] Among them, head m =Attention(Q) m ,K m V m ), It is an output mapping matrix that connects the various headers and generates the final output;
[0079] The overall output of the attention mechanism is residually connected to the original input (at each time step) and then normalized. The input feedforward network is then subjected to another residual connection and normalization. This process is repeated for D layers (each layer independently performs self-attention computation and feedforward processing, with the output of the previous layer serving as the input of the next). The output of the final Transformer encoder layer is the final temporal context representation Z (containing the semantic information of each time step in the global context, serving as the input to the subsequent decoder). The query template matrix Q is then set. pred Parallel prediction of future states is performed, and the predictions are input into the cross-attention module of the decoder along with the context representation Z.
[0080]
[0081] Among them, Cross Attention(Q pred (Z) is the query template matrix Q pred The correlation between Z and the temporal context representation;
[0082] Cross Attention (Q) based on correlation using a feedforward neural network pred Further processing (Z) enhances the model's nonlinear expressive power. After processing with cross-attention and feedforward networks, it is transformed through a linear projection layer to generate a sequence of predicted building environment conditions, Y = [y1, y2, ..., y]. t ], where y t It is the building environment state vector at time t;
[0083] Based on the prediction results, the total loss function is calculated to optimize the Transformer model parameters, ensuring that the model can accurately predict changes in the state of the built environment.
[0084] L=μ1Lsim +μ2L ord +μ3L pred
[0085] Where L is the total loss function, L sim It is the similarity loss between nodes and cluster centers, L ord It is the loss that preserves the ranking structure of cluster centers, L pred It represents the prediction error, and μ1, μ2, and μ3 are weighting coefficients set through an adaptive mechanism.
[0086] L sim The calculation formula is:
[0087]
[0088] Among them, h o It is the o-th sample (the feature vector of a node at a certain time), C c(o) c(o) is the cluster center to which sample o belongs, and c(o) is the cluster number to which sample o belongs;
[0089] L ord The calculation formula is:
[0090]
[0091] Among them, C l and C k These are the l-th and k-th cluster centers, respectively, and δ is the ranking tolerance threshold.
[0092] L pred The calculation formula is:
[0093]
[0094] Among them, y' t It is the eigenvalue y that is predicted at time t. t is the true feature value at time t, and P is the total number of predicted future time steps;
[0095] The backpropagation algorithm is used to calculate the gradient of the Transformer model parameters based on the total loss function, update the model parameters, and reduce the loss. When the rate of descent of the total loss function tends to stabilize, convergence stops, and the final predicted result of the built environment state, Y′=[y′1,y′2,...,y′], is output. t ].
[0096] By fusing node features with feature vectors of surrounding nodes using graph neural networks, the expressive power of node features in spatial modeling is enhanced, overcoming the problem of excessive independence of single-node features and effectively improving the prediction accuracy of the model. Through feature enhancement and clustering, the potential correlations between features are extracted and structurally expressed. Discrete cosine transform reduces data volume and computational overhead while maintaining key features, enhancing the model's ability to capture long-term trends. Self-attention mechanism captures correlation features between different time steps, enhancing the model's understanding of long-term dependencies and preventing the loss of long-term dependencies in traditional sequence models. Multi-head mechanism parallel learning of multiple relational features effectively improves the diversity and stability of feature learning. Through multi-layer Transformer encoder stacking, a global understanding of the changing patterns of the built environment is obtained. By integrating feature similarity loss, cluster center ranking loss, and prediction error, prediction accuracy and feature consistency are ensured, model performance is optimized, and prediction results are more consistent with actual environmental changes.
[0097] S2. Based on the prediction results, use the LSTM model to predict the user's future path, and use deep reinforcement learning to output control actions based on the environmental state and the user's future path.
[0098] Specifically, based on the prediction results, the LSTM model is used to predict the user's future path, which refers to the sequence of predicted building environment status results Y′=[y′1,y′2,...,y′] t The input attention weighting module takes the environmental state at each time step as input and feedforward attention neural unit to obtain the attention score 'a'. t :
[0099]
[0100] Where, y′ t X is the state vector of the building environment at time t. a y It is the attention transformation weight matrix, b a It is the bias term, tanh(·) is the hyperbolic tangent activation function, V a It is a projection vector used to map the high-dimensional attention representation to a scalar;
[0101] The attention score sequence {a1, a2, ..., a} is obtained by calculating the attention score of the environment state at each time step. t The attention scores at different time steps are transformed into standardized weights (normalized) using the Softmax function, thus projecting the attention scores into the probability space and representing the proportion of the environmental state at each time step in the overall representation.
[0102]
[0103] Where, p t These are the standardized attention weights at time t, when p t ∈(0,1) and the sum of all standardized attention weights is 1, which constitutes a probability distribution;
[0104] Based on standardized attention weight p t The predicted environmental state sequence is weighted to obtain a new weighted state sequence Y. * =[y * 1,y * 2,...,y * t ]:
[0105] y * t =p t ⊙y t
[0106] Among them, Y * This is the sequence of environmental states after attention-weighted processing, which will serve as the final input for user behavior modeling. * t It is the weighted environment state vector, retaining the same structural dimensions as the original state, and ⊙ is element-wise dimension-wise multiplication;
[0107] The obtained weighted environmental state sequence Y * =[y * 1,y * 2,...,y * t The hidden states are sequentially input into the variant LSTM unit and processed step-by-step to obtain the hidden state at each step.
[0108]
[0109] Among them, h t It is in a hidden state, d t i t c t ,c' t o t These are the forget gate, input gate, candidate state, cell state update, and output gate, respectively. * t h is the weighted environment state vector at time t. t-1 and h t It represents the hidden state between the previous and current time steps, (·) is the Sigmoid activation function, and M... * s * These are the weights and biases of each gate;
[0110] After selecting the hidden state at the last time step as the internal state vector U = h after considering the overall prediction environment perceived by the user, a more accurate and accurate prediction method is formed. t It captures the overall response characteristics of the user to the prediction of the entire environmental state, and sets the internal state vector U = h t The input is fed into a fully connected layer to map the potential state space to the explicit behavior space, and the output is the predicted user behavior at time t.
[0111]
[0112] Among them, P t Z is the predicted value of the user's behavior at the next time step. l It is the weight matrix of the fully connected layer. It is a bias term;
[0113] By collecting ξ user behavior samples (each sample corresponds to a set of real behavior labels and predicted behavior results), the loss function (mean squared error) between the predicted user behavior values and the actual observed behavior is calculated, driving the backpropagation and optimization of the entire model parameters:
[0114]
[0115] in, It is the first Predicted behavior of a sample at time t It is the first The actual behavior of a sample at time t;
[0116] The average of the squared errors of all samples is used to construct the loss function for model training, thus obtaining a measure of the overall behavior prediction performance.
[0117]
[0118] The gradient of the loss function with respect to the model parameters is calculated through backpropagation. The Adam optimizer is used for iterative updates of the gradient descent, enabling joint training of the attention network, LSTM units, and fully connected layer parameters, ultimately minimizing the overall prediction error.
[0119]
[0120] Where θ is the set of trainable parameters for the entire model (including the attention network, LSTM network, and fully connected layers);
[0121] An adaptive genetic algorithm is used to optimize the model parameters in the neural network, thereby minimizing the prediction error. The parameters in the trainable parameter set θ (weights and biases in the LSTM) are linearly encoded and initialized to generate an initial population. in, It is the first A set of parameters;
[0122] Each initialized individual (parameter) is evaluated to determine its fitness. The fitness level determines the survival probability of the individual. Mean squared error is used as the fitness function to measure the difference between the neural network's predictions and the actual results.
[0123]
[0124] in, It is the first The mean squared error (fitness function) of a set of parameters. Is the model in the first Under the parameter set, for the first Prediction results for each sample It is the first The actual behavior of a sample at time t;
[0125] Based on the fitness calculated for each parameter set, a roulette wheel is used to select the individual with the highest fitness as the parent to generate the next generation of offspring. For the selected parent individual, a crossover operation is performed on the parent individual's parameters to generate new offspring individuals. and The crossover probability is set by the number of generations to avoid excessive crossover that could slow down the population convergence. Random numbers are generated before each pair of individuals crossovers. If random number If the probability is less than the crossover probability, then crossover is performed; otherwise, crossover is not performed.
[0126] After the crossover operation, a new set of offspring individuals is generated for mutation, increasing genetic diversity and thus escaping local minima. An adaptive adjustment mechanism sets the mutation probability ζ, and individuals are selected from the offspring for mutation based on this probability ζ. The mutation is performed on genes that meet the mutation criteria. Perform Gaussian perturbation mutation:
[0127]
[0128] in, These are the gene parameter values before the mutation. It is the new value after the mutation. It is a disturbance value. It controls the amplitude of the disturbance;
[0129] In each generation of evolution (crossover and mutation operations are both referred to as "generation"), the individual with the best fitness is retained (it does not participate in crossover and mutation operations and directly enters the next generation to ensure the transmission of the optimal solution). To avoid the loss of the obtained optimal solution due to random operations, the APSO algorithm is used to globally optimize the individual (parameters) with the best fitness. The individual with the best neural fitness output by the adaptive genetic algorithm is used as the initial particle swarm position center, and the individual positions and velocities of the particle swarm are initialized (initialized to zero or random small values):
[0130]
[0131] in, z β is the initial position of particle z, and β is the perturbation range used to initialize the diversity of the particle swarm. It is the individual with the best fitness (parameter);
[0132] In each iteration, a neural network model is constructed based on the current particle position (i.e., network parameters), and its prediction error is calculated. The particle fitness value Ξ(x) is obtained by using the mean squared error as the fitness function. z The minimum MSE indicates that the particle is in a better position in the search space. The global exploration and local exploitation capabilities of the particle swarm are balanced by the dynamic inertial weight Ω.
[0133]
[0134] Among them, Ω max Ω min These are the upper and lower bounds of the inertia weight, S is the maximum number of iterations, and is the current number of iterations;
[0135] Particle velocity and position are updated using dynamic inertial weight Ω:
[0136]
[0137] in, This is the updated speed. This is the updated location. It is the first The velocity of particle z in the next iteration. It is the particle position (i.e., the parameter solution), J' z It is the optimal position in the particle's history, J z It represents the current global optimal position, φ1 and φ2 are learning factors, and ψ1 and ψ2 are random numbers;
[0138] The particle swarm optimization algorithm stops iterating when it reaches the maximum number of iterations S, and outputs the optimal position V in the particle swarm. best As the final optimal parameter solution of the neural network Input the environmental state prediction results into the model, and output the probability distribution of user behavior at time t:
[0139]
[0140] Among them, R t It is a probability distribution of user behavior. It is the optimized LSTM model, Y * It is the sequence of environmental states after attention-weighted processing, h t ′ represents the hidden state of the model's history;
[0141] Use the highest probability method to identify predicted user behavior:
[0142]
[0143] in, It predicts user behavior.
[0144] By calculating the attention score at each time step using a feedforward attention neural unit, the problem of features at different time steps being treated equally is avoided. Attention weighting enhances the ability to capture features at key time steps, improving the flexibility and accuracy of state representation. The weighted state sequence is input into a variant LSTM unit to progressively extract temporal features, effectively mitigating the vanishing or exploding gradient problem and ensuring that long-term sequence features can be stably propagated to subsequent layers, thus enhancing the ability to model temporal features. The hidden state at the last time step is selected as the user's response feature to the overall environmental state prediction, and mapped to an explicit behavior prediction value through a fully connected layer. This fully utilizes the long-term dependency features captured by the LSTM to accurately represent the user's response features to environmental changes, enhancing behavior prediction. Accuracy is improved by calculating the loss between predicted and actual behavior values and performing backpropagation optimization. This allows the model to gradually learn and adapt to user behavior patterns, improving prediction accuracy and model stability. The adaptive genetic algorithm optimizes the model parameter set, overcoming the problem of getting trapped in local optima in gradient descent optimization, significantly improving the efficiency of model parameter optimization, and enabling the model to achieve better prediction performance. The APSO algorithm further optimizes the optimal individuals output by the genetic algorithm globally, further enhancing the model's ability to search for the global optimum and ensuring that the final output model parameter combination is more robust and generalizable in the entire search space. Based on the optimized LSTM model, the probability distribution of user behavior is output, improving the prediction model's ability to represent complex user behavior patterns.
[0145] Furthermore, through deep reinforcement learning, control actions are output based on environmental state predictions and user future paths, integrating the environmental state prediction result Y′ with the user behavior prediction result. Combine to construct state vector Define the target control variables of the required control equipment and construct the continuous value action space. Used to adjust the operating status of various environmental devices, among which... It's the air conditioner's set temperature. It is in the window open / closed state. It refers to the lighting brightness level;
[0146] Design a joint reward function to guide the control strategy towards reducing energy consumption while ensuring user comfort:
[0147]
[0148] Where, r t It is the reward function, y * t It is the weighted environment state vector. It is the optimal environmental state. It is the L2 norm of the environmental state deviation. It is to control actions The energy consumption of the corresponding equipment is estimated, where γ and λ are weighting coefficients, which are set through fuzzy logic;
[0149] The weighted environment state vector y * t As input, control action As output, the SAC algorithm is used to train the control policy, and policy optimization is achieved by maximizing the expected reward function.
[0150]
[0151] in, It is the expected target value of the policy parameter π, where π is the current policy parameter. It is a discount factor. It is the policy entropy term, which encourages diversity in policy outputs and prevents getting trapped in local optima;
[0152] Continuously optimize the desired target value during training. Get the current strategy parameters (in any given state) Next, take action The probability distribution of the state vector As a strategy parameter π * The input and output are the probability distributions of control actions in this state. Using the maximum probability method Select the action with the highest probability density (Air conditioning temperature and fan speed, light brightness and window opening / closing) After the control action is generated, the instructions are converted into an MQTT protocol structure according to the control parameter format of each device, and sent to the target execution device through the device gateway. After the control is executed, the entire process log of the current control strategy is automatically recorded (control timestamp and area, current status input, control action, actual execution result feedback and difference from the target status and energy consumption record).
[0153] By combining environmental state prediction, user behavior prediction, and an adaptive control strategy based on the SAC algorithm, an efficient and intelligent building environment control method is constructed. This method can flexibly control air conditioning, windows, and lighting equipment according to environmental conditions and user needs, effectively reducing energy consumption while ensuring user comfort. The reward function design ensures a balance between comfort and energy consumption, the SAC algorithm guarantees the stability and adaptability of the control strategy, and the MQTT protocol enables the rapid issuance of control commands.
[0154] S3. Monitor and manage abnormal situations in real time, adjust management actions based on meta-learning mechanism, and upload and store the adjusted management actions.
[0155] Specifically, real-time monitoring and control measures detect anomalies and adjust control actions using a meta-learning mechanism, employing anomaly deviation metrics for dynamic detection.
[0156]
[0157] in, It is an outlier. It is a prediction of user behavior. It refers to the actual user behavior recorded by the device, v device (t) represents the action executed by the device at time t. It is a control action issued;
[0158] Thresholds were set through experiments. When outliers Greater than the threshold If the condition is deemed abnormal, the subsequent fault-tolerant process will be triggered; otherwise, it will not be triggered.
[0159] The fault tolerance process is as follows: when an abnormal deviation exceeding the limit (outlier value) is detected... Greater than the threshold When this happens, the MAML quick adjustment mechanism is used to automatically migrate the output from the current control task to the new scene control. The update method is as follows:
[0160]
[0161] Where ω' is the parameter after fast adaptation, and π * These are the original strategy network parameters. It's the learning rate. It is the meta-task loss function. It is the gradient of the loss function with respect to the parameters, which guides parameter adjustment;
[0162] Calculate the probability distribution of action selection using the updated policy network parameters ω′ and the current building environment state:
[0163]
[0164] in, In the current state of the building environment y t The action is selected based on the policy network parameter ω′. The probability of;
[0165] Based on policy output By sampling to select the optimal action, executing the selected action, and receiving a reward from the environment, the next decision is made based on the new state.
[0166] By constructing an abnormal deviation measurement system, a dynamic threshold judgment mechanism, and combining MAML rapid transfer learning, a closed-loop intelligent control method is formed, which can autonomously perceive abnormalities, quickly adapt to environmental changes, and intelligently adjust control strategies. This method achieves high-precision real-time monitoring of the operating status of the control system, can respond promptly when deviating from the target behavior or executing abnormally, and can also respond quickly when exceeding limits, avoiding false triggering and resource waste. It achieves a balance between refined management and intelligent fault tolerance, as well as rapid adaptation and knowledge transfer capabilities to new scenarios, avoiding retraining from scratch, significantly reducing response latency, and improving system robustness and user satisfaction.
[0167] Furthermore, the adjustment of the control action upload and storage will convert the control parameters (temperature and wind speed values, brightness level, on / off status) of each device (air conditioner, lighting, windows) into a unified control instruction structure format, and bind the control time and target device ID metadata. The triggering background information (environmental status, policy source, triggering reason) of each action will be encapsulated together with the action to form an "action + context data packet" as a control execution unit. Each stage of the control process (original policy, policy switching, parameter change, final output action) will be synchronously organized into a structured record unit and pushed to the event log module. After being uniformly organized by the data management module, it will be uploaded to the central database in batches.
[0168] By integrating control actions from execution to archiving, and from structured encapsulation to data storage, the system achieves complete recording of control behaviors, context preservation, and standardized data management. This provides a stable data support platform for subsequent fault tracing, anomaly analysis, control optimization, and algorithm iteration, significantly improving the system's maintainability and intelligence.
[0169] This embodiment also provides a deep learning-based intelligent building adaptive integrated management and control system, including:
[0170] The graph construction and preprocessing module is used to parse building structures and multi-source data to generate standardized graph structures and feature sequences.
[0171] The feature enhancement and compression modeling module is used to extract key trend features of dynamic environments using graph neural networks and clustering compression.
[0172] The state prediction modeling module is used to predict environmental states based on Transformer and model time dependencies and sequence relationships.
[0173] The behavior-aware prediction module is used to fuse attention and LSTM to model user paths and output behavior probability distributions.
[0174] The intelligent control and execution module is used to make decisions on equipment control using the SAC algorithm, and combines state and behavior prediction optimization strategies to generate the optimal control scheme for real-time regulation.
[0175] This embodiment also provides a computer device applicable to a deep learning-based adaptive integrated management and control method for smart buildings, comprising: a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement the deep learning-based adaptive integrated management and control method for smart buildings proposed in the above embodiment.
[0176] The computer device can be a terminal, comprising a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, NFC (Near Field Communication), or other technologies. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.
[0177] This embodiment also provides a storage medium storing a computer program, which, when executed by a processor, implements a deep learning-based intelligent building adaptive integrated management and control method as proposed in the above embodiments. The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
Claims
1. A deep learning-based adaptive integrated management and control method for smart buildings, characterized in that: include, Multi-source data is collected and preprocessed to construct a building space map structure. Building environment status is predicted based on neural clustering and Transformer model combined with frequency domain compression technology. The multi-source data includes environmental sensor data and video surveillance data; Based on the prediction results, the LSTM model is used to predict the user's future path, and deep reinforcement learning is used to output control actions based on the environmental state and the user's future path. Real-time monitoring of any abnormal situations in the implementation of control measures; adjustment of control actions based on meta-learning mechanism; and uploading and storage of the adjusted control actions. The method for predicting the state of the built environment based on neural clustering and the Transformer model combined with frequency domain compression technology includes... Using the architectural spatial graph structure G, a graph neural network is used to fuse the feature vectors of each node in the graph structure with those of its surrounding nodes to obtain an enhanced feature vector representation. To form an enhanced time series matrix The system is divided into multiple dynamically similar cluster blocks using neural clustering. k cluster centers are initialized using k-means++, and the state after structural enhancement is calculated. With cluster center membership degree Assign cluster centers with the highest membership degree to form a set of cluster sequences. The cluster sequence set is transformed into the frequency domain, compressed, and then restored to obtain the reconstructed compressed time series. ; Compress time series In the input Transformer model encoder structure, the dependencies between states at different time steps are modeled through a temporal self-attention mechanism to generate a sequence of predicted building environment states. Calculate the total loss function based on the prediction results. Optimize the Transformer model parameters to obtain the final prediction results of the built environment state. ; The prediction of the user's future path using an LSTM model based on the prediction results refers to the sequence of predicted building environment status results. The attention score is obtained by inputting the attention weighting module. ; Attention score sequences are obtained by calculating the attention score of the environment state at each time step and then converted into standardized weights. To obtain a new weighted state sequence The hidden state at each step is obtained by inputting it into a variant LSTM unit. ; The hidden state at the last time step is selected as the internal state vector formed after the user perceives the overall prediction environment. Input to the fully connected layer outputs user behavior prediction values ; The loss function between the predicted user behavior and the actual observed behavior is calculated. The gradient of the loss function with respect to the model parameters is calculated through backpropagation. The parameters are iteratively updated using the Adam optimizer for gradient descent. Treating the model parameters in a neural network as individuals, we optimize the model parameters using an adaptive genetic algorithm and retain the individuals with the best fitness. The final optimal parameter solution is obtained through global optimization using the APSO algorithm. User behavior is predicted by combining environmental state prediction results. .
2. The intelligent building adaptive integrated management and control method based on deep learning as described in claim 1, characterized in that: The method uses deep reinforcement learning to output control actions based on environmental state prediction and the user's future path, referring to the environmental state prediction results. User behavior prediction results Combine to construct state vector Define the target control variables of the required control equipment and construct the continuous value action space. Calculate the joint reward function The weighted environment state vector As input, control action As output, the SAC algorithm is used to train the control policy, and the policy parameters are obtained by maximizing the expected reward function. Expected target value ; Continuously optimize the desired target value during training. Get the current strategy parameters , the state vector As a policy function The input and output are the probability distributions of control actions in this state. Select the action with the highest probability density using the highest probability method. After the control action is generated, the instructions are converted into an MQTT protocol structure according to the control parameter format of each device and sent to the target execution device through the device gateway. After the control is executed, the entire process log of the current round of control strategy is automatically recorded.
3. The intelligent building adaptive integrated management and control method based on deep learning as described in claim 2, characterized in that: The aforementioned real-time monitoring and control measures, which adjust control actions in conjunction with a meta-learning mechanism, utilize anomaly deviation metrics to dynamically detect outliers. When an abnormal deviation exceeding the limit is detected, the MAML fast adjustment mechanism is used to automatically migrate the output from the current control task to the new scenario control and update the obtained parameters. ; Through the updated policy network parameters Input the current building environment status to calculate the probability distribution of the selected action. By sampling, the optimal action is selected, the selected action is executed, and the reward in the environment is fed back. The next decision is made based on the new state.
4. The intelligent building adaptive integrated management and control method based on deep learning as described in claim 3, characterized in that... The process of adjusting and uploading control actions to storage refers to converting the control parameters of each device into a unified control instruction structure format and binding metadata. The triggering background information of each action is encapsulated together with the action to form an "action + context data packet" as a control execution unit. Each stage of the control process is synchronously organized into a structured record unit and pushed to the event log module. After being uniformly organized by the data management module, it is uploaded to the central database in batches.
5. The intelligent building adaptive integrated management and control method based on deep learning as described in claim 4, characterized in that: The process of collecting and preprocessing multi-source data to construct a building space structure diagram refers to extracting room units and connection relationships from the building's BIM model, and constructing a set of nodes and edges. Obtain the adjacency matrix ; Multi-source data is collected through temperature and humidity sensors, noise sensors, and high-definition cameras. Data is uploaded and controlled via the MQTT protocol, encoded in a unified format through a central data platform, and node state vectors are extracted. A sliding window mechanism is used for time synchronization and alignment to form feature vectors. Missing data were repaired using nearest-neighbor imputation and Z-score normalization was performed to construct a normalized feature matrix. ; Construct a time series matrix based on the standardized feature vectors. Combined with adjacency matrix Establish the spatial graph structure G.
6. A deep learning-based adaptive integrated management and control system for smart buildings, based on the deep learning-based adaptive integrated management and control method for smart buildings as described in any one of claims 1 to 5, characterized in that: include, The graph construction and preprocessing module is used to parse building structures and multi-source data to generate standardized graph structures and feature sequences. The feature enhancement and compression modeling module is used to extract key trend features of dynamic environments using graph neural networks and clustering compression. The environmental state prediction and modeling module is used to predict environmental states based on Transformer and model time dependencies and sequence relationships. The behavior-aware prediction module is used to fuse attention and LSTM to model user paths and output behavior probability distributions. The intelligent control and execution module is used to make decisions on equipment control using the SAC algorithm, and combines state and behavior prediction optimization strategies to generate the optimal control scheme for real-time regulation.
7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the deep learning-based intelligent building adaptive integrated management and control method as described in any one of claims 1 to 5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, it implements the steps of the deep learning-based intelligent building adaptive integrated management and control method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Settlement prediction method, system and equipment
CN116757303A
Energy consumption monitoring and optimizing method and system based on large model and multiple agents
CN118916778A