Data synchronization method, device and computer equipment for virtual simulation platform
By using reinforcement learning and time series prediction models in the virtual simulation platform, dynamically adjusting the data synchronization frequency, solving the problem that traditional fixed synchronization frequency mechanism is difficult to adapt to changes in complex environments, achieving efficient and real-time data synchronization, and improving system performance.
Patent Information
- Application Number
- CN202510092226.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-21
- Publication Date
- 2025-04-22
- Estimated Expiration
- 2045-01-21
AI Technical Summary
The traditional fixed synchronization frequency mechanism is difficult to adapt to complex environmental changes in multi-platform heterogeneous simulation systems, resulting in inefficient synchronization or waste of resources.
By introducing reinforcement learning and time series prediction models, the simulation status information of each heterogeneous virtual simulation sub-platform is collected in real time, and the data synchronization frequency is dynamically adjusted to adapt to changes in system state and network conditions.
It improves the accuracy and real-time data synchronization between different simulation platforms, reduces the impact of system overload and network delay on synchronization efficiency, and improves the overall operating performance and stability of the system.
Smart Images

Figure CN119513208B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of simulation technology, and in particular to a data synchronization method, device and computer equipment for a virtual simulation platform. Background Art
[0002] In multi-platform heterogeneous simulation systems, the real-time and accuracy of data synchronization are crucial, especially when it comes to the collaborative operation of semi-physical simulation, VR simulation, and computer virtual simulation systems. The clock synchronization, network delay, and load fluctuations between different simulation platforms will affect the overall performance of the system. At present, the traditional fixed synchronization frequency mechanism is difficult to adapt to these complex environmental changes, resulting in low synchronization efficiency or waste of resources.
[0003] In traditional technologies, although manually setting the synchronization frequency can improve system performance to a certain extent, it cannot dynamically respond to real-time changes in system status, especially when the system load, network status, and clock deviation fluctuate greatly, fixed synchronization strategies are difficult to meet the needs of efficient synchronization. Therefore, there is an urgent need for an adaptive synchronization frequency adjustment method that can dynamically adjust the synchronization frequency according to the real-time status and network conditions of each platform to improve the efficiency of data synchronization and the overall performance of the system. Summary of the invention
[0004] Based on this, it is necessary to provide a data synchronization method, device and computer equipment for a virtual simulation platform to address the above technical problems.
[0005] A data synchronization method for a virtual simulation platform is applied to the virtual simulation platform, wherein the virtual simulation platform includes a plurality of heterogeneous virtual simulation sub-platforms, a data synchronization management module, and a feedback and supervision module, and the method includes:
[0006] The data synchronization management module receives the simulation data of each heterogeneous virtual simulation sub-platform, and collects the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module;
[0007] Inputting the simulation state information into a pre-trained time series model, and outputting the predicted simulation state information at the next moment;
[0008] Inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency;
[0009] Data synchronization of each heterogeneous virtual simulation sub-platform is performed according to the data synchronization frequency.
[0010] In one embodiment, the simulation status information is:
[0011] ;
[0012] is the system load indicator, It's network latency. is the packet loss rate, is the clock bias, is the current synchronization frequency.
[0013] In one embodiment, the method further includes: inputting the simulation state information into a pre-trained time series model, and outputting the predicted simulation state information at the next moment as:
[0014] ;
[0015] in, Represents the predicted simulation state information, and n represents the length of the time window.
[0016] In one embodiment, the simulation state information and the predicted simulation state information are also used to As input to reinforcement learning models;
[0017] The action space is defined as increasing synchronization frequency, decreasing synchronization frequency, and maintaining synchronization frequency;
[0018] Define a reward function based on simulation state information;
[0019] A policy updating algorithm is used to select the best action in each time step to adjust the synchronization frequency.
[0020] In one of the embodiments, the clock deviation is also monitored in real time. When the clock deviation is greater than a threshold, clock synchronization is performed by reducing the synchronization frequency until the clock deviation is less than the threshold.
[0021] A data synchronization device for a virtual simulation platform is applied to the virtual simulation platform, wherein the virtual simulation platform includes a plurality of heterogeneous virtual simulation sub-platforms, a data synchronization management module, and a feedback and supervision module, and the device includes:
[0022] A monitoring module, used for receiving simulation data of each heterogeneous virtual simulation sub-platform, and collecting simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module;
[0023] A prediction module, used for inputting the simulation state information into a pre-trained time series model and outputting the predicted simulation state information at the next moment;
[0024] A synchronization frequency adjustment module, used for inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency;
[0025] The data synchronization module is used to synchronize the data of each heterogeneous virtual simulation sub-platform according to the data synchronization frequency.
[0026] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0027] The data synchronization management module receives the simulation data of each heterogeneous virtual simulation sub-platform, and collects the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module;
[0028] Inputting the simulation state information into a pre-trained time series model, and outputting the predicted simulation state information at the next moment;
[0029] Inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency;
[0030] Data synchronization of each heterogeneous virtual simulation sub-platform is performed according to the data synchronization frequency.
[0031] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the following steps:
[0032] The data synchronization management module receives the simulation data of each heterogeneous virtual simulation sub-platform, and collects the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module;
[0033] Inputting the simulation state information into a pre-trained time series model, and outputting the predicted simulation state information at the next moment;
[0034] Inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency;
[0035] Data synchronization of each heterogeneous virtual simulation sub-platform is performed according to the data synchronization frequency.
[0036] The data synchronization method, device, computer equipment and storage medium of the above virtual simulation platform can dynamically adjust the data synchronization frequency according to the real-time status of the multi-platform simulation system (including system load, network delay, clock deviation, etc.) by introducing reinforcement learning and time series prediction models, thereby realizing adaptive optimization synchronization strategy. This method not only improves the accuracy and real-time performance of data synchronization between different simulation platforms, but also effectively reduces the impact of system overload and network delay on synchronization efficiency, and improves the overall operation performance and stability of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 A schematic diagram of a flow chart of a data synchronization method for a virtual simulation platform in an embodiment;
[0038] Figure 2 A structural block diagram of a data synchronization device for a virtual simulation platform in an embodiment;
[0039] Figure 3 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0040] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0041] In one embodiment, Figure 1 As shown, a data synchronization method for a virtual simulation platform is provided, and the method is applied to the virtual simulation platform, wherein the virtual simulation platform includes a plurality of heterogeneous virtual simulation sub-platforms, a data synchronization management module, and a feedback and supervision module, and includes the following steps:
[0042] Step 102: The data synchronization management module receives the simulation data of each heterogeneous virtual simulation sub-platform, and collects the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module.
[0043] The data synchronization management module includes a central coordination unit, a local control unit, and a data transmission module. The central coordination unit, as a global controller, is responsible for dynamically adjusting the synchronization frequency according to the status of each simulation system (load, delay, clock deviation, etc.). Local control unit: Each simulation system (such as HIL simulation system, VR simulation system, and computer virtual simulation system) has its own local control unit to communicate with the central coordination unit. The local unit collects real-time data such as system load and network status and sends it to the central unit. Data transmission module: Responsible for transmitting data between systems. The transmission rate and frequency are adjusted according to the instructions of the central coordination unit.
[0044] The feedback and supervision modules include: delay monitoring module, system load monitoring module and clock synchronization module. The delay monitoring module monitors the delay time of each data transmission and feeds back to the central coordination unit. The system load monitoring module monitors the CPU, memory, network bandwidth and other load conditions of each simulation system. The clock synchronization module will regularly report the clock deviation between the simulation systems to assist in adjusting the synchronization strategy.
[0045] Step 104, input the simulation state information into the pre-trained time series model, and output the predicted simulation state information at the next moment.
[0046] The time series model is trained based on historical data. The time series model can be ARIMA, LSTM, etc. The model predicts future system load, network delay, clock deviation, etc. based on past status data.
[0047] Step 106, inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency.
[0048] The reinforcement learning model obtains rewards based on the current state and actions through interaction with the environment, and continuously updates the strategy so that it can select the optimal synchronization frequency under different states.
[0049] Step 108: synchronize the data of each heterogeneous virtual simulation sub-platform according to the data synchronization frequency.
[0050] In the data synchronization method of the above virtual simulation platform, by introducing reinforcement learning and time series prediction models, the data synchronization frequency can be dynamically adjusted according to the real-time status of the multi-platform simulation system (including system load, network delay, clock deviation, etc.), thereby realizing an adaptive optimization synchronization strategy. This method not only improves the accuracy and real-time performance of data synchronization between different simulation platforms, but also effectively reduces the impact of system overload and network delay on synchronization efficiency, and improves the overall operating performance and stability of the system.
[0051] In one embodiment, the simulation status information is:
[0052] ;
[0053] is the system load indicator, It's network latency. is the packet loss rate, is the clock bias, is the current synchronization frequency.
[0054] In another embodiment, the simulation state information is input into a pre-trained time series model, and the predicted simulation state information at the next moment is output as:
[0055] ;
[0056] in, Represents the predicted simulation state information, and n represents the length of the time window.
[0057] Specifically, the time series model predicts the future system status based on historical data collected in real time:
[0058] 1. Predict network delay: Predict possible future network delay peaks so as to adjust the synchronization frequency in advance
[0059] 2. Predict system load: Predict the changing trend of system load to ensure that the synchronization frequency is reduced when the load increases to avoid system overload.
[0060] 3. Predict clock deviation: Detect changes in clock deviation and adjust the clock synchronization strategy in advance.
[0061] Based on the results of time series forecasting, the system can adjust the synchronization frequency in advance. For example:
[0062] 1. If it is predicted that network latency will increase in the future, the synchronization frequency can be reduced in advance to reduce the pressure of data transmission.
[0063] 2. If it is predicted that the system load will decrease in the future, the synchronization frequency can be increased to improve the accuracy and real-time performance of synchronization.
[0064] In one embodiment, the simulation state information and the predicted simulation state information are As the input of the reinforcement learning model; define the action space as increasing the synchronization frequency, decreasing the synchronization frequency, and maintaining the synchronization frequency; define the reward function based on the simulation state information; use the policy update algorithm to select the best action in each time step to adjust the synchronization frequency.
[0065] Each action corresponds to a specific synchronization frequency adjustment strategy. For example:
[0066] 1. When increasing the synchronization frequency, data synchronization is adjusted from 10 times per second to 20 times per second.
[0067] 2. When reducing the synchronization frequency, the synchronization frequency is adjusted from 20 times per second to 10 times per second.
[0068] In one of the embodiments, the clock deviation is monitored in real time, and when the clock deviation is greater than a threshold, the clock synchronization is performed by reducing the synchronization frequency until the clock deviation is less than the threshold.
[0069] It should be understood that although Figure 1 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 2At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.
[0070] In one embodiment, Figure 2 As shown, a data synchronization device for a virtual simulation platform is provided, which is applied to the virtual simulation platform. The virtual simulation platform includes multiple heterogeneous virtual simulation sub-platforms, a data synchronization management module and a feedback and supervision module, including: a monitoring module 202, a prediction module 204, a synchronization frequency adjustment module 206 and a data synchronization module 208, wherein:
[0071] The monitoring module 202 is used to receive the simulation data of each heterogeneous virtual simulation sub-platform, and collect the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module;
[0072] Prediction module 204, used for inputting the simulation state information into a pre-trained time series model and outputting the predicted simulation state information at the next moment;
[0073] A synchronization frequency adjustment module 206, configured to input the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency;
[0074] The data synchronization module 208 is used to synchronize the data of each heterogeneous virtual simulation sub-platform according to the data synchronization frequency.
[0075] In one embodiment, the simulation status information is:
[0076] ;
[0077] is the system load indicator, It's network latency. is the packet loss rate, is the clock bias, is the current synchronization frequency.
[0078] In one embodiment, the prediction module 204 is further used to input the simulation state information into a pre-trained time series model, and output the predicted simulation state information at the next moment as:
[0079] ;
[0080] in, Represents the predicted simulation state information, and n represents the length of the time window.
[0081] In one embodiment, the synchronization frequency adjustment module 206 is further configured to convert the simulation state information and the predicted simulation state information into As the input of the reinforcement learning model; define the action space as increasing the synchronization frequency, decreasing the synchronization frequency, and maintaining the synchronization frequency; define the reward function based on the simulation state information; use the policy update algorithm to select the best action in each time step to adjust the synchronization frequency.
[0082] In one embodiment, the synchronization frequency adjustment module 206 is further configured to monitor the clock deviation in real time, and when the clock deviation is greater than a threshold, the clock synchronization is performed by reducing the synchronization frequency until the clock deviation is less than the threshold.
[0083] For the specific definition of the data synchronization device of the virtual simulation platform, please refer to the definition of the data synchronization method of the virtual simulation platform mentioned above, which will not be repeated here. Each module in the data synchronization device of the above virtual simulation platform can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0084] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 3 As shown. The computer device includes a processor, a memory, a network interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a data synchronization method for a virtual simulation platform is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a key, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.
[0085] Those skilled in the art will understand that Figure 3The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0086] In one embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the method in the above embodiment when executing the computer program.
[0087] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method in the above embodiment are implemented.
[0088] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0089] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0090] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A data synchronization method for a virtual simulation platform, characterized in that: Applied in a virtual simulation platform, the virtual simulation platform includes a plurality of heterogeneous virtual simulation sub-platforms, a data synchronization management module and a feedback and supervision module, the method includes: The data synchronization management module receives the simulation data of each heterogeneous virtual simulation sub-platform, and collects the simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module; Inputting the simulation state information into a pre-trained time series model, and outputting the predicted simulation state information at the next moment; Inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency; Performing data synchronization on each heterogeneous virtual simulation sub-platform according to the data synchronization frequency; The simulation status information is: is the system load indicator, It's network delay. is the packet loss rate, is the clock bias, is the current synchronization frequency.
2. The data synchronization method of the virtual simulation platform according to claim 1, characterized in that: Inputting the simulation state information into a pre-trained time series model and outputting the predicted simulation state information at the next moment, including: The simulation state information is input into the pre-trained time series model, and the predicted simulation state information at the next moment is output as: in, represents the predicted simulation state information, n represents the time window length, Represents a time series model.
3. The data synchronization method of the virtual simulation platform according to claim 2, characterized in that: Inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency, including: The simulation state information and the predicted simulation state information As input to reinforcement learning models; The action space is defined as increasing synchronization frequency, decreasing synchronization frequency, and maintaining synchronization frequency; Define a reward function based on simulation state information; A policy updating algorithm is used to select the best action in each time step to adjust the synchronization frequency.
4. The data synchronization method of a virtual simulation platform according to any one of claims 1 to 3, characterized in that: The method further comprises: The clock deviation is monitored in real time, and when the clock deviation is greater than a threshold, the clock synchronization is performed by reducing the synchronization frequency until the clock deviation is less than the threshold.
5. A data synchronization device for a virtual simulation platform, characterized in that: Applied in a virtual simulation platform, the virtual simulation platform includes a plurality of heterogeneous virtual simulation sub-platforms, a data synchronization management module and a feedback and supervision module, the device includes: A monitoring module, used for receiving simulation data of each heterogeneous virtual simulation sub-platform, and collecting simulation status information of each heterogeneous virtual simulation sub-platform in real time through the feedback and supervision module; A prediction module, used for inputting the simulation state information into a pre-trained time series model and outputting the predicted simulation state information at the next moment; A synchronization frequency adjustment module, used for inputting the simulation state information and the predicted simulation state information into a pre-trained reinforcement learning model so that the reinforcement learning model outputs an optimal data synchronization frequency; A data synchronization module, used for performing data synchronization of various heterogeneous virtual simulation sub-platforms according to the data synchronization frequency; The simulation status information is: is the system load indicator, It's network latency. is the packet loss rate, is the clock bias, is the current synchronization frequency.
6. The data synchronization device for a virtual simulation platform according to claim 5, characterized in that: The prediction module is also used to input the simulation state information into a pre-trained time series model, and output the predicted simulation state information at the next moment as: in, represents the predicted simulation state information, n represents the time window length, Represents a time series model.
7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the data synchronization method of the virtual simulation platform described in any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Data synchronization method, device and system and database
CN106095969A
Data synchronization method suitable for large-scale distributed cluster simulation
CN118158238A