A spatio-temporal sequence prediction method and system based on thought chain enhancement
Patent Information
- Application Number
- CN202511716022.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-21
- Publication Date
- 2026-10-20
- Estimated Expiration
- 2045-11-21
AI Technical Summary
这类数据具有复杂的时间依赖性和空间相关性,准确预测面临诸多挑战
本方法通过训练得到包含时空特征提取编码模块、思维链推理网络以及噪声预测网络的扩散模型;对原始目标流场数据逐步添加高斯噪声,生成纯噪声分布的含噪流场数据;采用时空特征提取编码模块,提取每个时间步的历史流场时空序列数据中的空间特征,将每个时间步的空间特征沿时间维度拼接,得到时空融合特征,并将时空融合特征编码为上下文特征;基于当前含噪流场数据、时间步嵌入以及上下文特征,构建初始推理状态;采用思维链推理网络对初始推理状态执行多步思维链推理,得到最终推理状态;基于最终推理状态,通过噪声预测网络确定预测噪声,并根据预测噪声对纯噪声分布的含噪流场数据进行去噪更新,直到完全去噪后,得到目标时空序列预测结果。如此,时空特征提取编码模块通过分层处理空间和时间依赖关系,有效捕获了时空序列数据的复杂模式,为准确预测时空序列提供了丰富的特征表示;采用思维链推理网络对初始推理状态执行多步思维链推理,提供了预测过程的可解释路径,能够捕获时空序列数据中的复杂依赖关系,通过渐进式推理减少预测误差;最后基于最终推理状态,通过噪声预测网络确定预测噪声,再根据预测噪声执行去噪更新,以得到目标时空序列预测结果,能够提高时空序列预测的精确度和可靠性。
Smart Images

Figure CN122692874B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of spatiotemporal sequence prediction technology, and in particular to a spatiotemporal sequence prediction method and system based on thought chain enhancement. Background Technology
[0002] Spatiotemporal series data are widely used in practical applications such as weather forecasting, traffic flow prediction, and air quality monitoring. This type of data exhibits complex temporal dependencies and spatial correlations, posing numerous challenges to accurate prediction. Traditional spatiotemporal series prediction methods often struggle to capture deep correlations in high-dimensional, complex spatiotemporal models, limiting the accuracy of predictions. Particularly in long-term spatiotemporal series prediction tasks, error accumulation severely impacts the reliability of predictions. Summary of the Invention
[0003] This application aims to propose a spatiotemporal sequence prediction method and system based on thought chain enhancement, which can improve the accuracy and reliability of spatiotemporal sequence prediction.
[0004] In a first aspect, embodiments of this application provide a spatiotemporal sequence prediction method based on thought chain enhancement, the method comprising: Acquire historical spatiotemporal sequence data of the flow field, including fluid velocity field, pressure field, and temperature field, as well as the original target flow field data; The training yielded a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain reasoning network, and a noise prediction network. Gaussian noise is gradually added to the original target flow field data to generate noisy flow field data with pure noise distribution; The spatiotemporal feature extraction and encoding module is used to extract spatial features from the historical flow field spatiotemporal sequence data of each time step, and the spatial features of each time step are spliced along the time dimension to obtain spatiotemporal fusion features, and the spatiotemporal fusion features are encoded as context features. Based on the current noisy flow field data, time step embedding, and the aforementioned context features, an initial inference state is constructed; The initial reasoning state is subjected to multi-step reasoning using the aforementioned thought chain reasoning network to obtain the final reasoning state. Based on the final inference state, the predicted noise is determined by the noise prediction network, and the noisy flow field data of the pure noise distribution is updated by denoising according to the predicted noise until complete denoising is achieved, and the target spatiotemporal sequence prediction result is obtained.
[0005] Compared with the prior art, the first aspect of this application has the following beneficial effects: This method trains a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network. Gaussian noise is progressively added to the original target flow field data to generate noisy flow field data with a pure noise distribution. The spatiotemporal feature extraction and encoding module extracts spatial features from the historical flow field spatiotemporal sequence data at each time step, concatenates these features along the time dimension to obtain spatiotemporal fusion features, and encodes these fusion features as context features. An initial inference state is constructed based on the current noisy flow field data, time step embeddings, and context features. The thought chain inference network performs multi-step thought chain inference on the initial inference state to obtain the final inference state. Based on the final inference state, the noise prediction network determines the prediction noise, and the noisy flow field data with a pure noise distribution is updated to remove noise based on the prediction noise until complete denoising is achieved, resulting in the target spatiotemporal sequence prediction result. Thus, the spatiotemporal feature extraction and encoding module effectively captures the complex patterns of spatiotemporal sequence data by processing spatial and temporal dependencies in a hierarchical manner, providing rich feature representations for accurate prediction of spatiotemporal sequences. The use of a thought chain reasoning network to perform multi-step thought chain reasoning on the initial reasoning state provides an interpretable path for the prediction process, enabling the capture of complex dependencies in spatiotemporal sequence data and reducing prediction errors through progressive reasoning. Finally, based on the final reasoning state, a noise prediction network is used to determine the prediction noise, and then denoising and updating are performed based on the prediction noise to obtain the prediction result of the target spatiotemporal sequence, which can improve the accuracy and reliability of spatiotemporal sequence prediction.
[0006] In some implementations, the training yields a diffusion model comprising a spatiotemporal feature extraction encoding module, a thought chain reasoning network, and a noise prediction network, including: Construct a denoising loss function, and construct a thought chain consistency loss function; The total loss function is obtained by weighted summing of the denoising loss function and the thought chain consistency loss function. Based on the total loss function, a diffusion model including a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network is trained.
[0007] In some implementations, the construction of the thought chain consistency loss function includes: ; in, This represents the consistency loss function of the thought chain. This represents the total number of steps in the thought process chain. Indicates the first Weight of step-by-step reasoning This indicates that the current student network is in the [number]th [period]. Denoising steps and the first The intermediate reasoning states of each reasoning stage The teacher network is in the first Denoising steps and the first The target reasoning state is generated in each reasoning stage.
[0008] In some implementations, the spatiotemporal feature extraction and encoding module includes a graph convolutional network, a temporal convolutional network, and a linear transform layer. The module extracts spatial features from the historical flow field spatiotemporal sequence data at each time step, concatenates the spatial features of each time step along the time dimension to obtain spatiotemporal fusion features, and encodes these spatiotemporal fusion features as contextual features, including: The graph convolutional network is used to extract spatial features from the historical flow field spatiotemporal sequence data at each time step; The spatial features of each time step are concatenated along the time dimension using the aforementioned temporal convolutional network to obtain spatiotemporal fusion features; The spatiotemporal fusion features are encoded into contextual features using the linear transformation layer.
[0009] In some implementations, constructing the initial inference state based on the current noisy flow field data, time step embedding, and the context features includes: The current noisy flow field data, time step embedding, and the aforementioned context features are concatenated to construct the initial inference state.
[0010] In some implementations, the step of using the thought chain reasoning network to perform multi-step thought chain reasoning on the initial reasoning state to obtain the final reasoning state includes: The initial inference state and the context features are input into the attention mechanism to obtain the relevant features extracted by the attention mechanism; The relevant features extracted by the attention mechanism and the current inference state are input into the gated loop unit to obtain the intermediate inference state; The intermediate reasoning state and the context features are processed through an attention mechanism and a gated loop unit for thought chain reasoning until multiple thought chain reasoning steps are completed, resulting in the final reasoning state.
[0011] In some implementations, updating the noisy flow field data of the pure noise distribution based on the predicted noise includes: ; in, Indicates the first The flow field data after denoising. Indicates the first Step-by-step noisy flow field data, Indicates the first The diffusion coefficient of the step, Indicates the first Predictive noise of the step, Indicates the first The noise scale parameter of the step. Indicates the first Random noise in the step.
[0012] Secondly, embodiments of this application also provide a spatiotemporal sequence prediction system based on thought chain enhancement, the system comprising: The data acquisition unit is used to acquire historical spatiotemporal sequence data of the flow field, including fluid velocity field, pressure field, and temperature field, as well as the original target flow field data. The model training unit is used to train a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain reasoning network, and a noise prediction network. The noise addition unit is used to gradually add Gaussian noise to the original target flow field data to generate noisy flow field data with pure noise distribution; The feature extraction unit is used to extract spatial features from the historical flow field spatiotemporal sequence data of each time step using the spatiotemporal feature extraction and encoding module, concatenate the spatial features of each time step along the time dimension to obtain spatiotemporal fusion features, and encode the spatiotemporal fusion features as context features. The inference state construction unit is used to construct an initial inference state based on the current noisy flow field data, time step embedding, and the context features. The thought chain reasoning unit is used to perform multi-step thought chain reasoning on the initial reasoning state using the thought chain reasoning network to obtain the final reasoning state. The spatiotemporal sequence prediction unit is used to determine the prediction noise through the noise prediction network based on the final inference state, and to denoise and update the noisy flow field data of the pure noise distribution according to the prediction noise until complete denoising is achieved, so as to obtain the target spatiotemporal sequence prediction result.
[0013] Thirdly, embodiments of this application also provide an electronic device, including at least one control processor and a memory for communicatively connecting to the at least one control processor; the memory stores instructions executable by the at least one control processor, the instructions being executed by the at least one control processor to enable the at least one control processor to perform a spatiotemporal sequence prediction method based on thought chain enhancement as described above.
[0014] Fourthly, embodiments of this application also provide a computer-readable storage medium storing computer-executable instructions for causing a computer to execute a spatiotemporal sequence prediction method based on thought chain enhancement as described above.
[0015] It is understood that the beneficial effects of the second to fourth aspects compared with the related technologies are the same as the beneficial effects of the first aspect compared with the related technologies. Please refer to the relevant description in the first aspect above, which will not be repeated here. Attached Figure Description
[0016] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a flowchart illustrating an embodiment of the spatiotemporal sequence prediction method based on enhanced thinking chain provided in this application; Figure 2 This is a schematic diagram of the structure of an embodiment of the spatiotemporal sequence prediction system based on enhanced thinking chain provided in this application; Figure 3 This is a schematic diagram of the structure of an embodiment of the electronic device provided in this application. Detailed Implementation
[0017] The embodiments of this application are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain this application, and should not be construed as limiting this application.
[0018] In the description of this application, the use of terms such as "first," "second," etc., is for the purpose of distinguishing technical features only and should not be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated or the order of the technical features indicated.
[0019] In the description of this application, it should be understood that the orientation descriptions, such as up, down, etc., are based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this application.
[0020] In the description of this application, it should be noted that, unless otherwise explicitly defined, terms such as "setup," "installation," and "connection" should be interpreted broadly, and those skilled in the art can reasonably determine the specific meaning of the above terms in this application in conjunction with the specific content of the technical solution.
[0021] Spatiotemporal series data are widely used in practical applications such as weather forecasting, traffic flow prediction, and air quality monitoring. This type of data exhibits complex temporal dependencies and spatial correlations, posing numerous challenges to accurate prediction. Traditional spatiotemporal series prediction methods often struggle to capture deep correlations in high-dimensional, complex spatiotemporal models, limiting the accuracy of predictions. Particularly in long-term spatiotemporal series prediction tasks, error accumulation severely impacts the reliability of predictions.
[0022] To address the problems existing in the prior art, this application proposes a spatiotemporal sequence prediction method and system based on enhanced thinking chains.
[0023] Reference Figure 1 This application provides a schematic flowchart of a spatiotemporal sequence prediction method based on enhanced thought chains. This method is applied to an electronic device, such as a server or a mobile terminal. Figure 1 As shown, the spatiotemporal sequence prediction method based on enhanced thought chain can include the following steps: Step S101: Obtain historical spatiotemporal sequence data of the flow field, including fluid velocity field, pressure field, and temperature field, and original target flow field data; Step S102: Train to obtain a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain reasoning network, and a noise prediction network; Step S103: Gaussian noise is gradually added to the original target flow field data to generate noisy flow field data with pure noise distribution; Step S104: Using the spatiotemporal feature extraction and encoding module, extract the spatial features from the historical flow field spatiotemporal sequence data of each time step, concatenate the spatial features of each time step along the time dimension to obtain spatiotemporal fusion features, and encode the spatiotemporal fusion features as context features; Step S105: Construct the initial inference state based on the current noisy flow field data, time step embedding, and contextual features; Step S106: Use the thought chain reasoning network to perform multi-step thought chain reasoning on the initial reasoning state to obtain the final reasoning state; Step S107: Based on the final inference state, the predicted noise is determined through the noise prediction network, and the noisy flow field data with pure noise distribution is denoised and updated according to the predicted noise until complete denoising is achieved, and the target spatiotemporal sequence prediction result is obtained.
[0024] In this embodiment, historical flow field spatiotemporal sequence data containing fluid velocity, pressure, and temperature fields, and original target flow field data are acquired. A diffusion model containing a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network is trained. Gaussian noise is progressively added to the original target flow field data to generate noisy flow field data with a pure noise distribution. The spatiotemporal feature extraction and encoding module extracts spatial features from the historical flow field spatiotemporal sequence data at each time step, and concatenates the spatial features of each time step along the time dimension to obtain spatiotemporal fusion features, which are then encoded as context features. An initial inference state is constructed based on the current noisy flow field data, time step embedding, and context features. The thought chain inference network performs multi-step thought chain inference on the initial inference state to obtain the final inference state. Based on the final inference state, the noise prediction network determines the prediction noise, and the noisy flow field data with a pure noise distribution is denoised and updated according to the prediction noise until complete denoising is achieved, resulting in the target spatiotemporal sequence prediction result. Thus, the spatiotemporal feature extraction and encoding module effectively captures the complex patterns of spatiotemporal sequence data by processing spatial and temporal dependencies in a hierarchical manner, providing rich feature representations for accurate prediction of spatiotemporal sequences. The use of a thought chain reasoning network to perform multi-step thought chain reasoning on the initial reasoning state provides an interpretable path for the prediction process, enabling the capture of complex dependencies in spatiotemporal sequence data and reducing prediction errors through progressive reasoning. Finally, based on the final reasoning state, a noise prediction network is used to determine the prediction noise, and then denoising and updating are performed based on the prediction noise to obtain the prediction result of the target spatiotemporal sequence, which can improve the accuracy and reliability of spatiotemporal sequence prediction.
[0025] The aforementioned acquisition of historical flow field spatiotemporal sequence data and original target flow field data, which include fluid velocity field, pressure field, and temperature field, can be, but is not limited to, spatiotemporal distribution data of fluid velocity field, pressure field, and temperature field.
[0026] The aforementioned spatiotemporal feature extraction and encoding module may include graph convolutional networks, temporal convolutional networks, and linear transform layers.
[0027] The aforementioned time step embedding can be obtained by encoding the position information of the current denoising step. The encoding method can be an encoding network known to those skilled in the art. This embodiment does not impose specific limitations or descriptions.
[0028] The location information of the current denoising step mentioned above can be the time step of the current denoising step.
[0029] In some implementations, a diffusion model is trained that includes a spatiotemporal feature extraction encoding module, a thought chain reasoning network, and a noise prediction network, including: Construct a denoising loss function, and construct a thought chain consistency loss function; The total loss function is obtained by weighted summing of the denoising loss function and the thought chain consistency loss function. Based on the total loss function, a diffusion model is trained that includes a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network.
[0030] In this embodiment, the total loss function is obtained by weighted summation of the denoising loss function and the thought chain consistency loss function. This effectively integrates the generative capability of the diffusion model with the thought chain reasoning mechanism, and guides the denoising process through stepwise reasoning, thereby improving the accuracy and interpretability of spatiotemporal sequence prediction.
[0031] In some implementations, a thought chain consistency loss function is constructed, including: ; in, This represents the consistency loss function of the thought chain. This represents the total number of steps in the thought process chain. Indicates the first Weight of step-by-step reasoning This indicates that the current student network is in the [number]th [period]. Denoising steps and the first The intermediate reasoning states of each reasoning stage The teacher network is in the first Denoising steps and the first The target reasoning state is generated in each reasoning stage.
[0032] In this embodiment, by constructing a thought chain consistency loss function, a good data foundation is laid for more accurate guidance of the diffusion model denoising process.
[0033] In some implementations, the spatiotemporal feature extraction and encoding module includes a graph convolutional network, a temporal convolutional network, and a linear transform layer. Using this module, spatial features are extracted from the historical flow field spatiotemporal sequence data at each time step. The spatial features of each time step are concatenated along the time dimension to obtain spatiotemporal fusion features, which are then encoded as contextual features, including: A graph convolutional network is used to extract spatial features from the historical flow field spatiotemporal sequence data at each time step; A temporal convolutional network is used to concatenate the spatial features of each time step along the temporal dimension to obtain spatiotemporal fusion features. A linear transformation layer is used to encode the spatiotemporal fusion features into contextual features.
[0034] In this embodiment, the spatiotemporal feature extraction module effectively captures the complex patterns of spatiotemporal sequence data by processing spatial and temporal dependencies in a hierarchical manner, providing rich feature representations for accurate prediction.
[0035] In some implementations, an initial inference state is constructed based on the current noisy flow field data, time step embedding, and contextual features, including: The current noisy flow field data, time step embedding, and context features are concatenated to construct the initial inference state.
[0036] In this embodiment, the splicing operation of the current noisy flow field data, time step embedding, and context features can lay a good data foundation for subsequent thought chain reasoning, so as to better guide the denoising process.
[0037] In some implementations, a thought chain reasoning network is used to perform multi-step thought chain reasoning on the initial reasoning state to obtain the final reasoning state, including: The initial inference state and contextual features are input into the attention mechanism to obtain the relevant features extracted by the attention mechanism; The relevant features extracted by the attention mechanism and the current inference state are input into the gated recurrent unit to obtain the intermediate inference state; The intermediate reasoning states and contextual features are processed through attention mechanisms and gating loop units to perform thought chain reasoning until the multi-step thought chain reasoning is completed, and the final reasoning state is obtained.
[0038] In this embodiment, the thought chain reasoning module refines the denoising decision step by step through multi-step iterative reasoning, which improves the accuracy and interpretability of spatiotemporal sequence prediction and enables the diffusion model to handle more complex spatiotemporal dependencies.
[0039] In some implementations, the noisy flow field data with a pure noise distribution is updated by denoising based on the predicted noise, including: ; in, Indicates the first The flow field data after denoising. Indicates the first Step-by-step noisy flow field data, Indicates the first The diffusion coefficient of the step, Indicates the first Predictive noise of the step, Indicates the first The noise scale parameter of the step. Indicates the first random noise of the step, Positive integers are allowed.
[0040] In this embodiment, by performing denoising updates based on the predicted noise to obtain the target spatiotemporal sequence prediction result, the accuracy and reliability of spatiotemporal sequence prediction can be improved.
[0041] To facilitate understanding by those skilled in the art, a set of preferred embodiments is provided below: This embodiment proposes a spatiotemporal sequence prediction method based on a diffusion model enhanced by thought chain reasoning. As a generative model, the core idea of the diffusion model is to learn the inverse mapping relationship from noise distribution to target data distribution. During training, the model learns how to reconstruct the target data from noisy data, rather than simply mapping the noisy data back to the original data. This learning mechanism enables the diffusion model to capture the inherent distribution patterns of the data and possesses powerful generative capabilities. This embodiment innovatively embeds the thought chain reasoning mechanism into the inverse denoising process of the diffusion model, guiding noise prediction in the denoising process through multi-step reasoning, thereby achieving high-precision spatiotemporal sequence prediction.
[0042] This embodiment's method includes: encoding the input spatiotemporal sequence to extract contextual features; performing thought chain reasoning at each step of the diffusion model denoising process to generate multiple intermediate reasoning states; predicting noise based on the final reasoning state and performing denoising updates; and obtaining the final prediction result through iterative denoising. This embodiment effectively improves the accuracy and interpretability of spatiotemporal sequence prediction and has broad application prospects in fields such as traffic flow prediction and weather forecasting. The specific technical solution of this embodiment includes the following: 1. System architecture.
[0043] This embodiment predicts flow field spatiotemporal sequence data. The flow field data includes the spatiotemporal distribution data of the fluid velocity field, pressure field, and temperature field. Let the historical flow field spatiotemporal sequence data be... ,in, Indicates the length of a historical time step. This represents the data channel dimension, corresponding to different flow field physical quantities. Represents the spatial height dimension. This indicates the width dimension of the space.
[0044] Predicting the target is the future. The flow field sequence at each time step (i.e., the prediction result of the target spatiotemporal sequence). ,in This indicates the length of the prediction time step.
[0045] This system architecture provides a standardized data interface for subsequent feature extraction and prediction processes by defining clear input and output dimensions, ensuring compatible processing of data at different spatiotemporal scales.
[0046] 2. Forward diffusion process.
[0047] The forward diffusion process involves gradually adding Gaussian noise to the target flow field data. Convert to pure noise distribution. Define the total number of diffusion steps as... , It can take positive integers, in the th... step The diffusion process is as follows: ; in, For the original target flow field data, Indicates the first The noisy data after step diffusion Indicates the first The noisy data after step diffusion along with With the increase of noise, the proportion of noise gradually increases. For the first The diffusion coefficient of the step controls the degree of noise addition. Standard Gaussian noise, and They have the same dimensions.
[0048] It should be noted that, With the subsequent reverse denoising process There is a corresponding relationship: during the training phase, It is the forward diffusion first The noisy data obtained from the step, and Indicates the first step in the reverse denoising process Step (corresponding to the forward step) (Step) data. When hour, That is, data that is completely noisy.
[0049] The role of the forward diffusion process is to build a bridge from the flow field data distribution to the noise distribution, providing a training target for the reverse denoising process, and enabling the diffusion model to learn the potential structural features of the flow field data.
[0050] 3. Spatiotemporal feature extraction module (i.e., spatiotemporal feature extraction and encoding module).
[0051] The spatiotemporal feature extraction module has the following network parameters: encoder encoder A network architecture combining Graph Convolutional Network (GCN) and Temporal Convolutional Network (TCN) is employed to extract the spatiotemporal sequence of historical flow fields. Its spatiotemporal characteristics.
[0052] Graph Convolutional Networks (GCNs) consist of multiple graph convolutional layers, each performing the following operations: ; in, To add self-connected adjacency matrices, This is the corresponding degree matrix. For the first Features of the layer For the first The learnable weight matrix of the layer. For activation function, Indicates the first Features of the layer Positive integers are allowed.
[0053] To better understand the computational logic of GCN and to prevent questions about the symbol interpretation, it is necessary to explain that: (1) For the input, the first... Data at each time step Reorganized into a graph node feature matrix ; (2) Through Feature extraction is performed using layer GCN, and each layer is updated as follows: ; (3) Output the final layer Reorganized into Spatial characteristics.
[0054] Temporal Convolutional Networks (TCNs) consist of multiple stacked one-dimensional causal convolutional layers, each containing: Causal convolution: Ensuring time The output depends only on and previous input; Dilated convolution: Expanding the receptive field by setting different dilation rates; Residual connections: alleviate the gradient vanishing problem in deep networks.
[0055] The specific input calculation logic of the spatiotemporal feature extraction module is as follows: 3.1 Spatial feature extraction.
[0056] ; in, For the first Data at each time step It is a spatial adjacency matrix that encodes the connection relationships between spatial locations. For the extracted spatial features, For spatial feature dimensions.
[0057] 3.2 Temporal feature fusion.
[0058] ; in, Indicates will Spatial features of each time step are pieced together along the time dimension. As a feature of spatiotemporal fusion, The time feature dimension.
[0059] Final encoded features (i.e., contextual features): ,in This is a linear transformation layer that maps features to the target dimension. ,get ,in The spatial dimension of the context feature map.
[0060] The spatiotemporal feature extraction module effectively captures the complex patterns of spatiotemporal sequence data by processing spatial and temporal dependencies in a hierarchical manner, providing rich feature representations for accurate prediction of spatiotemporal sequences.
[0061] 4. The reverse noise reduction process of enhancing the thought chain.
[0062] The core innovation of this embodiment lies in introducing a thought chain reasoning mechanism during the reverse denoising process. A thought chain reasoning network is defined. ,in These are network parameters; the network contains... One reasoning step.
[0063] For each noise reduction step (from arrive ), perform the following operations: 4.1 Context feature acquisition.
[0064] Using the aforementioned spatiotemporal feature extraction module Obtained context features This serves as the input of historical information for reasoning within the thought process.
[0065] 4.2 Thought chain reasoning.
[0066] In the The noise reduction step and the reasoning process of the thought chain include: The thought chain mechanism, by simulating the step-by-step reasoning process of humans, decomposes complex denoising decisions into multiple simple reasoning steps. Each step builds upon the reasoning results of the previous step, forming a reasoning chain. This mechanism makes the model's decision-making process transparent and traceable because each intermediate reasoning state... These all represent the results of reasoning at a specific stage. Researchers can understand how the model gradually arrives at the final prediction by analyzing these intermediate reasoning states.
[0067] Initialize inference state : ; in, Given the current noisy flow field data, during training, the corresponding forward diffusion process... , For time step embedding, the position information of the current denoising step is encoded. This indicates a feature splicing operation.
[0068] for Perform inference update: ; in, For the first One gated loop unit, Relevant features extracted for the attention mechanism Indicates the first The intermediate reasoning states of each reasoning stage Indicates the first The intermediate reasoning state of each reasoning stage.
[0069] The thought chain reasoning module refines the noise reduction decision through multi-step iterative reasoning, improving the accuracy and interpretability of predictions and enabling the model to handle more complex spatiotemporal dependencies.
[0070] 4.3 Noise prediction and denoising.
[0071] Based on the final inference state The predicted noise is: .in This is a noise prediction network with the following parameters: .
[0072] Perform a noise reduction update: ; in, For the first The noise scale parameter of the step controls the randomness of the denoising process. This is random noise (used during training, can be set to random noise during inference). ), For the first The diffusion coefficient of the step, The control focuses on how to recover data based on the predicted noise, that is, using the diffusion coefficient of the corresponding step in the forward diffusion process to ensure the mathematical consistency between the denoising process and the noise addition process.
[0073] The noise prediction and denoising module is the core execution unit of the diffusion model. It gradually restores the true distribution of the target data by accurately predicting and removing noise.
[0074] 5. Training strategies.
[0075] 5.1 Loss Function.
[0076] The training loss (i.e., the total loss function) consists of two parts: ; Denoising loss function: ; in, This is real noise. To predict noise, the expectation is... Calculate for all training samples and time steps.
[0077] Mind chain consistency loss function: ; in, The balancing coefficient controls the relative importance of the two losses. For the first The weights of step-by-step reasoning are typically set in an increasing sequence to emphasize the importance of later reasoning steps. For the current student network in the first Denoising steps and the first The intermediate reasoning states of each reasoning stage The corresponding reasoning target (i.e., the target reasoning state) generated for the teacher network, where Positive integers are allowed.
[0078] A teacher network is a pre-trained, larger-scale thought chain reasoning network that guides the student network (i.e., the currently trained network) to learn better reasoning paths through knowledge distillation. Teacher networks typically have more parameters and a deeper structure, enabling them to generate more accurate intermediate reasoning states as learning objectives.
[0079] 5.2 Training process.
[0080] Random sampling time step , Indicates a uniform distribution; For target flow field data Perform forward diffusion to obtain ; Predicting noise by enhancing the noise reduction process through thought chain. ; Calculate total loss And update network parameters through backpropagation. .
[0081] The training strategy optimizes denoising capability and inference quality together, enabling the model to have both accurate generation capability and interpretable decision-making process.
[0082] 6. Reasoning and prediction.
[0083] In the inference phase, given historical flow field spatiotemporal sequence data... : initialization Generate random noise with the same dimension as the target; right from arrive Enhance and denoise the execution mind chain; Obtain the final prediction result As a prediction of future sequences.
[0084] The inference and prediction process uses iterative denoising to gradually recover prediction results that conform to the data distribution from pure noise, thus achieving high-quality spatiotemporal sequence generation.
[0085] The complete execution steps of the method in this embodiment are as follows: (1) Input historical flow field spatiotemporal sequence data Through the spatiotemporal feature extraction module Encode to obtain contextual features .
[0086] (2) Initialize noise data Its dimensions are This serves as the starting point for the reverse denoising process.
[0087] (3) For each denoising step from At step 1, perform the noise reduction operation to enhance the thought chain: Current noisy flow field data Contextual features and time step embedding By splicing the data together, we obtain the initial reasoning state. .
[0088] Calculate sequentially using the M-step thought chain reasoning. ,in .
[0089] Based on the final inference state Using a noise prediction network Predict current step noise .
[0090] (4) Based on the predicted noise Perform denoising update, calculate We obtained the denoised flow field data.
[0091] (5) Repeat steps (3) and (4) until Reaching 1, at this point This is the final prediction result, representing the future. Prediction of the spatiotemporal sequence of the flow field at each time step (i.e., the prediction result of the target spatiotemporal sequence).
[0092] Compared with existing technologies, the method in this embodiment introduces a thought chain reasoning mechanism in the diffusion model denoising process, achieving the following technical effects: (1) Improve prediction accuracy: The multi-step reasoning process of the thinking chain can capture the complex dependencies in the spatiotemporal sequence data and reduce the spatiotemporal sequence prediction error through progressive reasoning.
[0093] (2) Enhanced interpretability: The intermediate reasoning state of the thought chain provides an interpretable path for the spatiotemporal sequence prediction process, making the model decision-making process more transparent and easier to understand and debug.
[0094] (3) Improve long-term prediction performance: By continuously performing inference correction during the denoising process, the problem of error accumulation in long-term prediction is effectively alleviated.
[0095] (4) Improve generalization ability: The thinking chain mechanism enables the model to adaptively adjust the reasoning strategy according to different spatiotemporal patterns, which enhances its adaptability to new scenarios.
[0096] (5) Optimization of computational efficiency: Compared with independent multi-model integration schemes, this method completes inference and generation within a single framework, reducing computational complexity.
[0097] Reference Figure 2 This application also provides a spatiotemporal sequence prediction system based on enhanced thought chain, which includes a data acquisition unit 201, a model training unit 202, a noise addition unit 203, a feature extraction unit 204, an inference state construction unit 205, a thought chain inference unit 206, and a spatiotemporal sequence prediction unit 207, wherein: The data acquisition unit 201 is used to acquire historical flow field spatiotemporal sequence data and original target flow field data, which include fluid velocity field, pressure field and temperature field. The model training unit 202 is used to train a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain reasoning network, and a noise prediction network. The noise addition unit 203 is used to gradually add Gaussian noise to the original target flow field data to generate noisy flow field data with pure noise distribution; The feature extraction unit 204 is used to extract the spatial features in the historical flow field spatiotemporal sequence data of each time step using the spatiotemporal feature extraction and encoding module, splice the spatial features of each time step along the time dimension to obtain the spatiotemporal fusion features, and encode the spatiotemporal fusion features as context features; The inference state construction unit 205 is used to construct the initial inference state based on the current noisy flow field data, time step embedding, and context features; The thought chain reasoning unit 206 is used to perform multi-step thought chain reasoning on the initial reasoning state using the thought chain reasoning network to obtain the final reasoning state. The spatiotemporal sequence prediction unit 207 is used to determine the prediction noise through a noise prediction network based on the final inference state, and to denoise and update the noisy flow field data with pure noise distribution according to the prediction noise until the target spatiotemporal sequence prediction result is obtained after complete denoising.
[0098] It should be noted that since the spatiotemporal sequence prediction system based on thought chain enhancement in this embodiment is based on the same inventive concept as the spatiotemporal sequence prediction method based on thought chain enhancement described above, the corresponding content in the method embodiment is also applicable to this system embodiment, and will not be described in detail here.
[0099] Reference Figure 3 This application also provides an electronic device, which includes: At least one memory; At least one processor; At least one program; The program is stored in memory, and the processor executes at least one program to implement the spatiotemporal sequence prediction method based on thought chain enhancement described above in this disclosure.
[0100] This electronic device can be any smart terminal, including mobile phones, tablets, personal digital assistants (PDAs), and in-vehicle computers.
[0101] The electronic devices according to embodiments of this application will now be described in detail.
[0102] The processor 1600 can be implemented using a general-purpose central processing unit (CPU), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this disclosure. The memory 1700 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 1700 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1700 and is called and executed by the processor 1600 to execute the spatiotemporal sequence prediction method based on thought chain enhancement of the embodiments of this disclosure.
[0103] The input / output interface 1800 is used to implement information input and output. The communication interface 1900 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.). Bus 2000 transmits information between various components of the device (e.g., processor 1600, memory 1700, input / output interface 1800, and communication interface 1900); The processor 1600, memory 1700, input / output interface 1800 and communication interface 1900 are connected to each other within the device via bus 2000.
[0104] This disclosure also provides a storage medium, which is a computer-readable storage medium storing computer-executable instructions for causing a computer to execute the above-described spatiotemporal sequence prediction method based on thought chain enhancement.
[0105] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0106] The embodiments described in this disclosure are for the purpose of more clearly illustrating the technical solutions of this disclosure and do not constitute a limitation on the technical solutions provided by this disclosure. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by this disclosure are also applicable to similar technical problems.
[0107] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this disclosure, and may include more or fewer steps than shown, or combine certain steps, or different steps.
[0108] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0109] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0110] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0111] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.
[0112] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0113] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0114] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0115] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause an electronic device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks. The embodiments of this application have been described in detail above with reference to the accompanying drawings, but this application is not limited to the above embodiments. Various changes can be made within the scope of knowledge possessed by those skilled in the art without departing from the spirit of this application.
[0116] The embodiments of this application have been described in detail above with reference to the accompanying drawings. However, this application is not limited to the above embodiments. Within the scope of knowledge possessed by those skilled in the art, various changes can be made without departing from the spirit of this application.
Claims
1. A spatiotemporal sequence prediction method based on enhanced thought chains, characterized in that, The method includes: Acquire historical spatiotemporal sequence data of the flow field, including fluid velocity field, pressure field, and temperature field, as well as the original target flow field data; The trained diffusion model includes a spatiotemporal feature extraction encoding module, a thought chain reasoning network, and a noise prediction network, and comprises: Construct a denoising loss function, and construct a thought chain consistency loss function; The total loss function is obtained by weighted summing of the denoising loss function and the thought chain consistency loss function. Based on the total loss function, a diffusion model including a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network is trained. Gaussian noise is gradually added to the original target flow field data to generate noisy flow field data with pure noise distribution; The spatiotemporal feature extraction and encoding module is used to extract spatial features from the historical flow field spatiotemporal sequence data of each time step, and the spatial features of each time step are spliced along the time dimension to obtain spatiotemporal fusion features, and the spatiotemporal fusion features are encoded as context features. Based on the current noisy flow field data, time step embedding, and the aforementioned context features, an initial inference state is constructed; The thought chain reasoning network is used to perform multi-step thought chain reasoning on the initial reasoning state to obtain the final reasoning state, including: The initial inference state and the context features are input into the attention mechanism to obtain the relevant features extracted by the attention mechanism; The relevant features extracted by the attention mechanism and the current inference state are input into the gated loop unit to obtain the intermediate inference state; The intermediate reasoning state and the context features are subjected to thought chain reasoning through an attention mechanism and a gated loop unit until multiple steps of thought chain reasoning are completed to obtain the final reasoning state. Based on the final inference state, the predicted noise is determined by the noise prediction network, and the noisy flow field data of the pure noise distribution is updated by denoising according to the predicted noise until complete denoising is achieved, and the target spatiotemporal sequence prediction result is obtained.
2. The spatiotemporal sequence prediction method based on enhanced thought chain as described in claim 1, characterized in that, The spatiotemporal feature extraction and encoding module includes a graph convolutional network, a temporal convolutional network, and a linear transform layer. Using this module, spatial features are extracted from the historical flow field spatiotemporal sequence data at each time step. The spatial features of each time step are concatenated along the time dimension to obtain spatiotemporal fusion features, which are then encoded as contextual features, including: The graph convolutional network is used to extract spatial features from the historical flow field spatiotemporal sequence data at each time step; The spatial features of each time step are concatenated along the time dimension using the aforementioned temporal convolutional network to obtain spatiotemporal fusion features; The spatiotemporal fusion features are encoded into contextual features using the linear transformation layer.
3. The spatiotemporal sequence prediction method based on enhanced thought chain as described in claim 1, characterized in that, The initial inference state is constructed based on the current noisy flow field data, time step embedding, and the context features, including: The current noisy flow field data, time step embedding, and the aforementioned context features are concatenated to construct the initial inference state.
4. The spatiotemporal sequence prediction method based on thought chain enhancement according to claim 1, characterized in that, The constructed thought chain consistency loss function includes: ; in, This represents the consistency loss function of the thought chain. This represents the total number of steps in the thought process chain. Indicates the first Weight of step-by-step reasoning This indicates that the current student network is in the [number]th [period]. Denoising steps and the first The intermediate reasoning states of each reasoning stage The teacher network is in the first Denoising steps and the first The target reasoning state is generated in each reasoning stage.
5. The spatiotemporal sequence prediction method based on enhanced thought chain as described in claim 1, characterized in that, The step of denoising and updating the noisy flow field data of the pure noise distribution based on the predicted noise includes: ; in, Indicates the first The flow field data after denoising. Indicates the first Step-by-step noisy flow field data, Indicates the first The diffusion coefficient of the step, Indicates the first Predictive noise of the step, Indicates the first The noise scale parameter of the step. Indicates the first Random noise in the step.
6. A spatiotemporal sequence prediction system based on enhanced thought chain, characterized in that, The system includes: The data acquisition unit is used to acquire historical spatiotemporal sequence data of the flow field, including fluid velocity field, pressure field, and temperature field, as well as the original target flow field data. The model training unit is used to train a diffusion model that includes a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network, including: Construct a denoising loss function, and construct a thought chain consistency loss function; The total loss function is obtained by weighted summing of the denoising loss function and the thought chain consistency loss function. Based on the total loss function, a diffusion model including a spatiotemporal feature extraction and encoding module, a thought chain inference network, and a noise prediction network is trained. The noise addition unit is used to gradually add Gaussian noise to the original target flow field data to generate noisy flow field data with pure noise distribution; The feature extraction unit is used to extract spatial features from the historical flow field spatiotemporal sequence data of each time step using the spatiotemporal feature extraction and encoding module, concatenate the spatial features of each time step along the time dimension to obtain spatiotemporal fusion features, and encode the spatiotemporal fusion features as context features. The inference state construction unit is used to construct an initial inference state based on the current noisy flow field data, time step embedding, and the context features. The thought chain reasoning unit is used to perform multi-step thought chain reasoning on the initial reasoning state using the thought chain reasoning network to obtain the final reasoning state, including: The initial inference state and the context features are input into the attention mechanism to obtain the relevant features extracted by the attention mechanism; The relevant features extracted by the attention mechanism and the current inference state are input into the gated loop unit to obtain the intermediate inference state; The intermediate reasoning state and the context features are subjected to thought chain reasoning through an attention mechanism and a gated loop unit until multiple steps of thought chain reasoning are completed to obtain the final reasoning state. The spatiotemporal sequence prediction unit is used to determine the prediction noise through the noise prediction network based on the final inference state, and to denoise and update the noisy flow field data of the pure noise distribution according to the prediction noise until complete denoising is achieved, so as to obtain the target spatiotemporal sequence prediction result.
7. An electronic device, characterized in that, It includes at least one control processor and a memory for communicatively connecting to the at least one control processor; the memory stores instructions executable by the at least one control processor, which, when executed by the at least one control processor, enable the at least one control processor to perform the spatiotemporal sequence prediction method based on thought chain enhancement as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions for causing a computer to perform the spatiotemporal sequence prediction method based on thought chain enhancement as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Action generation method, agent system, device, storage medium and program product
CN122389951A
A spatio-temporal sequence prediction method and system based on channel information fusion
CN122673497A