Building internet of things monitoring method and system based on digital twinning

By constructing a physical twin mapping relationship and improving the MemAE model, the problem of synchronization lag between the status of physical devices and the status of digital twin nodes in the building Internet of Things (IoT) was solved, achieving highly accurate anomaly identification and tracing, and improving the intelligence and precision of monitoring.

CN123145284APending Publication Date: 2026-11-20ZHEJIANG AOLE INTELLIGENT SYST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611501005.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-24
Publication Date
2026-11-20

AI Technical Summary

Technical Problem

Existing digital twin monitoring methods in the building Internet of Things (IoT) suffer from problems such as different data update frequencies between the physical device status and the digital twin node status, network transmission delays, and status synchronization lags, resulting in status misalignment and making it difficult to accurately identify anomalies and trace their starting location and associated range.

Method used

By constructing physical twin mapping relationships, synchronizing state version chains, and improving the MemAE model, mismatch detection and continuous anomaly tracing of the building IoT operation status are achieved. By utilizing delayed arrival state verification and combining adjacent states and cross-time period changes for analysis, the accuracy of anomaly identification and tracing capabilities are enhanced.

Benefits of technology

It improves the accuracy and stability of building IoT monitoring, effectively distinguishes between real anomalies and false anomalies caused by data delays, reduces the probability of false alarms, and provides reliable basis for anomaly tracing and fault location.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123145284A_ABST
    Figure CN123145284A_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on digital twinning building internet of things monitoring method and system, it is related to digital twinning technical field, including the following steps: gather building internet of things, digital twinning data, generate building monitoring source data;Establish two-way index, generate physical twin mapping;Build double state version chain and cross alignment, mark delay arrival state, generate synchronization state pair set;Extract adjacent state and cross period change, generate physical twin state sample set;State mismatch data is generated using improved MemAE model;Merge common mismatch nodes, generate mismatch association cluster;Using delay arrival state update history version and review, generate effective abnormal node set;Trace back the starting point of sustained mismatch, generate building internet of things monitoring result.The application realizes building internet of things virtual and real state mismatch detection and abnormal trace back by improving MemAE model combined with physical twin state analysis, reduces the misjudgment caused by delay data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of digital twin technology, and in particular to a building IoT monitoring method and system based on digital twins. Background Technology

[0002] With the continuous development of smart buildings, the Internet of Things (IoT) in buildings, and digital twin technologies, the operational status, environmental status, and control status of building equipment are increasingly being collected in real time through sensors, edge terminals, and network platforms, and synchronously mapped to the digital twin space for building operation status monitoring, equipment management, and anomaly analysis. Existing technologies typically upload data collected by the IoT to a monitoring platform, establishing a link between physical devices and digital models through device identifiers, timestamps, or spatial locations. This is then combined with threshold judgments, statistical analysis, or machine learning models to identify operational anomalies. While this method can achieve digital monitoring of building equipment to a certain extent, there are often discrepancies in data update frequencies, network transmission delays, and status synchronization lags between the physical device status and the digital twin node status, which can easily lead to temporal misalignments between the physical and digital twin states.

[0003] Existing digital twin monitoring methods mostly rely on direct matching between the current physical state and the twin state, or on separate anomaly detection of IoT time-series data and digital model states. These methods fail to adequately utilize the continuous changing relationship between the physical state and the twin state, as well as the associated states of adjacent nodes. When data from some devices is delayed due to network congestion, edge caching, or communication interruptions, the existing twin state may be updated based on incomplete physical information. Existing methods often struggle to distinguish between state mismatches caused by real device anomalies and temporary mismatches caused by data delays or version misalignments. Furthermore, anomaly detection models often establish normal patterns based on unilateral state characteristics, lacking joint memory and reliable update control of the pairing relationship between physical and twin states. Abnormal states may also be continuously written into the normal state representation, thus reducing the accuracy of subsequent monitoring results.

[0004] Furthermore, existing methods often directly generate alarm results after detecting inconsistencies between the physical state and the twin state, lacking a process to re-verify and trace the anomaly by combining historical versions of the state and the connection relationships of building equipment, making it difficult to determine the starting point and associated scope of the continuous mismatch.

[0005] Therefore, how to provide a building IoT monitoring method and system based on digital twins is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention

[0006] One objective of this invention is to propose a building IoT monitoring method and system based on digital twins. This invention fully utilizes digital twin, building IoT, and improved MemAE model technology. By constructing physical twin mapping relationships, synchronizing state version chains, and combining delayed arrival state verification, it achieves mismatch detection and continuous anomaly tracing of the building IoT's operating status. It has the advantages of strong correlation between virtual and real states, high accuracy of anomaly identification, low interference from delayed data, and strong anomaly tracing capabilities.

[0007] A building IoT monitoring method based on digital twin according to an embodiment of the present invention includes: Collect building IoT data and digital twin data, and merge them according to device identifier, twin identifier, connection relationship and timestamp to generate building monitoring source data; A physical twin bidirectional index is established based on building monitoring source data to generate a physical twin mapping map; Based on the physical twin mapping graph, construct the physical state version chain and the twin state version chain, establish cross-version relationships according to time and mark the delayed arrival state to generate a set of synchronized state pairs; Extract the adjacent states and cross-time changes of the synchronized state pair set along the physical twin mapping graph to generate a physical twin state sample set; The physical twin state sample set is input into the improved MemAE model to generate state mismatch data. The improved MemAE model includes a shared state encoding layer, a physical twin pairing memory layer, a synchronous trusted writing layer, a state reconstruction decoding layer, and a state mismatch output layer. The mismatch data is pasted back to the physical twin mapping graph. Common mismatch nodes are selected along the physical state version chain and the twin state version chain and merged according to the connection relationship to generate mismatch association clusters. Replace the historical version state of the mapped node in the mismatched cluster with the delayed arrival state, verify the state mismatch, and generate a valid set of abnormal nodes; Tracing the point of continuous mismatch of the effective set of abnormal nodes along the physical twin map generates building IoT monitoring results.

[0008] Optionally, the generated building monitoring source data includes: The system collects building IoT data, aggregates equipment operation records by device identifier, extracts connection object identifiers and collection time, and generates physical monitoring records. The building IoT data includes device identifiers, device operating parameters, device operating status, connection object identifiers, and collection time. Collect digital twin data, aggregate twin node records according to twin identifiers, extract associated device identifiers, connected object identifiers, and update times, and generate twin-side monitoring records; the digital twin data includes twin identifiers, associated device identifiers, twin node status, connected object identifiers, and update times; By associating physical monitoring records and twin monitoring records with the device identifier and associated device identifier, the connection object identifiers are merged into connection relationships, and the acquisition time and update time are retained to generate building monitoring source data.

[0009] Optionally, generating the physical twin mapping includes: Establish physical nodes and their relationships based on the device identifiers and connection relationships in the building monitoring source data; Twin nodes are established based on twin identifiers and associated device identifiers, and physical nodes are paired with twin nodes to generate physical twin node pairs; Based on the physical twin node pairs, establish bidirectional indexes from physical nodes to twin nodes and from twin nodes to physical nodes, and map the physical node relationships to the paired twin nodes to generate a physical twin mapping graph.

[0010] Optionally, generating the set of synchronization state pairs includes: Based on the physical twin node and the associated physical monitoring records and twin monitoring records, the device operating status is arranged by collection time, and the twin node status is arranged by update time, generating a physical status version chain and a twin status version chain. Associate the physical state version chain and the twin state version chain, establish a cross-version relationship between the operating states of devices with adjacent times and the twin node states, and mark the operating states of devices that belong to existing historical versions after the cross-version is formed as delayed arrival states. The device operating status and twin node status of the same physical twin node pair are filtered along the cross-version relationship, and the pairs are encapsulated in version order to generate a set of synchronized status pairs.

[0011] Optionally, the generation of the physical twin state sample set includes: Based on the connection relationship in the physical twin mapping graph, the states of adjacent physical nodes and adjacent twin nodes are extracted from the synchronization state pairs in the synchronization state pair set to generate an adjacency state group. Extract the state changes of the same physical twin node to adjacent versions along the physical state version chain and the twin state version chain, organize them according to the direction and magnitude of the change, and generate cross-time period change records; Synchronous state pairs are combined with their corresponding adjacent state groups and cross-time change records, and arranged according to the physical twin node pairs and version order to generate a physical twin state sample set.

[0012] Optionally, the generated state mismatch data includes: The encoder based on the MemAE model forms a shared state encoding layer, replaces the memory module with a physical twin paired memory layer, adds a synchronous trusted write layer, and establishes a forward connection from the physical twin paired memory layer to the synchronous trusted write layer and a feedback connection from the synchronous trusted write layer to the physical twin paired memory layer; a state reconstruction decoding layer is formed based on the decoder, and a state mismatch output layer is added after the state reconstruction decoding layer to form an improved MemAE model. The physical twin state sample set is input into the shared state coding layer to encode synchronous state pairs, adjacent state groups and cross-time period change records, generating physical state coding data and twin state coding data. The physical state encoded data and twin state encoded data are input into the physical twin pairing memory layer, and the physical state prototype and twin state prototype in the pairing memory slot are jointly matched to generate pairing memory read data and slot matching data. The slot matching data and physical twin state sample set are input into the synchronous trusted writing layer. Trusted writing tags are generated based on time correspondence, slot matching consistency and state change continuity, and fed back to the physical twin pairing memory layer to update the pairing memory slots. The paired memory read data is input into the state reconstruction decoding layer to generate physical state reconstruction data and twin state reconstruction data; The physical state reconstruction data and twin state reconstruction data are input into the state mismatch output layer and compared with the device operating state and twin node state in the synchronized state pair to generate state mismatch data. Acquire historical building IoT data and historical digital twin data, generate a historical normal physical twin state sample set and input it into the improved MemAE model, determine the training objective based on state reconstruction deviation and pairing slot matching deviation, iteratively update the model parameters and the physical state prototype and twin state prototype in the pairing memory slot, and obtain the trained improved MemAE model.

[0013] Optionally, the generation of mismatch association clusters includes: According to the physical twin node pairs and version order, the state mismatch data is pasted back to the physical nodes and twin nodes in the physical twin mapping diagram to generate node mismatch markers; Track node mismatch markers along the physical state version chain and the twin state version chain, filter out nodes in which physical nodes and their corresponding twin nodes simultaneously exhibit state mismatch in consecutive versions, and generate a set of nodes with common mismatches. By associating common mismatch nodes according to the connection relationship in the physical twin mapping graph, common mismatch nodes that have connection relationships and overlap mismatch versions are merged to generate mismatch association clusters.

[0014] Optionally, generating a valid set of abnormal nodes includes: Filter the delayed arrival states to match the mapped nodes within the mismatched cluster, and locate the historical version states according to the physical twin node pairs and version order; By replacing the historical version state with the delayed arrival state, updating the synchronized state pair set and the physical twin state sample set, and inputting the updated physical twin state sample set into the improved MemAE model, the system re-detects under the condition that the pairing memory slots remain unchanged, and generates verification state mismatch data. Compare the verification state mismatch data with the state mismatch data, remove the mapping nodes whose mismatch is eliminated after state replacement, retain the mapping nodes with continuous mismatch, and generate a set of valid abnormal nodes.

[0015] Optionally, the generation of building IoT monitoring results includes: Track the mismatch status of the valid abnormal node set in the verification status mismatch data along the physical state version chain and the twin state version chain, determine the starting version of the continuous mismatch, and generate a continuous mismatch record; The persistent mismatch records are pasted back to the physical twin mapping graph, the abnormal nodes are traced along the connection relationship, the earliest node with persistent mismatch is selected, and the persistent mismatch starting point is generated. The system aggregates a set of valid abnormal nodes, records of continuous mismatches, and the starting point of continuous mismatches to generate building IoT monitoring results.

[0016] A building IoT monitoring system based on digital twins according to an embodiment of the present invention includes the following modules: The monitoring source data construction module is used to collect building IoT data and digital twin data to generate building monitoring source data; The physical twin mapping module is used to establish a bidirectional index between physical nodes and twin nodes, and generate a physical twin mapping graph; The state version synchronization module is used to construct physical state version chains and twin state version chains, mark delayed arrival states, and generate a set of synchronized state pairs. The state sample construction module is used to extract adjacent states and cross-time changes based on the set of synchronous state pairs to generate a physical twin state sample set; The state mismatch detection module is used to process the physical twin state sample set by improving the MemAE model and generate state mismatch data. The mismatch association merging module is used to filter and merge common mismatch nodes based on state mismatch data to generate mismatch association clusters. The delayed state verification module is used to update and verify the historical version state in the mismatch association cluster using the delayed arrival state, and generate a set of valid abnormal nodes. The continuous mismatch tracing module is used to trace the starting point of continuous mismatch in the set of valid abnormal nodes and generate building IoT monitoring results.

[0017] The beneficial effects of this invention are: This invention unifies and merges building IoT data and digital twin data, establishing a bidirectional index and physical twin mapping graph between physical nodes and twin nodes. Furthermore, it constructs physical state version chains and twin state version chains, enabling correlation analysis between the actual operating status of building equipment and the status of digital twin nodes under a unified mapping and version relationship. Compared to monitoring methods that rely solely on one-sided IoT data or the current state, this invention more accurately maintains the correspondence between the physical and twin states, improving the completeness of state correlation and synchronous analysis during building digital twin monitoring.

[0018] This invention improves the MemAE model for joint modeling of physical twin state samples. It introduces a physical twin pairing memory and synchronous trusted writing mechanism into the memory system, performing paired memory, joint matching, and trusted updates between the physical state and the twin state. This enables the model to identify situations where one-sided states remain within the normal range, but abnormal mismatches have occurred between the physical state and the twin state, and reduces interference from abnormal or asynchronous states on normal memory. Combining the analysis of adjacent states and cross-time period changes enhances the characterization of continuous state changes and anomalies in associated nodes, thereby improving the accuracy and stability of anomaly monitoring in the building IoT.

[0019] This invention further utilizes delayed arrival states to replace historical version states and re-execute state mismatch detection. It verifies temporary virtual-physical mismatches caused by network transmission delays, edge caching, or communication interruptions, effectively distinguishing between genuine anomalies and false anomalies caused by data delays, thus reducing the probability of false alarms. Based on this, by screening common mismatch nodes along the physical state version chain, twin state version chain, and physical twin mapping graph, and tracing the starting point of continuous mismatch, the monitoring results not only identify valid anomaly nodes but also reflect the continuous process and starting location of the anomaly. This provides a more reliable basis for building equipment operation and maintenance, fault location, and anomaly handling, improving the intelligence and precision of building IoT monitoring. Attached Figure Description

[0020] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a flowchart of a building IoT monitoring method based on digital twins proposed in this invention; Figure 2 This is a schematic diagram of the structure of an improved MemAE model for a building IoT monitoring method based on digital twins proposed in this invention. Figure 3 This is a schematic diagram of the structure of a building Internet of Things monitoring system based on digital twin proposed in this invention. Detailed Implementation

[0021] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0022] refer to Figure 1 and Figure 2 A building IoT monitoring method based on digital twins includes: Collect building IoT data and digital twin data, and merge them according to device identifier, twin identifier, connection relationship and timestamp to generate building monitoring source data; A physical twin bidirectional index is established based on building monitoring source data to generate a physical twin mapping map; Based on the physical twin mapping graph, construct the physical state version chain and the twin state version chain, establish cross-version relationships according to time and mark the delayed arrival state to generate a set of synchronized state pairs; Extract the adjacent states and cross-time changes of the synchronized state pair set along the physical twin mapping graph to generate a physical twin state sample set; The physical twin state sample set is input into the improved MemAE model to generate state mismatch data. The improved MemAE model includes a shared state encoding layer, a physical twin pairing memory layer, a synchronous trusted writing layer, a state reconstruction decoding layer, and a state mismatch output layer. The mismatch data is pasted back to the physical twin mapping graph. Common mismatch nodes are selected along the physical state version chain and the twin state version chain and merged according to the connection relationship to generate mismatch association clusters. Replace the historical version state of the mapped node in the mismatched cluster with the delayed arrival state, verify the state mismatch, and generate a valid set of abnormal nodes; Tracing the point of continuous mismatch of the effective set of abnormal nodes along the physical twin map generates building IoT monitoring results.

[0023] In this embodiment, the generation of building monitoring source data includes: The system collects building IoT data, aggregates equipment operation records by device identifier, extracts connection object identifiers and collection time, and generates physical monitoring records. The building IoT data includes device identifiers, device operating parameters, device operating status, connection object identifiers, and collection time. Collect digital twin data, aggregate twin node records according to twin identifiers, extract associated device identifiers, connected object identifiers, and update times, and generate twin-side monitoring records; the digital twin data includes twin identifiers, associated device identifiers, twin node status, connected object identifiers, and update times; Based on the device identifier and associated device identifier, the physical monitoring records and twin monitoring records are linked. The connection object identifiers are merged into connection relationships, and the acquisition time and update time are retained to generate building monitoring source data. Specifically, the generation of building monitoring source data includes: Physical monitoring records and twin monitoring records with the same device identifier and associated device identifier are grouped into the same record group; the connection object identifier in the record group is read, and the connection object identifier is compared with the existing device identifier and twin identifier in the building monitoring record item by item. When the values ​​are consistent, the connection relationship from the node to the record to the matching node is established; the connection relationships with consistent starting nodes and target nodes are merged, and the device identifier, twin identifier, device operating parameters, device operating status, twin node status, connection relationship, acquisition time and update time are encapsulated into monitoring records and aggregated to generate building monitoring source data.

[0024] In this embodiment, generating the physical twin mapping graph includes: Establish physical nodes and their relationships based on the device identifiers and connection relationships in the building monitoring source data; Twin nodes are established based on twin identifiers and associated device identifiers. Physical nodes are paired with twin nodes to generate physical twin node pairs. The specific steps for generating physical twin node pairs are as follows: Twin nodes are established by reading twin identifiers from twin monitoring records. The associated device identifier is compared with the device identifier corresponding to the physical node item by item. When the values ​​are consistent, a pairing relationship is established between the physical node and the twin node. The device identifier and the twin identifier are combined and recorded as a physical twin node pair. All pairing records are collected to generate a set of physical twin node pairs. Based on the physical twin node pairs, bidirectional indexes are established from physical nodes to twin nodes and from twin nodes to physical nodes. The relationships between physical nodes are then mapped to the pairs of twin nodes, generating a physical twin mapping graph. Specifically, the generation of the physical twin mapping graph involves: Read each physical twin node pair one by one, and create an index entry from physical node to twin node using the device identifier as the index key and the twin identifier as the index value. Create an index entry from twin node to physical node using the twin identifier as the index key and the device identifier as the index value. Read the device identifiers at both ends of the physical node relationship, find the paired twin identifier through the index entry from physical node to twin node, and write the same connection relationship between the paired twin nodes. Combine the physical nodes, twin nodes, bidirectional indexes, physical node relationships, and twin node relationships to generate a physical twin mapping graph.

[0025] In this embodiment, generating a set of synchronization state pairs includes: Based on the physical twin node's association with the physical monitoring records and the twin monitoring records, the device operating status is arranged by acquisition time, and the twin node status is arranged by update time, generating a physical status version chain and a twin status version chain. The specific steps for generating the physical status version chain and the twin status version chain are as follows: The device operating status and twin node status are collected separately according to the same physical twin node pair. The device operating status is arranged from earliest to latest according to the collection time, and the twin node status is arranged from earliest to latest according to the update time. Each device operating status record is determined as a physical status version, and each twin node status record is determined as a twin status version. Version associations from the previous status version to the next status version are established according to the adjacent time sequence, generating a physical status version chain and a twin status version chain. By associating the physical state version chain and the twin state version chain, a cross-version relationship is established between the time-adjacent device operating states and the twin node states. Device operating states whose data collection time belongs to an existing historical version are marked as delayed arrival states after the cross-version is formed. Specifically, associating the physical state version chain and the twin state version chain involves: The acquisition time of each physical status version is read one by one and compared with the update time of each twin status version under the same physical twin node. The twin status version with the smallest time interval is selected to establish a cross version relationship with the physical status version according to the time interval between the two time points from small to large. If the time intervals are the same, the twin status version with the earlier update time is selected. When merging the device operation status, the acquisition time is compared with the acquisition time of the existing versions in the physical status version chain one by one. If the acquisition time is between two adjacent existing versions and the two adjacent existing versions have established a cross version relationship, the device operation status is marked as delayed arrival status. The device operating status and twin node status of the same physical twin node pair are filtered along the cross-version relationship, and then encapsulated in pairs according to version order to generate a set of synchronized state pairs. Specifically, the generation of the synchronized state pair set is as follows: Read the physical state version and twin state version in the cross-version relationship one by one, extract the device operation status corresponding to the physical state version, the twin node status corresponding to the twin state version, and the physical twin node pair identifier. Combine the device operation status and twin node status that have the same physical twin node pair and have established a cross-version relationship into a synchronization state pair, and write them into the physical state version order and twin state version order. Arrange the synchronization state pairs according to the physical state version order and collect them to generate a synchronization state pair set.

[0026] In this embodiment, generating the physical twin state sample set includes: Based on the connection relationships in the physical twin mapping graph, the states of adjacent physical nodes and adjacent twin nodes are extracted from the synchronization state pairs in the synchronization state pair set to generate adjacency state groups. Specifically, generating adjacency state groups involves: Read the physical twin node pairs to which the synchronization state pairs belong, identify the physical nodes that have established direct connections with the physical nodes as adjacent physical nodes, find the twin nodes that are paired with the adjacent physical nodes through bidirectional indexing, and determine the adjacent twin nodes; according to the physical state version and twin state version position of the synchronization state pairs, extract the states with the same version position from the state version chains of adjacent physical nodes and adjacent twin nodes, extract the states that establish the cross version relationship when there is a cross version relationship, and generate the adjacency state group according to the node connection relationship; Extract the state changes of the same physical twin node to adjacent versions along the physical state version chain and the twin state version chain, organize them according to the direction and magnitude of change, and generate cross-time period change records. Specifically, the generation of cross-time period change records is as follows: For the same physical twin node pair, sequentially read adjacent physical state versions and adjacent twin state versions. For numerical equipment operating parameters and twin node state parameters, compare the value of the later version with the value of the previous version. If the value of the later version is larger, record it as an increase; if it is smaller, record it as a decrease; if they are equal, record it as a remainder. The absolute value of the difference between the two version values ​​determines the magnitude of the change. For discrete equipment operating states and discrete twin node states, record the transition results from the previous version state to the next version state. Collect the change direction, change magnitude, and state transition results according to the version order to generate a cross-time period change record. Synchronization state pairs are combined with their corresponding adjacent state groups and cross-time change records, and arranged according to the physical twin node pairs and version order to generate a physical twin state sample set. Specifically, the generation of the physical twin state sample set is as follows: Synchronization state pairs, adjacent state groups, and cross-time period change records are matched according to the physical twin node pair identifier and version order. Synchronization state pairs, adjacent state groups, and cross-time period change records with consistent physical twin node pair identifiers and version positions are encapsulated into a physical twin state sample. All physical twin state samples are arranged according to the physical twin node pair and version order, and then aggregated to generate a physical twin state sample set.

[0027] In this embodiment, the generation of state mismatch data includes: The encoder based on the MemAE model forms a shared state encoding layer, replacing the memory module with a physically twin-paired memory layer, adding a synchronous trusted write layer, and establishing a forward connection from the physically twin-paired memory layer to the synchronous trusted write layer and a feedback connection from the synchronous trusted write layer to the physically twin-paired memory layer. A state reconstruction decoding layer is formed based on the decoder, and a state mismatch output layer is added after the state reconstruction decoding layer, forming an improved MemAE model. Specifically, the improved MemAE model is as follows: The MemAE model's encoder is retained, and the physical state input and twin state input are connected to the same encoding path and share encoding parameters to form a shared state encoding layer. The memory module is removed, and a physical twin paired memory layer consisting of multiple paired memory slots is set. Each paired memory slot uses a unified slot number to set the physical state storage location and the twin state storage location respectively. Physical state storage locations with the same slot number and twin state storage locations form a pairing relationship. A new synchronous trusted write layer is added, connecting the slot matching output of the physical twin paired memory layer to the input of the synchronous trusted write layer, and feeding back the output of the synchronous trusted write layer to the memory update end of the physical twin paired memory layer. The MemAE model's decoder is retained, and the paired memory reading results are connected to the decoder to form a state reconstruction decoding layer. A state mismatch output layer is added to the output of the state reconstruction decoding layer, forming a forward processing path consisting of the shared state encoding layer, the physical twin paired memory layer, the state reconstruction decoding layer, and the state mismatch output layer, as well as a memory update feedback path consisting of the synchronous trusted write layer, resulting in the improved MemAE model. This invention structurally optimizes the traditional MemAE model by modifying the memory structure and adding a trusted write and mismatch output structure, thereby improving the ability to jointly analyze physical states and twin states. To address the problem that traditional MemAE models cannot simultaneously represent the correspondence between physical states and twin states, a shared state encoding layer is set up to uniformly encode synchronous states, adjacent states, and cross-time changes, thereby improving the consistency of virtual and real state feature representation. To enhance the memory capacity of the physical state and twin state in combination with normal patterns, the memory module is replaced with a physical twin paired memory layer. The physical state prototype and the twin state prototype are associated through paired memory slots, thereby improving the ability to identify anomalies in state correspondence. To address the issue that delayed arrival and abnormal states may affect memory updates, a new synchronous trusted write layer is added. This layer controls the updates of paired memory slots based on time correspondence, slot matching consistency, and the continuity of state changes, thereby improving the stability of the memory content. In terms of state reconstruction, a new state mismatch output layer is added to jointly compare the reconstruction results of physical state and twin state, thereby improving the accuracy of state mismatch detection. The improved MemAE model enhances the stability and reliability of virtual-real state mismatch detection in the building IoT through collaborative processing of shared encoding, paired memory, trusted writing, and mismatch output. The physical twin state sample set is input into the shared state coding layer to encode synchronous state pairs, adjacent state groups, and cross-time period change records, generating physical state coded data and twin state coded data. The shared state coding layer includes: State splitting unit: Based on physical twin node pairs and state source, synchronized state pairs, adjacent state groups, and cross-time change records are divided into physical side state fields and twin side state fields, while preserving version order and node connection position; Shared feature mapping unit: The same set of weights and biases are used to perform linear mapping and nonlinear activation on the physical side state field and the twin side state field respectively, transforming different state fields into state feature vectors with consistent dimensions. The weights and biases are obtained iteratively by the training process of the improved MemAE model. Adjacency State Aggregation Unit: Aggregates the state features of adjacent nodes on the physical side and the twin side according to the node connection position. The adjacent state features of the same node are averaged according to the feature dimension to generate physical adjacency features and twin adjacency features. Cross-time period change fusion unit: Map the change direction, change magnitude and state transition results to cross-time period change features according to the version order, and then concatenate them with the physical side state features, twin side state features and corresponding adjacent features respectively; Encoding output unit: Performs linear mapping on the concatenated physical side features and twin side features using shared weights to generate physical state encoded data and twin state encoded data with consistent dimensions; In the shared state coding layer, the state splitting unit determines the physical-side state field and the twin-side state field according to the device operating state and twin node state in the synchronous state pair, and extracts state information from the same source from the adjacent state group and cross-time change records; the shared feature mapping unit processes the physical-side state field and the twin-side state field with the same weight and bias, and forms the basic state features through linear mapping and ReLU activation; the adjacent state aggregation unit averages the basic state features of adjacent nodes according to the connection position in the physical twin mapping diagram, and combines them with the basic state features of the node to which it belongs; the cross-time change fusion unit converts the increase, decrease and maintain into discrete direction encoding, retains the change amplitude as a continuous feature, encodes the discrete state transformation result into a state transformation feature, and combines it with the basic state features according to the version position; the encoding output unit maps the combined physical-side features and twin-side features to the same feature dimension using shared parameters, and outputs physical state encoded data and twin state encoded data respectively. The physical state encoded data and twin state encoded data are input into the physical twin pairing memory layer. The physical state prototypes and twin state prototypes in the matching pairing memory slots are then jointly matched to generate pairing memory read data and slot matching data. The physical twin pairing memory layer includes: Paired memory slot unit: Multiple paired memory slots with the same slot number are set up. Each paired memory slot stores the physical state prototype and the twin state prototype respectively. Physical state prototypes with the same slot number and twin state prototypes form a pairing relationship. Joint matching unit: Calculate the matching degree between physical state encoded data and each physical state prototype, and the matching degree between twin state encoded data and each twin state prototype, and merge the matching results on both sides in the same proportion to obtain the joint matching degree of each paired memory slot; Read weight generation unit: Performs an exponential transformation on the joint matching degree of each paired memory slot, divides the transformation result of a single paired memory slot by the sum of the transformation results of all paired memory slots, and generates normalized read weights; Paired reading unit: The physical state prototype and twin state prototype in each paired memory slot are weighted and accumulated according to the normalized reading weight to generate physical memory reading features and twin memory reading features, which are then combined to form paired memory reading data. At the same time, the slot number, the matching degree on both sides, the joint matching degree and the normalized reading weight are collected to generate slot matching data. In the physical twin paired memory layer, the paired memory slot unit uses the physical state prototypes and twin state prototypes formed during the training of the improved MemAE model to establish one-to-one paired normal state memories; the joint matching unit performs vector normalization on the physical state encoded data, twin state encoded data, and the two types of state prototypes in the same slot, respectively, multiplies the components of the same dimension item by item and sums them to determine the matching degree on both sides, and sums the physical side matching degree and the twin side matching degree with a weight of 0.5 to obtain the joint matching degree; the read weight generation unit converts the joint matching degree into normalized read weights; the paired read unit uses the same set of normalized read weights to read the physical state prototypes and twin state prototypes, keeping the read results on both sides from the same paired memory slot, and outputs the paired memory read data and slot matching data; The slot matching data and physical twin state sample set are input into the synchronous trusted write layer. Trusted write tags are generated based on time correspondence, slot matching consistency, and state change continuity, and then fed back to the physical twin paired memory layer to update the paired memory slots. The synchronous trusted write layer includes: Time correspondence determination unit: Read the synchronization state pairs in the physical twin state sample set, calculate the time interval between the device operation status acquisition time and the twin node status update time, and take the 95th percentile of the time interval of the same physical twin node pair in the historical normal physical twin state sample set as the upper limit of time correspondence. When the time interval does not exceed the upper limit of time correspondence, a time correspondence pass mark is generated. Slot consistency determination unit: Reads slot matching data, selects the paired memory slots with the highest physical matching degree and the highest twin matching degree respectively, and generates a slot consistency pass mark when the slot numbers of the two paired memory slots are consistent; State continuity determination unit: Reads cross-period change records, compares the change amplitude of numerical state with the 95th percentile of the change amplitude of adjacent versions of the same state in the historical normal physical twin state sample set, and checks whether discrete state transitions exist in the historical normal physical twin state sample set, and generates a state continuity pass mark. Trusted write control unit: The collection time corresponds to the pass mark, the slot consistent pass mark, and the status continuous pass mark. When all three marks pass, a write-allowed mark is generated. When any mark fails, a write-prohibited mark is generated. The write-allowed mark or write-prohibited mark is fed back to the physical twin paired memory layer as a trusted write mark. In the synchronous trusted write layer, the time correspondence determination unit determines the time interval based on the acquisition time and update time of the synchronous state pair, and compares it with the upper limit of time correspondence to exclude time misalignment states; the slot consistency determination unit compares the matching results of each paired memory slot on the physical side and the twin side respectively, and determines the pairing matching consistency by whether the highest matching slot number is consistent; the state continuity determination unit uses the 95th percentile determined by the historical normal physical twin state sample set as the upper limit of the change range for numerical states, and checks whether the state transition combination exists in the historical normal physical twin state sample set for discrete states; the trusted write control unit generates a write permission flag only when time correspondence, slot matching consistency, and state change continuity are all satisfied, and feeds it back to the physical twin paired memory layer, which updates the physical state prototype and twin state prototype in the paired memory slot with the physical state encoding data and twin state encoding data of the current matching slot, and the paired memory slot corresponding to the write permission flag remains unchanged; The paired memory read data is input into the state reconstruction decoding layer to generate physical state reconstruction data and twin state reconstruction data. The state reconstruction decoding layer includes: Paired Reading Segmentation Unit: Read paired memory reading data and extract physical memory reading features and twin memory reading features respectively; Shared decoding unit: The decoder using the MemAE model processes physical memory retrieval features and twin memory retrieval features respectively. It recovers the feature dimensions before encoding layer by layer through linear mapping and nonlinear activation. The decoding weights and biases are obtained iteratively by the training process of the improved MemAE model. Dual-sided reconstruction output unit: According to the arrangement order of physical side state fields and twin side state fields, the decoded features are mapped to the device operation state dimension and twin node state dimension to generate physical state reconstruction data and twin state reconstruction data respectively; In the state reconstruction decoding layer, the paired read splitting unit extracts the physical memory read features and twin memory read features from the paired memory read data respectively; the shared decoding unit performs linear mapping and ReLU activation on the two types of memory read features at the same decoding level, and restores the memory read features to the state feature dimension step by step; the dual-sided reconstruction output unit restores the physical side decoding features to the device operating state and the twin side decoding features to the twin node state according to the order of the state fields retained when the shared state encoding layer is input, forming physical state reconstruction data and twin state reconstruction data respectively; The physical state reconstruction data and twin state reconstruction data are input into the state mismatch output layer, and compared with the device operating state and twin node state in the synchronized state pair to generate state mismatch data. The state mismatch output layer includes: Physical state deviation calculation unit: Compares the physical state reconstruction data with the device operating status in the synchronization state pair according to the order of the device operating status fields to generate physical state deviation data; Twin state deviation calculation unit: Compares the twin state reconstruction data with the twin node states in the synchronization state pair according to the order of the twin node state fields to generate twin state deviation data; Mismatch data encapsulation unit: Combines physical state deviation data and twin state deviation data according to physical twin node pairs and version positions to generate state mismatch data; In the state mismatch output layer, the physical state deviation calculation unit calculates the absolute value of the difference between the reconstructed value and the actual value of the numerical device operating state, and records the state field and deviation value; for the discrete device operating state, it reads the values ​​of each category output by the state reconstruction decoding layer, selects the category with the largest value as the reconstructed state, and records it as consistent when the reconstructed state is consistent and as mismatched when it is inconsistent; the twin state deviation calculation unit processes the twin state reconstruction data and twin node state in the same way; the mismatch data encapsulation unit writes the deviation value of the numerical state, the consistency or mismatch result of the discrete state, and the state field into the same record according to the physical twin node pair identifier and version position, and collects them to generate state mismatch data; Acquire historical building IoT data and historical digital twin data, generate a historical normal physical twin state sample set and input it into the improved MemAE model. Determine the training objective based on state reconstruction bias and paired slot matching bias, iteratively update the model parameters and the physical state prototypes and twin state prototypes in the paired memory slots, and obtain the trained improved MemAE model. Specifically, the trained improved MemAE model is as follows: Historical building IoT data and historical digital twin data are acquired. Historical intervals with normal equipment operation status records, established cross-version relationships between physical and digital twin states, and no delayed arrival of states are selected. A historical normal physical twin state sample set is generated according to physical twin node pairs, version order, adjacent states, and cross-time period changes. The first 80% of the historical normal physical twin state sample set is designated as training samples and the last 20% as validation samples according to time order. The training samples are input into the improved MemAE model. For numerical states, the absolute value of the difference between the normalized reconstructed value and the actual value is averaged. For discrete states, the normalized output probability corresponding to the actual category is read, and the difference between 1 and the output probability is averaged. The results from the physical side and the digital twin side are combined to form the state reconstruction bias. Read the paired memory slot with the highest joint matching degree, calculate the absolute value of the difference between the physical side matching degree and the twin side matching degree to form the paired slot matching bias; weight the state reconstruction bias and the paired slot matching bias with weights of 0.7 and 0.3 respectively, and sum them to determine the training objective; use the Adam optimization algorithm to iteratively update the parameters of the shared state encoding layer and the state reconstruction decoding layer with a learning rate of 0.001, and update the physical state prototype and twin state prototype in the paired memory slot according to the prototype retention ratio of 0.9 and the current encoding ratio of 0.1 for the allowed training samples; after each round of training, use the validation samples to calculate the training objective, and stop iterating when the decrease in the training objective is less than 0.0001 for 10 consecutive rounds, and obtain the improved MemAE model after training is completed.

[0028] In this embodiment, generating mismatch association clusters includes: Based on the physical twin node pairs and version order, the state mismatch data is pasted back to the physical nodes and twin nodes in the physical twin mapping graph, generating node mismatch markers. Specifically, generating node mismatch markers involves: Reconstruction deviations of each numerical state field are extracted from the historical normal physical twin state sample set. The samples are arranged in ascending order of deviation value. The sample size is multiplied by 95% and rounded up. The deviation value at the corresponding position is used as the mismatch threshold for the same state field. Physical state deviations and twin state deviations are read from the state mismatch data. Numerical state deviations exceeding the corresponding mismatch threshold are recorded as mismatches, while those below the threshold are recorded as normal. Discrete states are recorded directly based on consistency or mismatch results. A mismatch marker is generated when at least one mismatched state field exists at the same version position for the same physical node or twin node; a normal marker is generated when no mismatched state field exists. The generated markers are written into the physical node and twin node in the physical twin mapping graph according to the physical twin node pair and version position, forming node mismatch markers. Tracing node mismatch markers along the physical state version chain and the twin state version chain, filtering out nodes where physical nodes and their corresponding twin nodes exhibit state mismatch in consecutive versions, and generating a common mismatch node set, specifically: Read the node mismatch flags along the physical state version chain and the twin state version chain for the same physical twin node pair, and align the physical node version and the twin node version according to the cross version relationship; when both the physical node and the paired twin node have mismatch flags at the same cross version position, record the cross version position as a common mismatch version; check the continuity of common mismatch versions according to the version order, and determine that two adjacent common mismatch versions are continuous when there is no non-mismatch version interval in either the physical state version chain or the twin state version chain; when there are at least two consecutive versions of common mismatch versions, record the physical node and the paired twin node as common mismatch nodes; collect the common mismatch nodes and their corresponding common mismatch versions to generate a common mismatch node set; Based on the connection relationships in the physical twin mapping graph, nodes with common mismatches are associated. Nodes with overlapping mismatch versions and connections are merged to generate mismatch association clusters. Specifically, the generation of mismatch association clusters involves: Compare the common mismatch versions of node records in the common mismatch node set one by one. If two common mismatch nodes have at least one identical common mismatch version and have a direct connection in the physical twin mapping graph, establish a mismatch association relationship between the two common mismatch nodes. Select an unmerged common mismatch node as the starting node to establish an association set. Find common mismatch nodes that have a mismatch association relationship with any node in the association set and add them to the association set. Repeat the search and addition operation until no more common mismatch nodes are added to the association set. The association set is then determined as a mismatch association cluster. Repeat the association set construction process for the remaining unmerged common mismatch nodes to gather all mismatch association clusters.

[0029] In this embodiment, generating a valid set of abnormal nodes includes: From the delayed arrival states, filter states that match the mapped nodes within the mismatched cluster. Locate historical version states according to the physical twin node pairs and version order. Specifically, locating historical version states according to the physical twin node pairs and version order is as follows: Read the device identifier and acquisition time from the delayed arrival status. Compare the device identifier with the device identifier corresponding to the physical node in the mismatch association cluster item by item. If the values ​​are consistent, determine the matching mapping node through the physical twin node pair. Compare the acquisition time of the delayed arrival status with the acquisition time of each physical status version along the physical status version chain of the matching mapping node. Filter the physical status versions whose acquisition time is not later than the acquisition time of the delayed arrival status, and select the physical status version with the smallest time interval as the historical version position. Read the device running status in the historical version position as the historical version status. The historical version state is replaced with a delayed arrival state, and the synchronized state pair set and physical twin state sample set are updated. The updated physical twin state sample set is then input into the improved MemAE model. Under the condition that the paired memory slots remain unchanged, a re-detection is performed to generate verification state mismatch data. Specifically, the generation of verification state mismatch data involves: Write the delayed arrival state to the historical version location obtained from the positioning and replace the historical version state. Recombine the affected synchronization state pairs according to the existing cross-version relationship. Based on the updated synchronization state pairs, re-extract the adjacency states of the same physical twin node pair and directly connected nodes, and recalculate the cross-time change records of adjacent versions before and after the historical version location. Replace the state samples of the same physical twin node pair and version location in the physical twin state sample set. Freeze the physical state prototype and twin state prototype in the paired memory slot, stop the synchronous trusted writing layer from feeding back to the memory update end, input the updated physical twin state sample set into the improved MemAE model, regenerate physical state encoded data, twin state encoded data, slot matching data, paired memory read data, physical state reconstruction data, and twin state reconstruction data, and calculate the updated state deviation according to the comparison method of the state mismatch output layer. Gather according to the physical twin node pairs and version locations to generate the verification state mismatch data. Compare the verified state mismatch data with the current state mismatch data, remove mapping nodes whose mismatch has been eliminated after state replacement, retain mapping nodes with persistent mismatch, and generate a set of valid abnormal nodes. Specifically, the generation of the set of valid abnormal nodes is as follows: The system matches and verifies the state mismatch data with the physical twin node pairs and version positions. It reads the numerical state deviations and discrete state results from the verification state mismatch data. If the numerical state deviations do not exceed the mismatch threshold determined by the historical normal physical twin state sample set, and the discrete states are all recorded as consistent, the mapped node is determined to be mismatched and eliminated. If at least one numerical state deviation exceeds the mismatch threshold, or at least one discrete state is recorded as mismatched, the mapped node is determined to be continuously mismatched and retained. The system aggregates the retained mapped nodes and version positions according to the physical twin node pairs to generate a set of valid abnormal nodes.

[0030] In this embodiment, the generation of building IoT monitoring results includes: Tracing the mismatch status of the valid abnormal node set in the verification status mismatch data along the physical state version chain and the twin state version chain, determining the starting version of continuous mismatch, and generating a continuous mismatch record, specifically, generating a continuous mismatch record involves: Read the mismatch results of valid abnormal nodes in the review state mismatch data according to the physical twin node pairs and version order, and arrange them version by version along the physical state version chain and the twin state version chain; when two adjacent versions are both recorded as mismatched, and there is no version recorded as normal between the two versions, the adjacent versions are grouped into the same continuous mismatch interval; continuously perform version merging until a normal version is encountered or the version chain ends, and determine the earliest version in the continuous mismatch interval as the starting version and the latest version as the ending version; record the physical node, twin node, starting version, ending version and version position in the continuous mismatch interval to generate a continuous mismatch record; The persistent mismatch records are pasted back to the physical twin mapping graph. Abnormal nodes are traced along the connectivity relationships, and the earliest node exhibiting persistent mismatch is selected to generate the persistent mismatch initiation point. Specifically, generating the persistent mismatch initiation point involves: According to the physical twin node pairs, the persistent mismatch records are written to the abnormal nodes in the physical twin mapping graph. The starting version and persistent mismatch interval of the abnormal nodes with direct connection relationship are read. When the persistent mismatch intervals of two abnormal nodes have at least one version position, the starting version time is compared. The abnormal node with the later starting version moves along the connection relationship to the abnormal node with the earlier starting version, and continues to compare the starting version and persistent mismatch interval of the newly arrived node with the adjacent abnormal nodes. When there is no adjacent abnormal node with an earlier starting version and the same version position in the persistent mismatch interval, the tracing stops, and the abnormal node at the stopping position and the starting version are recorded as the starting point of persistent mismatch. When there are multiple stopping positions with the same starting version time, the corresponding abnormal node and the same starting version are recorded together as the starting point of persistent mismatch. The system aggregates a set of valid abnormal nodes, persistent mismatch records, and the starting point of persistent mismatch to generate building IoT monitoring results. Specifically, the generation of building IoT monitoring results includes: Based on the set of valid abnormal nodes matched by physical twin node pairs, the continuous mismatch records, and the starting point of continuous mismatch, the abnormal node identifier, starting version, ending version, continuous mismatch interval, and continuous mismatch starting point are written into the same monitoring record; the monitoring records belonging to the same physical twin node pair are merged and arranged from earliest to latest according to the starting version time, and all monitoring records are collected to generate the building IoT monitoring results.

[0031] refer to Figure 3 A building IoT monitoring system based on digital twins includes the following modules: The monitoring source data construction module is used to collect building IoT data and digital twin data to generate building monitoring source data; The physical twin mapping module is used to establish a bidirectional index between physical nodes and twin nodes, and generate a physical twin mapping graph; The state version synchronization module is used to construct physical state version chains and twin state version chains, mark delayed arrival states, and generate a set of synchronized state pairs. The state sample construction module is used to extract adjacent states and cross-time changes based on the set of synchronous state pairs to generate a physical twin state sample set; The state mismatch detection module is used to process the physical twin state sample set by improving the MemAE model and generate state mismatch data. The mismatch association merging module is used to filter and merge common mismatch nodes based on state mismatch data to generate mismatch association clusters. The delayed state verification module is used to update and verify the historical version state in the mismatch association cluster using the delayed arrival state, and generate a set of valid abnormal nodes. The continuous mismatch tracing module is used to trace the starting point of continuous mismatch in the set of valid abnormal nodes and generate building IoT monitoring results.

[0032] Example 1: To verify the feasibility of this invention in practice, it was applied to a building IoT monitoring scenario in a large public building. The building area is approximately 86,000 square meters, and 428 physical devices, including air conditioning units, water pumps, lighting controllers, power distribution monitoring terminals, and environmental sensors, were connected. 428 corresponding twin nodes were established in a digital twin platform. Seven days of continuous data collection were performed at a sampling period of 30 seconds, resulting in approximately 8.64 million building IoT records and 8.64 million digital twin status records. The building IoT records include device identifiers, temperature, current, power, start / stop status, connected object identifiers, and collection time. The digital twin status records include twin identifiers, associated device identifiers, twin node status, connected object identifiers, and update time.

[0033] The system matches physical monitoring records with twin monitoring records based on device identifiers and associated device identifiers. Records with matching values ​​are grouped into the same record group, and node connections are established based on the connection object identifier. This results in 428 physical twin node pairs. A forward index is created using the device identifier as the index key and the twin identifier as the index value, while a reverse index is created using the twin identifier as the index key and the device identifier as the index value. Physical node relationships are mapped to paired twin nodes, forming a physical twin mapping graph containing 428 physical nodes, 428 twin nodes, and 612 connection relationships. For example, after device identifier AHU-017 is matched with associated device identifier AHU-017, it forms a physical twin node pair with twin identifier DT-AHU-017. The connection relationship between device AHU-017 and chilled water pump P-006 is synchronously mapped to the relationship between DT-AHU-017 and DT-P-006.

[0034] The system arranges device operating status according to acquisition time and twin node status according to update time. Each status record is identified as a status version, and adjacent versions are connected to form a physical status version chain and a twin status version chain. For the same physical twin node pair, the twin status version with the smallest update time and acquisition time interval is selected to establish a cross-version relationship. This operation identified 1864 delayed arrival statuses, with the longest delay time being 173 seconds and the average delay time being 41.6 seconds. For example, the power status acquired by device P-021 at 10:16:30 was delayed due to edge buffering and merged after 10:18. The acquisition time falls between the already formed 10:16:00 version and the 10:17:00 version, therefore it is recorded as a delayed arrival status.

[0035] The system encapsulates device operating states and twin node states in pairs along cross-version relationships, and extracts directly connected one-hop adjacent node states from the physical twin mapping graph. For continuous numerical states, it records whether adjacent versions increase, decrease, or remain the same, and determines the magnitude of the change by the absolute value of the difference between the two versions; for discrete states, it records the state transition results. This ultimately results in approximately 2.86 million physical twin state samples, each containing a pair of synchronized states, a group of adjacent states, and cross-time period change records. For example, a sample of an air conditioning unit includes information such as the current supply air temperature of 12.8℃, the twin-side supply air temperature of 12.6℃, the adjacent chilled water valve opening of 71%, the supply air temperature increase of 0.4℃ from the previous version to the current version, and the operating state transitioning from low load to medium load.

[0036] The improved MemAE model includes a shared state encoding layer, a physical twin paired memory layer, a synchronous trusted write layer, a state reconstruction decoding layer, and a state mismatch output layer. The shared state encoding layer maps the physical and twin states to a 128-dimensional feature space using the same encoding parameters. The physical twin paired memory layer has 64 paired memory slots, each storing the physical state prototype and the twin state prototype respectively. Slot matching is performed on the physical and twin state encoded data separately. The matching results from both the physical and twin sides are combined with a weight of 0.5 to obtain the joint matching degree and generate normalized read weights. In a set of normal air conditioning unit samples, the highest matching degree on the physical side is 0.91, and the highest matching degree on the twin side is 0.89, both pointing to paired memory slot number 18, with a joint matching degree of 0.90.

[0037] The synchronous trusted write layer assesses time correspondence, slot matching consistency, and state change continuity. The upper limit for the continuity of numerical states is the 95th quantile of the same type of change amplitude in historical normal samples. Discrete states are only allowed to have state transition combinations that have appeared in historical normal samples. A write permission flag is generated when all three conditions are met. During operation, 92.7% of the samples met the trusted write conditions; the remaining samples did not participate in paired memory slot updates. For a sample with a supply air temperature change amplitude of 3.8℃, the 95th quantile of the same type of historical normal change amplitude is 1.6℃. The system determines that the state change continuity requirement is not met and does not allow the state code to be written to the paired memory slot.

[0038] The model training used the first 80% of historical normal samples as the training set and the last 20% as the validation set. State reconstruction bias and paired slot matching bias were weighted at 0.7 and 0.3 respectively to determine the training objectives, and the Adam optimization algorithm was used for training with a learning rate of 0.001. Allowed write samples updated the paired memory slots according to a prototype retention ratio of 0.9 and a current encoding ratio of 0.1. Training stopped at epoch 46 when the validation set training objective decreased by less than 0.0001 for 10 consecutive epochs. After training, the average reconstruction bias on the physical side decreased from 0.084 to 0.031, and the average reconstruction bias on the twin side decreased from 0.079 to 0.029.

[0039] During online monitoring, the state reconstruction decoding layer outputs physical state reconstruction data and twin state reconstruction data, while the state mismatch output layer compares the reconstruction results with the actual states in the synchronized state pairs item by item. The system uses the 95th percentile of the reconstruction deviation of each numerical state field in historical normal samples as the mismatch threshold. When the numerical state deviation exceeds the corresponding threshold, or when the discrete state reconstruction result is inconsistent with the actual state, the node is marked as mismatched in the corresponding version. For example, the actual power of device P-034 in a certain version is 18.7kW, the reconstructed power is 15.1kW, the deviation is 3.6kW, which is higher than the corresponding mismatch threshold of 2.1kW, so it is recorded as a numerical state mismatch.

[0040] After continuous version checks, a total of 37 groups of nodes with common mismatches were identified. The system merged nodes with direct connections and at least one identical mismatched version into 9 mismatch clusters. The largest mismatch cluster contained 8 physical nodes and 8 twin nodes, with 14 persistent mismatched versions. The largest mismatch cluster mainly covered one chilled water pump, two air conditioning units, and associated valve nodes, with the node mismatch time concentrated between 14:32 and 14:39.

[0041] For 9 mismatch clusters, a total of 126 delayed arrival states were matched. The system located historical version states according to device identifier and acquisition time, and used the delayed arrival states to replace them, regenerating the affected synchronization state pairs, adjacent state groups, and cross-time period change records. During the review, the physical state prototype and twin state prototype in the pairing memory slot were frozen, memory writing was stopped, and only the updated state samples were re-encoded, memory read, state reconstruction, and mismatch detection were re-executed. After review, 11 groups of node mismatches were eliminated, and the remaining 26 groups of nodes formed a valid set of abnormal nodes. Among them, the original temperature recorded by a certain environmental sensor was 26.8℃. After the delayed arrival state was corrected to 24.9℃, the reconstruction deviations of the physical side and the twin side both decreased to within the corresponding mismatch threshold, and the node was removed from the abnormal results.

[0042] The system tracks continuous mismatch intervals for 26 groups of valid abnormal nodes and identifies the earliest mismatch version as the starting version. After the continuous mismatch records are pasted onto the physical twin mapping graph, they are traced along direct connections from nodes with later starting versions to nodes with earlier starting versions, ultimately identifying four continuous mismatch starting points. On-site verification results show that three of these starting points correspond to actual equipment faults: abnormal chilled water pump bearings, stuck air supply valves in air conditioning units, and abnormal loads in power distribution branches; one starting point corresponds to an abnormal controller configuration. The system ultimately generates a building IoT monitoring record, recording the abnormal node identifier, starting version, ending version, continuous mismatch interval, and continuous mismatch starting point for maintenance personnel to query.

[0043] On the same test data, the present invention was compared with the traditional MemAE model. The anomaly identification accuracy of the traditional MemAE model was 88.6%, while that of the present invention was 95.8%; the false alarm rate of the traditional MemAE model was 9.7%, while that of the present invention was 3.4%; the elimination rate of false anomalies caused by delayed arrival data of the traditional MemAE model was 41.2%, while that of the present invention was 82.5%; the average positioning error of the starting point of continuous anomalies of the traditional method was 4.6 versions, while that of the present invention was 1.3 versions; the identification rate of samples with normal physical state but abnormal virtual-real correspondence of the traditional MemAE model was 68.9%, while that of the present invention was improved to 91.7%. This embodiment demonstrates that the present invention can maintain high mismatch detection accuracy when there are update delays, version misalignments, and local correlation anomalies between the physical state and the digital twin state, and reduces false anomalies through delayed arrival state verification, while improving the reliability of locating the starting point of continuous mismatch, thus verifying the engineering feasibility of the present invention in building digital twin monitoring scenarios.

[0044] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A building IoT monitoring method based on digital twins, characterized in that, include: Collect building IoT data and digital twin data, and merge them according to device identifier, twin identifier, connection relationship and timestamp to generate building monitoring source data; A physical twin bidirectional index is established based on building monitoring source data to generate a physical twin mapping map; Based on the physical twin mapping graph, construct the physical state version chain and the twin state version chain, establish cross-version relationships according to time and mark the delayed arrival state to generate a set of synchronized state pairs; Extract the adjacent states and cross-time changes of the synchronized state pair set along the physical twin mapping graph to generate a physical twin state sample set; The physical twin state sample set is input into the improved MemAE model to generate state mismatch data. The improved MemAE model includes a shared state encoding layer, a physical twin pairing memory layer, a synchronous trusted writing layer, a state reconstruction decoding layer, and a state mismatch output layer. The mismatch data is pasted back to the physical twin mapping graph. Common mismatch nodes are selected along the physical state version chain and the twin state version chain and merged according to the connection relationship to generate mismatch association clusters. Replace the historical version state of the mapped node in the mismatched cluster with the delayed arrival state, verify the state mismatch, and generate a valid set of abnormal nodes; Tracing the point of continuous mismatch of the effective set of abnormal nodes along the physical twin map generates building IoT monitoring results.

2. The building IoT monitoring method based on digital twin according to claim 1, characterized in that, The generated building monitoring source data includes: The system collects building IoT data, aggregates equipment operation records by device identifier, extracts connection object identifiers and collection time, and generates physical monitoring records. The building IoT data includes device identifiers, device operating parameters, device operating status, connection object identifiers, and collection time. Collect digital twin data, aggregate twin node records according to twin identifiers, extract associated device identifiers, connected object identifiers, and update times, and generate twin-side monitoring records; the digital twin data includes twin identifiers, associated device identifiers, twin node status, connected object identifiers, and update times; By associating physical monitoring records and twin monitoring records with the device identifier and associated device identifier, the connection object identifiers are merged into connection relationships, and the acquisition time and update time are retained to generate building monitoring source data.

3. The building IoT monitoring method based on digital twin according to claim 1, characterized in that, The generation of the physical twin mapping includes: Establish physical nodes and their relationships based on the device identifiers and connection relationships in the building monitoring source data; Twin nodes are established based on twin identifiers and associated device identifiers, and physical nodes are paired with twin nodes to generate physical twin node pairs; Based on the physical twin node pairs, establish bidirectional indexes from physical nodes to twin nodes and from twin nodes to physical nodes, and map the physical node relationships to the paired twin nodes to generate a physical twin mapping graph.

4. The building IoT monitoring method based on digital twin according to claim 1, characterized in that, The generation of the synchronization state pair set includes: Based on the physical twin node and the associated physical monitoring records and twin monitoring records, the device operating status is arranged by collection time, and the twin node status is arranged by update time, generating a physical status version chain and a twin status version chain. Associate the physical state version chain and the twin state version chain, establish a cross-version relationship between the operating states of devices with adjacent times and the twin node states, and mark the operating states of devices that belong to existing historical versions after the cross-version is formed as delayed arrival states. The device operating status and twin node status of the same physical twin node pair are filtered along the cross-version relationship, and the pairs are encapsulated in version order to generate a set of synchronized status pairs.

5. A building IoT monitoring method based on digital twins according to claim 1, characterized in that, The generated physical twin state sample set includes: Based on the connection relationship in the physical twin mapping graph, the states of adjacent physical nodes and adjacent twin nodes are extracted from the synchronization state pairs in the synchronization state pair set to generate an adjacency state group. Extract the state changes of the same physical twin node to adjacent versions along the physical state version chain and the twin state version chain, organize them according to the direction and magnitude of the change, and generate cross-time period change records; Synchronous state pairs are combined with their corresponding adjacent state groups and cross-time change records, and arranged according to the physical twin node pairs and version order to generate a physical twin state sample set.

6. The building IoT monitoring method based on digital twin according to claim 1, characterized in that, The generated state mismatch data includes: The encoder based on the MemAE model forms a shared state encoding layer, replaces the memory module with a physical twin paired memory layer, adds a synchronous trusted write layer, and establishes a forward connection from the physical twin paired memory layer to the synchronous trusted write layer and a feedback connection from the synchronous trusted write layer to the physical twin paired memory layer; a state reconstruction decoding layer is formed based on the decoder, and a state mismatch output layer is added after the state reconstruction decoding layer to form an improved MemAE model. The physical twin state sample set is input into the shared state coding layer to encode synchronous state pairs, adjacent state groups and cross-time period change records, generating physical state coding data and twin state coding data. The physical state encoded data and twin state encoded data are input into the physical twin pairing memory layer, and the physical state prototype and twin state prototype in the pairing memory slot are jointly matched to generate pairing memory read data and slot matching data. The slot matching data and physical twin state sample set are input into the synchronous trusted writing layer. Trusted writing tags are generated based on time correspondence, slot matching consistency and state change continuity, and fed back to the physical twin pairing memory layer to update the pairing memory slots. The paired memory read data is input into the state reconstruction decoding layer to generate physical state reconstruction data and twin state reconstruction data; The physical state reconstruction data and twin state reconstruction data are input into the state mismatch output layer and compared with the device operating state and twin node state in the synchronized state pair to generate state mismatch data. Acquire historical building IoT data and historical digital twin data, generate a historical normal physical twin state sample set and input it into the improved MemAE model, determine the training objective based on state reconstruction deviation and pairing slot matching deviation, iteratively update the model parameters and the physical state prototype and twin state prototype in the pairing memory slot, and obtain the trained improved MemAE model.

7. A building IoT monitoring method based on digital twins according to claim 1, characterized in that, The generation of mismatch association clusters includes: According to the physical twin node pairs and version order, the state mismatch data is pasted back to the physical nodes and twin nodes in the physical twin mapping diagram to generate node mismatch markers; Track node mismatch markers along the physical state version chain and the twin state version chain, filter out nodes in which physical nodes and their corresponding twin nodes simultaneously exhibit state mismatch in consecutive versions, and generate a set of nodes with common mismatches. By associating common mismatch nodes according to the connection relationship in the physical twin mapping graph, common mismatch nodes that have connection relationships and overlap mismatch versions are merged to generate mismatch association clusters.

8. A building IoT monitoring method based on digital twins according to claim 1, characterized in that, The generated set of valid anomaly nodes includes: Filter the delayed arrival states to match the mapped nodes within the mismatched cluster, and locate the historical version states according to the physical twin node pairs and version order; By replacing the historical version state with the delayed arrival state, updating the synchronized state pair set and the physical twin state sample set, and inputting the updated physical twin state sample set into the improved MemAE model, the system re-detects under the condition that the pairing memory slots remain unchanged, and generates verification state mismatch data. Compare the verification state mismatch data with the state mismatch data, remove the mapping nodes whose mismatch is eliminated after state replacement, retain the mapping nodes with continuous mismatch, and generate a set of valid abnormal nodes.

9. A building IoT monitoring method based on digital twins according to claim 1, characterized in that, The generated building IoT monitoring results include: Track the mismatch status of the valid abnormal node set in the review status mismatch data along the physical state version chain and the twin state version chain, determine the starting version of the continuous mismatch, and generate a continuous mismatch record; The persistent mismatch records are pasted back to the physical twin mapping graph, the abnormal nodes are traced along the connection relationship, the earliest node with persistent mismatch is selected, and the persistent mismatch starting point is generated. The system aggregates a set of valid abnormal nodes, records of continuous mismatches, and the starting point of continuous mismatches to generate building IoT monitoring results.

10. A building IoT monitoring system based on digital twins, comprising the building IoT monitoring method based on digital twins as described in any one of claims 1 to 9, characterized in that, Includes the following modules: The monitoring source data construction module is used to collect building IoT data and digital twin data to generate building monitoring source data; The physical twin mapping module is used to establish a bidirectional index between physical nodes and twin nodes, and generate a physical twin mapping graph; The state version synchronization module is used to construct physical state version chains and twin state version chains, mark delayed arrival states, and generate a set of synchronized state pairs. The state sample construction module is used to extract adjacent states and cross-time changes based on the set of synchronous state pairs to generate a physical twin state sample set; The state mismatch detection module is used to process the physical twin state sample set by improving the MemAE model and generate state mismatch data. The mismatch association merging module is used to filter and merge common mismatch nodes based on state mismatch data to generate mismatch association clusters. The delayed state verification module is used to update and verify the historical version state in the mismatch association cluster using the delayed arrival state, and generate a set of valid abnormal nodes. The continuous mismatch tracing module is used to trace the starting point of continuous mismatch in the set of valid abnormal nodes and generate building IoT monitoring results.