High-speed precision machine tool small sample thermal error prediction method and compensation system based on spatial-temporal feature interactive fusion network

Through the STFIFN model, the spatial and temporal characteristics are effectively captured and fused in precision machine tools, and the problem of low prediction accuracy of small samples is solved, and efficient thermal error control is achieved.

CN118917177APending Publication Date: 2024-11-08CHONGQING UNIV
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410935298.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

Existing deep learning models cannot effectively capture spatiotemporal features in small sample thermal error prediction, resulting in low prediction accuracy and robustness, especially in precision machine tools, the spatiotemporal feature interaction and fusion of thermal information data is difficult to achieve.

Method used

A spatial-temporal feature interactive fusion network (STFIFN) model is proposed. Through the connected STFI block and the spatial-temporal feature fusion layer, combined with the GTC, TMHSA, GCN and SMHSA mechanisms, the importance of time and space characteristics is dynamically adjusted to achieve the comprehensiveness of space-time features. Capture and interact.

Benefits of technology

The accuracy and robustness of thermal error prediction of small samples are improved, efficient spatiotemporal feature extraction and fusion under small samples data are achieved, and the thermal error control accuracy and stability of precision machine tools are significantly improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118917177A_ABST
    Figure CN118917177A_ABST
Patent Text Reader

Abstract

The invention discloses a high-speed precision machine tool small sample thermal error prediction method based on a spatio-temporal feature interactive fusion network, and a spatio-temporal feature interactive fusion network model is constructed and comprises a spatio-temporal feature interactive block, a spatio-temporal feature gating fusion layer and a residual structure. Gated time convolution is combined with multi-head auto-attention to capture time information and integrate time features, capturing short-term and long-term relationships. Spatial information is integrated through spatial feature fusion by using a graph convolutional network and multi-head self-attention. The method facilitates simultaneous utilization of spatio-temporal characteristics. Then, the thermal information data is processed through a spatio-temporal feature gating fusion layer, and information is mixed by using a gating mechanism; the result shows that the spatial-temporal feature interactive fusion network is obviously superior to other models in the aspects of small sample thermal information prediction and thermal error compensation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of mechanical error analysis, and specifically provides a small sample thermal error prediction method and compensation system for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network. Background Art

[0002] As key equipment in the manufacturing industry, precision machine tools are the cornerstone for achieving high-precision machining of complex parts. Its applications span various fields, including aerospace, medical equipment, etc. In the process of precision machining, inevitable friction and electrical heating will cause thermal deformation of machine tool components, resulting in a decrease in machining accuracy. Research results show that thermal error (TE) accounts for a large part of the overall machining error of precision machine tools, ranging from 40% to 70%. It can be seen that TE is the basic determining factor affecting the machining accuracy of precision machine tools. In general, precision machine tools are affected by internal and external heat sources, which together lead to an uneven temperature field. This phenomenon is the main factor causing TE in machine tools. In order to significantly improve machining accuracy, effective control of TE must be achieved.

[0003] At present, the methods for effectively controlling TE of machine tools mainly include two aspects: TE prevention and compensation methods. The former aims to reduce or prevent the generation of TE by optimizing the machine tool structure and selecting suitable machine tool materials, while the latter focuses on mitigating TE during the machining process. TE compensation is well known for its efficiency and cost-effectiveness and has a wide range of applications in improving machining accuracy. TE exhibits time-varying, nonlinear and non-stationary behaviors. The core of TE compensation lies in building a robust and high-precision model to predict TE in advance. At present, there are two main types of modeling methods, namely numerical simulation-based methods and data-driven methods. The models established using these two methods are called numerical simulation models and data-driven models, respectively. Building a numerical simulation model is labor-intensive and time-consuming. In addition, the numerical simulation model created for a specific machine tool is not applicable to other machine tools and exhibits poor generalization ability. Therefore, data-driven models have attracted considerable attention. Traditional experimental data models include robust ridge regression models, multivariate linear regression (MLR) models, least squares support vector machine (LSSVM) models, and random forest algorithm models. Correlation-based selection or decision tree-based selection methods are used to reduce collinearity between temperature-sensitive variables. However, they still fail to capture the spatiotemporal characteristics of TE and the complex nonlinear relationships in small sample thermal information data, resulting in low prediction accuracy and weak robustness.

[0004] TE is a kind of time series data. Some neural networks can learn and memorize complex relationships between input data by adjusting weights and biases, which gives them strong memory capabilities. This enables these neural networks to capture the relationship between a wide range of thermal information data. Therefore, in order to improve the prediction accuracy and robustness, neural networks with strong memory capabilities have become a key approach to TE compensation. In addition, in order to characterize thermal behavior, temperature and displacement sensors are positioned at various points on the machine tool to collect thermal information data. The thermal information data collected by the above sensors and the spatial positioning information of these sensors are of great significance for the accurate prediction of TE because TE exhibits strong spatiotemporal behavior. However, in previous studies, scholars have mainly focused on the temporal characteristics of TE and ignored the spatial location information of temperature and displacement sensors. Therefore, in order to improve the accuracy and robustness of the prediction, the temporal and spatial characteristics of TE should be mined.

[0005] For thermal information data, spatial and temporal features do not exist independently. In order to further improve the accuracy and robustness of the prediction, the spatiotemporal characteristics of TE must be fully captured and the interaction between the spatiotemporal characteristics must be considered. In addition, the thermal equilibrium time of the machine tool is very long. The collection of large-sample thermal information data is extremely difficult because the measurement process may interfere with the actual machining process and is very time-consuming and labor-intensive. Therefore, thermal information data is a kind of small-sample data. There is no exact standard value for the boundary between small-sample data sets and large-sample data sets, which is affected by the research field. For TE prediction, there is no exact standard value for the boundary between small-sample and large-sample data sets, but the prior art defines thermal information data sets with less than 5,000 samples as small-sample data sets, and thermal information sets with more than 100,000 samples as large-sample data sets.

[0006] So far, few studies have focused on building prediction models that can simultaneously capture the spatiotemporal features of small-sample thermal information data. Although spatiotemporal prediction models have some applications in other research fields, such as spatiotemporal graph convolutional networks (STGCNs), attention-based spatiotemporal graph convolutional networks (ASTGCNs), graph multi-attention networks (GMANs), and spatiotemporal synchronized graph convolutional networks, these models are not easily applied to small-sample TE prediction because these spatiotemporal prediction models are effective with large sample data as input. More specifically, STGCN adopts a spatiotemporal convolutional module that combines GCN with gated temporal convolution (GTC) to capture temporal and spatial features. However, due to its temporal structure, STGCN cannot fully realize the fusion and interaction between temporal and spatial features. GMAN adopts a parallel architecture that simultaneously feeds the input data into the spatiotemporal network for feature extraction and then fuses the spatiotemporal network information. Nevertheless, since the spatiotemporal features of TE data are closely intertwined and influence each other, it becomes crucial to realize the interaction between spatiotemporal features during feature extraction. In addition, the above models cannot effectively capture the long-term relationships and global features of thermal information data. The increase in temperature is the direct cause of the existence of TE. Therefore, TE is closely related to temperature data and also to the relative positions of different temperature sensors.

[0007] It can be seen that spatiotemporal features are crucial for small sample TE prediction. The sequential connection of the spatiotemporal network model cannot realize the interaction and fusion of spatiotemporal features of small sample thermal information data. Other existing spatiotemporal models cannot fully extract the spatiotemporal features of small sample thermal information data, resulting in weak robustness and low prediction accuracy of existing deep learning models. In order to improve the robustness and prediction accuracy of the model, the interaction of spatiotemporal features should be fully considered, and the small sample thermal information data should be used as input for fusion. In addition, the interaction and fusion strategy of spatiotemporal information is crucial, and how to enhance spatiotemporal information during network transmission is the key. Summary of the invention

[0008] In view of this, the purpose of the present invention is to provide a small sample thermal error prediction method and compensation system for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, which can completely extract the spatiotemporal characteristics of small sample thermal information data while maintaining the integrity of data feature transmission, thereby improving the accuracy and robustness of thermal error prediction.

[0009] In order to achieve the above object, the present invention provides the following technical solutions:

[0010] The present invention first proposes a small sample thermal error prediction method for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, comprising the following steps:

[0011] Step 1: Use multiple temperature sensors to collect thermal information data X of high-speed precision machine tools; divide the thermal information data X into training set Dtrain ←(X train ,Y train ) and the test set D test ←(X test ,Y test );

[0012] Step 2: Construct a spatiotemporal feature interactive fusion network model, which includes a 1×1 CNN layer, L STFI blocks arranged in series, and a spatiotemporal feature fusion layer; the STFI block includes a time feature fusion layer and a space feature fusion layer arranged in parallel, and the time feature fusion layer and the space feature fusion layer are both connected to the spatiotemporal feature interactive layer; the time feature fusion layer uses the GTC and TMHSA mechanisms to extract the time features in the thermal information data and perform feature fusion, and the space feature fusion layer uses the GCN and SMHSA mechanisms to extract the space features in the thermal information data and perform feature fusion; the spatiotemporal feature interactive layer interacts the time features and the space features to dynamically adjust the importance of the time features and the space features, and obtains the time feature output and the space feature output after the interaction;

[0013] In two adjacent STFI blocks, the temporal feature output of the previous STFI block is used as the input of the spatial feature fusion layer of the next STFI block, and the spatial feature output of the previous STFI block is used as the input of the temporal feature fusion layer of the next STFI block;

[0014] Step 3: Initialize the parameters of the spatiotemporal feature interaction fusion network model and calculate the spatial position adjacency matrix A sp , time similarity adjacency matrix A se and the mixed adjacency matrix A h ; i = 1;

[0015] Step 4: Use 1×1 CNN layer to extract temporal features X t and spatial feature X s ; l = 1

[0016] Step 5: Use GTC and TMHSA mechanisms to extract features and obtain the outputs of GTC and TMHSA mechanisms respectively and

[0017] GCN and SMHSA mechanisms are used to extract features respectively, and the outputs of GCN and SMHSA mechanisms are obtained respectively. and

[0018] Step 6: and Input the time feature fusion layer to obtain the fused time feature Will and Input the spatial feature fusion layer to obtain the fused spatial features

[0019] Step 7: Time features and spatial characteristics Input to the spatiotemporal feature interaction layer to get the temporal feature output And spatial feature output

[0020] Step 8: Determine whether the number of layers l of the current STFI block is equal to the maximum number of layers L of the STFI block: If so, execute step 9; if not, use the temporal feature output of the previous STFI block as the input of the spatial feature fusion layer of the next STFI block, and use the spatial feature output of the previous STFI block as the input of the temporal feature fusion layer of the next STFI block; let l=l+1, and execute step 5;

[0021] Step 9: Input the temporal feature output and spatial feature output of the K-th layer STFI block to the spatiotemporal feature fusion layer to obtain the spatiotemporal feature after feature fusion

[0022] Step 10: Calculate the fused spatiotemporal features Compared with the real spatiotemporal features Y in the training set train The loss function between

[0023] Step 11: Update the spatiotemporal feature interaction fusion network model according to the loss function;

[0024] Step 12: Determine whether the current number of iterations i is equal to the preset maximum number of iterations I: If yes, execute step 13; if not, set i=i+1 and execute step 4;

[0025] Step 13: Use the test set to test the prediction performance of the trained spatiotemporal feature interactive fusion network model;

[0026] Step 14: Use the spatial-temporal feature interactive fusion network model to predict thermal errors.

[0027] Further, in step three:

[0028] The spatial position adjacency matrix A sp for:

[0029]

[0030] Among them, d ij is the spatial distance between node i and node j; σ is the standard deviation; κ is the threshold used to filter the connection between nodes; the temporal similarity adjacency matrix A se for:

[0031]

[0032] Among them, X i and X j denote the time series data of node i and node j respectively; DTW(·) denotes the dynamic time warping algorithm;

[0033] Mixed adjacency matrix A h for:

[0034]

[0035] Furthermore, in step 5, the time feature extracted by GTC is:

[0036] h t =GTC(X t )=Tanh(Φ 1 *X t +a)⊙σ(Φ 2 *X t +b)

[0037] Among them, Φ 1 and Φ 2 is an independent dilated causal convolution; a and b are bias terms; Tanh and σ are activation functions; ⊙ is the Hadamard product; the temporal features extracted using the TMHSA mechanism are:

[0038] H t =TMHSA(X t )=Concat(head 1 ,head 2 ,…head n )W t

[0039]

[0040] Where n is the number of attention heads; W t is a learnable parameter; Softmax is an activation function; and:

[0041]

[0042]

[0043] in, and is a learnable parameter;

[0044] In step 6, the fused time features for:

[0045]

[0046]

[0047] in: and is a learnable parameter; b z is the bias term; z t It's a door.

[0048] Furthermore, the spatial features extracted by GCN are:

[0049] h s =f(X s ,A sp ,A se ,A h )=σ(A h Relu(σ(A se X s W se )⊙Tanh(A sp X s W sp ρW h )W se ,W sp and W h A se ,A sp and A h The weight matrix of the three adjacent matrices;

[0050] The spatial features extracted using the SMHSA mechanism are:

[0051] H s =SMHSA(X t )=Concat(head 1 ,head 2 ,…head n )W s

[0052]

[0053] Where: n is the number of attention heads; W s is a learnable parameter; Softmax is an activation function; and:

[0054]

[0055]

[0056] in: and is a learnable parameter;

[0057] In step 6, the fused spatial features for:

[0058]

[0059]

[0060] in: and is a learnable parameter; b z is the bias term; z s It's a door.

[0061] Further, in step 7, the time feature output And spatial feature output They are:

[0062]

[0063]

[0064]

[0065]

[0066]

[0067]

[0068] in: and Represents the output of the STFI block at layer l; and is a learnable parameter; and is the bias term; f t and They respectively represent the intermediate variables and time feature extraction results after being processed by the Sigmoid activation function; represents the first intermediate variable after being processed by the Tanh activation function; f s and Represents the intermediate variables and spatial feature extraction results after being processed by the Sigmoid activation function; represents the second intermediate variable after being processed by the Tanh activation function; σ and Tanh are activation functions respectively.

[0069] Furthermore, in step nine, the spatiotemporal features after feature fusion for:

[0070]

[0071]

[0072] Among them: H is the output of the spatiotemporal feature gating fusion layer, that is, the spatiotemporal feature after feature fusion W z,1 and W z,2 is a learnable parameter; b z is the bias term; z is the gate structure.

[0073] The present invention also proposes a small sample thermal error compensation system for high-speed precision machine tools based on a time-space feature interactive fusion network, which is characterized by: comprising a data acquisition system, a thermal error prediction module and a control module;

[0074] The data acquisition system includes a temperature sensor installed on a high-speed precision machine tool and a signal processing module that processes data collected by the temperature sensor;

[0075] The thermal error prediction module adopts a spatiotemporal feature interactive fusion network model, and uses a high-speed precision machine tool small sample thermal error prediction method based on a spatiotemporal feature interactive fusion network as described in any one of claims 1 to 6 to predict the thermal error;

[0076] The control system uses an NC program to convert the predicted thermal error into an error compensation component, and controls each motion axis of the machine tool to move according to the movement amount after subtracting the corresponding error compensation component through a CNC controller.

[0077] The beneficial effects of the present invention are:

[0078] The invention provides a small sample thermal error prediction method for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, which has the following technical effects:

[0079] (1) The STFI block is the core of the present invention. It combines TMHSA with GTC in the temporal dimension and SMHSA with GCN in the spatial dimension. This combination captures the long-term and short-term temporal relationships as well as the global and local spatial relationships. After collecting temporal features and spatial features, the spatial feature fusion layer is used to effectively fuse the long-term and short-term temporal relationships as well as the global and local spatial relationships. The STFI block realizes the interaction between spatial features and temporal features, so that temporal features and spatial features can be utilized at the same time. The spatiotemporal feature interactive fusion network model (STFIFN model) has high prediction accuracy and strong robustness under various working conditions, and the STFIFN model performs significantly in small sample thermal information data modeling and spatiotemporal feature fusion scenarios.

[0080] (2) The STFIFN model proposed in the present invention takes small sample thermal information data as input. The STFIFN model consists of multiple STFI blocks, spatiotemporal feature gated fusion layers and residual structures, which ensures the comprehensive capture of spatiotemporal feature information while maintaining the integrity of data feature transmission. The STFIFN model proposed in the present invention is applied to TE prediction and compensation under various working conditions of precision machine tools, and is tested. The results show that the proposed STFIFN model is superior to the baseline model in terms of several evaluation indicators of small sample thermal information data prediction.

[0081] (3) The hybrid adjacency matrix is ​​obtained by combining the spatial position adjacency matrix constructed by Euclidean distance and the temporal similarity adjacency matrix constructed by DTW, that is, the hybrid adjacency matrix is ​​constructed by combining spatial position information with temporal similarity information, which can more comprehensively describe the characteristics of thermal information data and provide a more comprehensive data perspective, which can enhance the spatiotemporal relationship beyond the traditional distance measurement method.

[0082] (4) The STFIFN model has made significant contributions to the field of small sample TE control. The STFIFN model has achieved excellent results in small sample TE compensation and realized reliable TE control. By skillfully capturing the interaction of spatiotemporal features, the STFIFN model is able to model and predict thermal information data with higher accuracy. This in turn improves the control accuracy and stability of TE. In the case of TE compensation, the STFIFN model exhibits the lowest maximum TE value among various models, indicating its significant advantage in reducing the most severe TE that may occur within the machine tool. The STFIFN model shows the stability and accuracy of the average TE value, ensuring that the machine tool always maintains a low TE level. BRIEF DESCRIPTION OF THE DRAWINGS

[0083] In order to make the purpose, technical solution and beneficial effects of the present invention clearer, the present invention provides the following drawings for illustration:

[0084] Figure 1 To simplify the thermal deformation of 1D high-speed precision machine tools; Figure 2 Grid division diagram; Figure 3 is the transient temperature field of MTSS;

[0085] Figure 4 MTSS thermal deformation field; (a) axial comprehensive deformation; (b) radial comprehensive deformation;

[0086] Figure 5 is the correlation between axial thermal deformation and front surface temperature; Figure 6 It is the structural diagram of the STFISN model;

[0087] Figure 7 This is the structural diagram of gated temporal convolution; Figure 8 This is the structural diagram of the multi-head self-attention mechanism;

[0088] Fig. 9 Figure 1 shows the data acquisition system and sensor distribution diagram. (a) Data acquisition system; (b) Sensor distribution.

[0089] Fig.10 The speeds under three working conditions: (a) the first working condition; (b) the second working condition; (c) the third working condition;

[0090] Fig.11 Thermal information data under three working conditions; (a) is the temperature data of the first working condition; (b) is the TE data of the first working condition; (c) is the temperature data of the second working condition; (d) is the TE data of the second working condition; (e) is the temperature data of the third working condition; (f) is the TE data of the third working condition;

[0091] Fig.12 is the spatial position adjacency matrix graph; Fig.13 is the temporal similarity adjacency matrix;

[0092] Fig.14 The impact of the main hyperparameters; (a) the number of attention heads; (b) the learning rate; (c) the batch size; (d) the number of layers of the STFI block;

[0093] Fig.15 are the loss curves of different optimizers; Fig.16 The influence of the number of measurement points; Fig.17 The influence of the measurement point location;

[0094] Fig.18 The prediction results for the second working condition; (a) Comparison between the prediction residual and the traditional model; (b) Comparison between the prediction residual and the spatiotemporal model;

[0095] Fig.19 Prediction residuals for the second operating condition; (a) Comparison between prediction residuals and traditional models; (b) Comparison between prediction residuals and spatiotemporal models;

[0096] Fig. 20 is the predicted residual PDF under the second working condition; Fig.21 The prediction interval of the STFIFN model; (a) global view; (b) local zoom;

[0097] Fig. 22 is the prediction interval of GPR;

[0098] Fig.23 The prediction results of the first working condition; (a) Comparison between the prediction residual and the traditional model; (b) Comparison between the prediction residual and the spatiotemporal model;

[0099] Fig.24 Prediction residuals for the first operating condition; (a) Comparison between prediction residuals and traditional models; (b) Comparison between prediction residuals and spatiotemporal models;

[0100] Fig.25 The prediction results of the third working condition; (a) the prediction results of the traditional model; (b) the prediction results of the spatiotemporal model;

[0101] Fig.26 Prediction residual for the third working condition; (a) prediction result of traditional model; (b) prediction result of spatiotemporal model;

[0102] Fig. 27 It is a schematic diagram of a small sample thermal error prediction method and compensation system for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network of the present invention;

[0103] Fig.28 Comparison of compensation results. DETAILED DESCRIPTION

[0104] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it, but the embodiments are not intended to limit the present invention.

[0105] 1. Thermal error mechanism

[0106] This embodiment demonstrates the spatiotemporal behavior of thermal information data through mathematical modeling and numerical simulation. The spatiotemporal behavior of thermal information data is demonstrated through the mathematical model of TE. Numerical simulation proves the dependence of current TE on historical thermal information. The results show that TE prediction is a spatiotemporal prediction problem. Therefore, it is necessary to propose a spatiotemporal prediction model to capture the spatiotemporal behavior of thermal information data and achieve high prediction accuracy and strong robustness.

[0107] 1.1 Mathematical modeling

[0108] The spindle of a high-speed precision machine tool is represented as a slender one-dimensional (1D) axis, such as Figure 1As shown. Assume that the temperature of each point in the same section of the shaft is the same, that is, the temperature is only related to time t and the axial coordinate x. Starting from the coordinate origin fixed at the midpoint of the left end surface of the shaft, the heat conduction equation formula of the 1D high-speed precision machine tool is as follows:

[0109]

[0110] Where: T is a function of the internal temperature; L is the length; α is the thermal diffusivity of the material.

[0111]

[0112] Where: k, ρ and c are thermal conductivity, density and specific heat capacity respectively.

[0113] The initial conditions for the heat conduction equation are:

[0114] T(x,0)=T 0

[0115] Where: T 0 is the ambient temperature.

[0116] The heat conduction equation is a partial differential equation, which is applicable to various solving methods. This embodiment uses Fourier transform to solve the equation.

[0117]

[0118] Among them: ξ is an intermediate variable.

[0119] The correlation between temperature and overall thermal deformation can be described as:

[0120]

[0121] Where: λ is the linear expansion coefficient.

[0122] TE at time 0 is: ΔL(0) = 0

[0123] The TE at this moment is:

[0124]

[0125] The TE at 2Δt is:

[0126]

[0127] The TE at time kΔt is:

[0128]

[0129] The results show that the thermal error ΔL(kΔt) at time kΔt is significantly correlated with the thermal errors ΔL((k-1)Δt), ΔL((k-2)Δt), ..., ΔL(2Δt), ΔL(Δt) and ΔL(0) at times (k-1)Δt, (k-2)Δt, ..., 2Δt, Δt and 0. Therefore, the theoretical proof establishes the temporal and nonlinear properties of TE. In addition, ΔL((k-1)Δt)>ΔL((k-2)Δt)> ...>ΔL(2Δt)>ΔL(Δt)>ΔL(0). Due to the cumulative effect of axial thermal deformation, TE varies with axial position. The magnitude of TE increases with the distance from the origin. Thus, the spatiotemporal behavior of TE is demonstrated.

[0130] 1.2 Numerical simulation

[0131] To simplify the simulation and meshing process, structures such as chamfers, fillets, threaded holes, washers, springs, etc. are ignored. The 3D model of the high-speed precision machine tool system (MTSS) constitutes an extremely symmetrical rotational solid, and then only one quarter of the 3D model is used for simulation. Tetrahedral elements are used for meshing, such as Figure 2 The material properties of MTSS are shown in Table 1.

[0132] Table 1 Main material parameters

[0133]

[0134] The transient heat conduction equation is solved by numerical simulation method:

[0135]

[0136] Where: T = T (x, y, z, t) represents the temperature of the tetrahedral unit; Q represents the internal heat source; k x ,k y and k z denote the thermal conductivity in the x-, y-, and z-directions, respectively.

[0137] TE is calculated according to Hooke's law: ΔL = λΔT, where ΔT represents the temperature rise.

[0138] The main sources of heat generation include heat dissipation from the internal motor and heat generated by bearing friction. The calculation includes the heat generated by the internal motor and bearings. Heat dissipation in the MTSS occurs mainly through convection and conduction mechanisms. Therefore, convection between the MTSS and the surrounding fluid and thermal contact conductance at the bearing interface must be considered as critical boundary conditions for heat dissipation, and the thermal boundary conditions and heat loads of the MTSS are established.

[0139] like Figure 3The figure shows the transient temperature field distribution of the MTSS, which is characterized by its inhomogeneity. The main source of heat comes from the friction generated by the bearing. It is worth noting that the highest temperature recorded by the inner ring of the front bearing reached 31.062°C. The inner ring is in direct contact with the journal, and the thermal contact conduction hinders the heat transfer from the inner ring to the shaft. In contrast, the temperature of the rear bearing is still significantly lower, about 2 to 3°C lower than that of the front bearing. In addition, a large amount of heat conduction occurs along the axial direction of the high-speed precision machine tool, which is conducive to the transfer of heat from the rear end of the axial direction to the front end.

[0140] Apply the transient temperature field distribution to the thermal characteristics analysis model as a heat load and perform thermal deformation simulation analysis, such as Figure 4 As shown in the figure, a large amount of thermal deformation is observed, and the uneven temperature field distribution is the direct cause of MTSS thermal bending. The most obvious total deformation of MTSS is concentrated at the front end of the shaft core, such as Figure 4 (a) is shown. Specifically, the maximum total deformation values ​​at the front and rear ends of the shaft core are 24.418μm and -22.144μm, respectively. Figure 4 In (b), the radial deformation of the MTSS is fully described, showing that the radial deformations of the front and rear surfaces are 7.367 μm and −8.640 μm, respectively.

[0141] Subsequently, the correlation between the axial thermal deformation and the front surface temperature was extracted, as Figure 5 As shown. The nonlinearity in this relationship is obvious. In addition, the thermal deformation of the shaft core during heating and cooling shows obvious non-overlap, which is a typical hysteresis phenomenon. This result emphasizes the existence of intrinsic hysteresis and long-term memory behavior of TE. It is worth noting that TE is not only affected by the current thermal conditions, but also by the previous thermal state. Therefore, it is extremely important to develop TE prediction models that can effectively encapsulate the long-term memory properties of TE.

[0142] 2. Spatiotemporal feature interactive fusion network model STFIFN

[0143] Multiple temperature sensors are used to collect thermal information data of the temperature field, and these temperature sensors are located in different spatial locations. The spatiotemporal behavior of TE should be characterized and the spatiotemporal characteristics of thermal information data should be mined. The layout and relationship of sensor nodes can be described using a graph G = (V, E), where V represents the number of sensor nodes and E is the edge size. Using graph G to describe sensor networks and spatial characteristics can provide rich information for spatial behavior analysis and modeling. Temporal characteristics are represented by signal sequences. Signal sequences contain sensor data that capture time-related information. Timestamps are combined with sensor measurements to form time series data. Spatial characteristics are represented by the relative spatial distance between every two sensors. Therefore, the challenge of spatiotemporal prediction of TE is formulated as the feature sequence {Xt+1 ,…,X t+n} and by {X t-T ,…X t} and the mapping relationship f between the feature sequence composed of graph G.

[0144] [X t+1 ,…,X t+n ] = f(G; (X t-T ,…,X t ))

[0145] In order to solve the limitations of the existing prediction models, this embodiment proposes a STFIFN model, such as Figure 6 As shown. The spatiotemporal feature interaction fusion network model of this embodiment includes a 1×1 CNN layer, L STFI blocks arranged in series, and a spatiotemporal feature fusion layer; the STFI block includes a time feature fusion layer and a space feature fusion layer arranged in parallel, and the time feature fusion layer and the space feature fusion layer are both connected to the spatiotemporal feature interaction layer. The time feature fusion layer uses the GTC and TMHSA mechanisms to extract the time features in the hot information data and perform feature fusion, and the space feature fusion layer uses the GCN and SMHSA mechanisms to extract the spatial features in the hot information data and perform feature fusion. The spatiotemporal feature interaction layer interacts with the time features and the space features to dynamically adjust the importance of the time features and the space features, and obtains the time feature output and the space feature output after the interaction. In two adjacent STFI blocks, the time feature output of the previous STFI block is used as the input of the space feature fusion layer of the next STFI block, and the space feature output of the previous STFI block is used as the input of the time feature fusion layer of the next STFI block.

[0146] Specifically, since the thermal information data has spatiotemporal characteristics, the thermal information data is input into the 1×1CNN layer to extract the temporal and spatial features of the thermal information data, increase the dimension of the spatial features, and better capture the complexity and diversity in the thermal information data. Subsequently, the STFI block receives the spatial features extracted by the 1×1CNN layer. Therefore, GCN and GTC are used to extract spatiotemporal features, and the output values ​​of GCN and GTC are obtained. GCN is the information fusion of temperature and TE nodes, and the adjacency matrix is ​​used to aggregate the spatial feature information in the thermal information data. GCN is used to extract temporal features from the thermal information data, and the GTC layer does not capture the spatial features of the thermal information data. Therefore, in order to make full use of the spatiotemporal features, the method of spatiotemporal information interaction is adopted. The output of GCN is connected to the input of GTC in the next STFI block, and the output of GTC is connected to the input of GCN in the previous STFI block. During the feature transmission process, GCN and GTC can simultaneously utilize spatiotemporal features to improve the prediction accuracy. The MHSA mechanism is used in the STFI block to extract the long-term temporal and global spatial relationships of TE. The time feature fusion layer and the space feature fusion layer are used to fuse the long-short time relationship, global spatial relationship and local spatial relationship of thermal information data respectively.

[0147] This embodiment uses multiple STFI blocks in the proposed STFIFN model to fully capture spatiotemporal features as the STFIFN network deepens. The extracted features are finally transferred to the spatiotemporal feature fusion layer, and the gating mechanism is used to fuse spatiotemporal features. In order to avoid the loss of important information during feature transmission, the residual structure is introduced to ensure the integrity of data transmission.

[0148] 2.1STFI Block

[0149] In this embodiment, the STFI block consists of GTC, GCN, MHSA, a temporal feature fusion layer, a spatial feature fusion layer, and a spatiotemporal feature interaction layer. The GTC and MHSA mechanisms are responsible for extracting the temporal features of TE. Within the TCN framework, the use of dilated causal convolution (DCC) aims to establish a feature extraction mechanism to facilitate the extraction of important feature insights. DCC introduces a dilation factor denoted as d into the traditional convolution operation. d increases exponentially with the depth of the network to increase the receptive field.

[0150] Specifically, the time series data X = {x 1 ,x 2 ,…,x T The calculation of DCC of} and filter f:{0,1,2,…,k-1} at time step t is expressed as follows:

[0151]

[0152] Where: k is the filter size.

[0153] according to Figure 7 ,GTC consists of TCN and gating mechanism to extract short-term temporal relationships. t ∈R N×T×C Indicated by, where C represents the number of channels. The time feature extracted by GTC is:

[0154] h t =GTC(X t )=Tanh(Φ 1 *X t +a)⊙σ(Φ 2 *X t +b)

[0155] Among them, Φ 1 and Φ 2 are independent dilated causal convolutions; a and b are bias terms; Tanh and σ are activation functions; ⊙ is the Hadamard product.

[0156] Temporal Multi-Head Attention (TMHSA) is used to extract long-term temporal relationships, such as Figure 8 As shown. Given the input time feature X t ∈R T×N×C , the dimension of the time feature is increased to obtain complex time relations. The time features are linearly transformed and then mapped into three different spaces to obtain:

[0157]

[0158]

[0159] in, and are learnable parameters.

[0160] Specifically, the temporal features extracted using the TMHSA mechanism are:

[0161] H t =TMHSA(X t )=Concat(head 1 ,head 2 ,…head n )W t

[0162]

[0163] Where n is the number of attention heads; W t is a learnable parameter; Softmax is an activation function.

[0164] In order to consider the long-term and short-term temporal relationships, we use the temporal feature fusion layer to fuse TMHSA (X t ) and GTC(X t ) output. In the STFI block at layer l, TMHSA(X t ) and GTC(X t ) are used to output and Indicates that the fused temporal features for:

[0165]

[0166]

[0167] in: and is a learnable parameter; b z is the bias term; z t It's a door.

[0168] The gated fusion mechanism adaptively controls the flow of long- and short-term temporal relationships at each time step. The spatial features of TE are extracted through GCN and MHSA mechanisms. GCN is used to learn spatial features. The principle of GCN is expressed as:

[0169]

[0170] Where: A represents the adjacency matrix; I is the identity matrix; is the degree matrix, represents the weight matrix and is a learnable parameter.

[0171] The spatial multi-attention (SMHSA) mechanism is used to extract global spatial relations. Given the input spatial feature X s ∈R T ×N×C , and then the spatial features are linearly transformed and mapped into three different spaces to obtain:

[0172]

[0173]

[0174] in: and are learnable parameters.

[0175] The spatial features extracted using the SMHSA mechanism are:

[0176] Hs =SMHSA(X t )=Concat(head 1 ,head 2 ,…head n )W s

[0177]

[0178] Where: n is the number of attention heads; W s is a learnable parameter; Softmax is an activation function.

[0179] Considering the local and global spatial relationship, a spatial feature fusion layer is used to fuse the outputs of GCN and SMHSA. In the first layer STFI block, the outputs of SMHSA and GCN are respectively and Specifically, the fused spatial features for:

[0180]

[0181]

[0182] in: and is a learnable parameter; b z is the bias term; z s It's a door.

[0183] In order to make full use of the dual temporal and spatial characteristics of thermal information data, the temporal and spatial feature interaction layer is used for information interaction. It allows the simultaneous use of temporal and spatial features to improve prediction accuracy. The temporal and spatial feature interaction layer effectively integrates two different types of information, which helps the proposed model to better understand the correlation of temporal and spatial features. It can also help the proposed model better understand the overall characteristics of temporal and spatial features and reduce feature redundancy. In addition, the temporal and spatial feature interaction layer allows the proposed model to dynamically adjust the importance of temporal and spatial features, and can adaptively adjust the weights of features to more effectively utilize temporal and spatial information. The temporal feature output obtained by the temporal and spatial feature interaction layer And spatial feature output They are:

[0184]

[0185]

[0186]

[0187]

[0188]

[0189]

[0190] in: and Represents the output of the STFI block at layer l; and is a learnable parameter; and is the bias term; f t and They respectively represent the intermediate variables and time feature extraction results after being processed by the Sigmoid activation function; represents the first intermediate variable after being processed by the Tanh activation function; f s and Represents the intermediate variables and spatial feature extraction results after being processed by the Sigmoid activation function; represents the second intermediate variable after being processed by the Tanh activation function; σ and Tanh are activation functions respectively.

[0191] 2.2 Spatial-temporal feature fusion

[0192] The spatiotemporal feature fusion layer is used to fuse the spatiotemporal features output by the nth layer STFI block. for:

[0193]

[0194]

[0195] Among them: H is the output of the spatiotemporal feature gating fusion layer, that is, the spatiotemporal feature after feature fusion W z,1 and W z,2 is a learnable parameter; b z is the bias term; z is the gate.

[0196] 2.3 Adjacency Matrix

[0197] Spatial position adjacency matrix A sp for:

[0198]

[0199] Among them, d ijis the spatial distance between node i and node j; σ is the standard deviation; κ is the threshold used to filter the connection between nodes. The larger the spatial distance, the lower the similarity value between the two nodes.

[0200] The measurement data of two nodes that are relatively far apart may also show similar trends, indicating that there is a potential correlation between the two nodes. Therefore, in order to fully consider the global spatiotemporal relationship, it becomes imperative to deeply study the semantic correlation between various measurement nodes. The Euclidean distance is not enough to accurately evaluate the similarity of two time series data, especially when the shapes of the two time series data graphs are similar but the time is not synchronized. The use of the DTW algorithm can effectively solve this problem. The temporal similarity adjacency matrix A se for:

[0201]

[0202] Among them, X i and X j denote the time series data of node i and node j respectively; DTW(·) denotes the dynamic time warping algorithm, and:

[0203]

[0204] Due to the joint influence of the common heat source, two adjacent nodes may indeed show similar trends. However, the difference in heat conduction caused by hysteresis can produce obvious trends between these adjacent nodes. Therefore, it is imperative to fully explore the complex relationship between spatial location and temporal similarity. In order to represent this basic relationship, a hybrid adjacency matrix is ​​introduced. Specifically, the hybrid adjacency matrix A h for:

[0205]

[0206] In this way, the spatial features extracted by GCN are:

[0207] h s =f(X s ,A sp ,A se ,A h )=σ(A h Relu(σ(A se X s W se )⊙Tanh(A sp X s W sp ))W h )

[0208] Where: W se ,W sp and W hA se ,A sp and A h The weight matrix of the three adjacency matrices.

[0209] Specifically, and Connected by a gate structure, the function of the gate structure is to control the inflow of valid thermal information data and invalid thermal information data. and The relationship between reflect.

[0210] 2.4 Small sample thermal error prediction method for high-speed precision machine tools based on temporal and spatial feature interactive fusion network

[0211] The present embodiment provides a small sample thermal error prediction method for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, comprising the following steps:

[0212] Step 1: Use multiple temperature sensors to collect thermal information data X of high-speed precision machine tools; divide the thermal information data X into training set D train ←(X train ,Y train ) and the test set D test ←(X test ,Y test );

[0213] Step 2: Construct a spatiotemporal feature interactive fusion network model, which includes a 1×1 CNN layer, L STFI blocks arranged in series, and a spatiotemporal feature fusion layer; the STFI block includes a time feature fusion layer and a space feature fusion layer arranged in parallel, and the time feature fusion layer and the space feature fusion layer are both connected to the spatiotemporal feature interactive layer; the time feature fusion layer uses the GTC and TMHSA mechanisms to extract the time features in the thermal information data and perform feature fusion, and the space feature fusion layer uses the GCN and SMHSA mechanisms to extract the space features in the thermal information data and perform feature fusion; the spatiotemporal feature interactive layer interacts the time features and the space features to dynamically adjust the importance of the time features and the space features, and obtains the time feature output and the space feature output after the interaction;

[0214] In two adjacent STFI blocks, the temporal feature output of the previous STFI block is used as the input of the spatial feature fusion layer of the next STFI block, and the spatial feature output of the previous STFI block is used as the input of the temporal feature fusion layer of the next STFI block;

[0215] Step 3: Initialize the parameters of the spatiotemporal feature interaction fusion network model and calculate the spatial position adjacency matrix A sp , time similarity adjacency matrix A seand the mixed adjacency matrix A h ; i = 1;

[0216] Step 4: Use 1×1 CNN layer to extract temporal features X t and spatial feature X s ; l = 1

[0217] Step 5: Use GTC and TMHSA mechanisms to extract features and obtain the outputs of GTC and TMHSA mechanisms respectively and

[0218] GCN and SMHSA mechanisms are used to extract features respectively, and the outputs of GCN and SMHSA mechanisms are obtained respectively. and

[0219] Step 6: and Input the time feature fusion layer to obtain the fused time feature Will and Input the spatial feature fusion layer to obtain the fused spatial features

[0220] Step 7: Time features and spatial characteristics Input to the spatiotemporal feature interaction layer to get the temporal feature output And spatial feature output

[0221] Step 8: Determine whether the number of layers l of the current STFI block is equal to the maximum number of layers L of the STFI block: If so, execute step 9; if not, use the temporal feature output of the previous STFI block as the input of the spatial feature fusion layer of the next STFI block, and use the spatial feature output of the previous STFI block as the input of the temporal feature fusion layer of the next STFI block; let l=l+1, and execute step 5;

[0222] Step 9: Input the temporal feature output and spatial feature output of the K-th layer STFI block to the spatiotemporal feature fusion layer to obtain the spatiotemporal feature after feature fusion

[0223] Step 10: Calculate the fused spatiotemporal features Compared with the real spatiotemporal features Y in the training set train The loss function between

[0224] Step 11: Update the spatiotemporal feature interaction fusion network model according to the loss function;

[0225] Step 12: Determine whether the current number of iterations i is equal to the preset maximum number of iterations I: If yes, execute step 13; if not, set i=i+1 and execute step 4;

[0226] Step 13: Use the test set to test the prediction performance of the trained spatiotemporal feature interactive fusion network model;

[0227] Step 14: Use the spatial-temporal feature interactive fusion network model to predict thermal errors.

[0228]

[0229] 3. Thermal Error Modeling

[0230] 3.1 Data Collection

[0231] Experimental systems and test equipment such as Fig. 9 As shown in (a), the high-speed precision machine tool system of the precision coordinate boring machine is taken as the research object. This embodiment develops a temperature displacement synchronous acquisition system based on the American NI-SCXI1600 architecture, which can synchronously acquire temperature and TE data. The main cause of TE is temperature rise, and these TE errors are usually predicted by monitoring the temperature rise of the high-speed precision machine tool system. According to expert experience, the selection criteria of the measurement points in the experiment are as follows: (1) The measurement point should be located at the main heat source of the high-speed precision machine tool system of the boring machine to accurately reflect its temperature field, because temperature rise is the direct cause of TE; (2) In order to avoid collinearity between temperature variables, only one measurement point should be selected for each heat source; (3) The measurement point should be located at a position where the sensor is easy to install without interfering with the normal operation process of the high-speed precision machine tool system. In the acquisition system, the precision magnetic temperature sensor PT100 is used to measure the temperature of key measurement points, such as motors, bearings, bases, coolants and environments. The specific installation positions are shown in Table 2.

[0232] Table 2 Specific installation position of temperature sensor

[0233]

[0234] This example collects thermal information data under three working conditions and verifies the prediction accuracy and robustness of the TE prediction model. Fig.10 As shown. It is worth noting that the rotation speed under the first working condition shows an increase first and then a decrease. In contrast, the rotation speed under the second working condition undergoes a cyclic pattern of speed increase and decrease every 80 minutes. The rotation speed under the third working condition adopts a random rotation speed.

[0235] The experimental measurement of thermal information data of high-speed precision machine tool systems is very time-consuming. The thermal information data acquisition time under the three working conditions is the same, which is 500 minutes. Under the first working condition, thermal information data is collected every 7.5 seconds, and then a total of 4000 thermal information data samples are collected. For thermal information data, there are nine temperature variables and one TE variable. Under the second and third working conditions, thermal information data is collected every 15 seconds, and then a total of 2000 thermal information data samples are collected.

[0236] The thermal information data collected under three working conditions are as follows Fig.11 As shown. The difference in rotation speed is reflected in the temperature and TE data. Specifically, under the first operating condition, both the temperature and TE data show a rapid initial rise, followed by a slower rise. For example, the TE data rises rapidly to 35μm, then gradually increases to 40μm, and then gradually decreases. In contrast, the temperature and TE data collected under the second operating condition show an overall upward trend. The rotation speed under the second operating condition experiences an initial increase, followed by a decrease over a certain period of time. Therefore, compared with the first operating condition, the TE under the second operating condition shows a slower rate of increase. At 150 minutes, the TE is only 15μm, and the TE data also rises and then falls within a certain period of time. The third operating condition uses a random rotation speed, the temperature data generally shows an upward trend, and the TE fluctuates with the rotation speed.

[0237] 3.2 Model parameter optimization

[0238] In existing research works, datasets corresponding to specific operating scenarios are divided into two parts. Subsequently, these segments are used to build training and testing datasets to evaluate robustness and prediction accuracy within the scope of specific operational scenarios. However, in real-world machining scenarios, mechanical parts are not always machined under specific operating conditions. To simulate real machining operations and evaluate the robustness of the model, our study adopts a unique approach. Here, data corresponding to one specific operating condition is used as the basis for the training set, while data originating from another different operating condition is reserved for the test set. This paradigm shift allows for a more comprehensive evaluation of the performance of the model in different operating scenarios. It involves utilizing the entire thermal information dataset from one specific operating condition for model training, while utilizing the thermal information dataset from another different operating condition for model testing. The goal is to rigorously evaluate the robustness and prediction accuracy of the proposed model. It is important to note that TE exhibits both long-term memory and nonlinear characteristics. As mentioned earlier, the current TE is intricately related to its historical counterpart. In order to fully capture the inherent long-term memory characteristics of TE, the training dataset of the STFIFN model contains all historical TE data from a single operating condition. This strategic approach ensures that the training dataset contains critical long-term memory information.

[0239] When the hyperparameters of the proposed model are different, its performance will also be different. Mean squared error (MSE), mean absolute error (MAE), root mean square error (RMSE) and prediction ability η are used as evaluation indicators to evaluate the performance of the proposed model.

[0240]

[0241] Where: N is the length of TE data; y i It is the real value; is the predicted value.

[0242] This embodiment uses the spatial distance of the measurement points to calculate the spatial position adjacency matrix, such as Fig.12 As shown in Figure 2, the spatial position of the temperature sensor and the displacement sensor has an impact on the correlation. The correlation varies with the spatial position of the temperature sensor and the displacement sensor. The threshold κ of the spatial position adjacency matrix is ​​1×10 -9 The similarity information between all two nodes is calculated by taking the minimum value of . This allows the spatial position adjacency matrix to capture global information, and then the influence of the spatial position of each node is extracted through the proposed STFIFN model. As a result, the node network remains fully connected without any isolated nodes.

[0243] like Fig.13 As shown in Figure 1, the temporal similarity adjacency matrix is ​​a graph. The threshold in the spatial position adjacency matrix is ​​not set to a specific value, and the threshold is dynamically adjusted by selecting the top 20% of the temporal similarity of each node to ensure that only nodes with high temporal similarity are retained. The temporal similarity adjacency matrix is ​​able to capture the local information and strong relationship between every two nodes with high temporal similarity. The spatial position adjacency matrix and the temporal similarity adjacency matrix are then combined to capture the global and local relationship between two nodes.

[0244] When tuning one hyperparameter, the other hyperparameters are already at their optimal values ​​by default. The impact of the main hyperparameters on model performance is as follows: Fig.14 The effect of the number of MHSA heads is shown in Fig.14 (a) As shown. It can be found that appropriately increasing the number of attention heads can improve model performance. When the model has the best performance, the number of attention heads is 4; followed by a slightly lower level of accuracy, the number of attention heads is 8; the accuracy of 16 heads further decreases, and the accuracy decrease of two heads is more obvious. The lowest model accuracy is observed when only one head is used. The effects of learning rate and batch size on model performance are shown in Figure 2. Fig.14(b) and (c). The model accuracy is highest at a learning rate of 0.01, followed by the model accuracy at a learning rate of 0.001. The model accuracy slightly decreases at a learning rate of 0.0001, and the model accuracy further decreases after a learning rate of 0.1. The learning rate of 0.00001 is the worst model accuracy. When the batch size is 32, the model accuracy is the highest, followed by the model accuracy when the batch size is 64, and the model accuracy is the worst when the batch size is 128. When the learning rate is 0.01 and the batch size is 32, the model has the most outstanding prediction performance. The impact of the number of STFI block layers on model performance is shown in Fig.14 (d). When the number of layers is 2, the model has the best performance, followed by the model accuracy when the number of STFI block layers is 3, and the model accuracy is the worst when the number of STFI block layers is 1. Properly increasing the number of MHSA headers and STFI block layers can improve the prediction performance of the proposed model. However, setting too high a value will make the model more complex, resulting in reduced computational efficiency, and may also make the model more prone to overfitting.

[0245] Choosing the right optimizer plays a key role in ensuring the best prediction and convergence performance of the STFIFN model. During the model tuning phase, different optimizers were tested, resulting in different loss curves for the STFIFN model. The quality of the optimizer was evaluated based on the convergence speed, the rate of decrease of the training loss, and the stability. Fig.15The loss curves of STFIFN when using different optimizers are shown. When stochastic gradient descent (SGD) is used as the optimizer, the training loss curve of STFIFN converges relatively quickly. However, at the convergence point, the loss value of STFIFN using SGD is higher compared to STFIFN using adaptive moment estimation (Adam) and adaptive moment estimation with infinite norm as optimizers. In addition, when SGD is used as the optimizer, significant fluctuations are observed in the loss curve throughout the training process. Therefore, the proposed model has lower accuracy when SGD is used as the optimizer compared to when Adam and Adamax are used as optimizers. In contrast, when Adam serves as the optimizer, the loss curve shows significant stability throughout the training process, and the STFIFN model shows fast convergence, reaching the minimum loss point at convergence. In addition, when STFIFN uses Adamax as the optimizer, STFIFN shows a slower convergence speed compared to STFIFN using Adam as the optimizer. Therefore, Adam is selected as the optimizer. The early stopping strategy is used to train the TE model with three different optimizers, and the epoch size is set to 100. Specifically, the TE model with the Adamax optimizer reaches the best performance at the 63rd epoch, and then triggers the early stopping strategy, causing the loss function curve to look incomplete. Although the early stopping strategy is used with the other two optimizers for the TE model, both of the two TE models converge at the 98th epoch. Then the loss function curve looks complete, as shown in Fig.15 For the STFIFN model, its hyperparameter settings are shown in Table 3. In order to avoid overfitting of the model, an early stopping strategy is used and patience is set to 20.

[0246] Table 3 Hyperparameters of STFIFN model

[0247]

[0248] This example studies whether the number and location of key measurement points affect robustness. The impact of the number of measurement points on prediction accuracy and robustness is as follows: Fig.16As shown. Thermal information data has strong spatiotemporal behavior. In order to achieve high prediction accuracy and strong robustness, a TE model that can capture the spatiotemporal behavior of thermal information data should be proposed. In the study of this embodiment, the STFIFN model is proposed to capture the spatiotemporal behavior of thermal information data. When the number of temperature variables is 9, the STFIFN model has the highest prediction accuracy, when the number of temperature variables is 6, the STFIFN model has the second highest prediction accuracy, and when the number of temperature variables is 3, the STFIFN model has the lowest prediction accuracy. Due to the insufficient number of measurement points, the amount of thermal information data input into the proposed STFIFN model is relatively limited. Then the insufficient spatiotemporal features of the thermal information data are extracted. This insufficient extraction of spatiotemporal features results in poor prediction accuracy and robustness of the proposed STFIFN model. The influence of the location of the measurement points on the prediction accuracy and robustness of the proposed STFIFN model is shown in Fig.17 As shown in the figure. Due to the incorrect location of the measurement points, some important thermal information data were not collected by the acquisition system and then not input into the proposed STFIFN model, resulting in poor prediction accuracy and robustness. Therefore, the improper location of the measurement points leads to the neglect of important thermal information data, which in turn leads to insufficient spatiotemporal features extracted by the proposed STFIFN model, and also reduces the prediction accuracy and robustness of the proposed ST FIFN model. The results show that the number and location of the measurement points directly affect the quality of the input data, spatiotemporal feature extraction, and model training process, which significantly affects the prediction accuracy and robustness of the TE model.

[0249] For the first working condition, the total number of thermal information data is 4000. The prediction performance of the proposed STFIFN model under different sample sizes was evaluated. 100% (i.e., 4000 samples), 50% (i.e., 2000 samples), and 25% (i.e., 1000 samples) of the thermal information data collected under the first working condition were used as training data sets, and the thermal information collected under the second working condition was used as a test data set. As shown in Table 4, the prediction performance of the proposed STFIFN model was evaluated. The results show that when 100% of the thermal information data collected under the first working condition is used as the training data set, the prediction ability and R2 are 98.51% and 0.9993, respectively. When 50% of the thermal information data collected under the first working condition is used as the training data set, the prediction ability and R 2 When 25% of the thermal information data collected under the first condition is used as the training data set, the prediction ability and R 2 They are 97.14% and 0.9952 respectively. When the minimum number of thermal information data is 1000, the proposed STFIFN model does not fail.

[0250] Table 4 Performance of the model under different sample sizes

[0251]

[0252] 4. Modeling results and verification

[0253] Modeling results

[0254] 4.1.1 Model Validation

[0255] In order to validate the proposed STFIFN model, a comprehensive comparative analysis of the base models was performed. The STFIFN model was implemented using the Pytorch machine learning framework. For comparison, the following models were selected: LSSVM, LSTM, CNN-LSTM, TCN, STGCN, GMAN, and STSGCN. Each of these models represents a different prediction method. LSSVM represents a traditional data-driven machine learning method. LSTM and TCN represent temporal prediction methods. CNN-LSTM is obtained by sequentially connecting CNN and LSTM models. STGCN, GMAN, and STSGCN represent spatiotemporal prediction models. These representative models are compared with the proposed STFIFN model.

[0256] The thermal information data from the high-speed precision machine tool under the first working condition is used as the training data set, while the thermal information data from the high-speed precision machine tool operating under the second working condition is used as the test data set. Fig.18 As shown. Subsequently, the prediction results are evaluated based on five indicators: MSE, MAE, RMSE, R2, and η. The evaluation results are shown in Table 5. The information provided discusses different spatiotemporal prediction models, including STGCN, GMAN, STSGCN, and STFIFN, as well as other traditional models such as LSSVM, LSTM, CNN-LSTM, and TCN. The prediction performance evaluation of these models based on RMSE, MSE, MAE, R2, and η is summarized. The lower the values ​​of RMSE, MSE, and MAE, the higher the prediction accuracy. The higher the value of the prediction ability η, the higher the prediction accuracy.

[0257] The STFIFN model exhibits the lowest RMSE, MSE, and MAE values ​​among all the models, with RMSE of 0.4082, MSE of 0.1666, and MAE of 0.3736. The lower values ​​in these metrics indicate that the predictions made by the STFIFN model are closer to the actual values. The predictive power η of STFIFN is consistently high, with a value of 98.51%. This indicates that the STFIFN model has extremely high prediction accuracy compared to the other models. The STGCN model adopts a sequential structure and performs temporal and spatial convolutions sequentially. The GMAN model uses spatial attention, temporal attention, and gated fusion mechanisms to extract and fuse spatiotemporal features. The STSGCN model uses local spatiotemporal subgraphs to extract spatiotemporal features synchronously, but ignores global effects. In contrast, the STFIFN model utilizes GTC, GCN, MHSA, spatial feature fusion layers, and temporal feature fusion layers to fully capture long-term and short-term relationships as well as global and local spatial relationships. This more comprehensive approach in STFIFN enables it to capture complex relationships more effectively. STFIFN has a dedicated spatiotemporal feature interaction layer that enables dual interactions of spatial and temporal features. This interaction is not fully realized in the STGCN and GMAN models, which may explain the superior prediction accuracy of STFIFN. LSSVM, LSTM, and TCN are traditional models, among which LSTM and TCN can only extract temporal features from the data. Therefore, their prediction performance is good but not as good as spatiotemporal models such as STSGCN and STFIFN. CNN-LSTM, as a spatiotemporal model, performs better than LSTM and TCN, but still lower than STFIFN.

[0258] The STGCN, GMAN, STSGCN, and STFIFN models are spatiotemporal prediction models, which show smaller RMSE, MSE, and MAE values ​​compared with other models. STGCN adopts a sequential structure, in which the convolution operation of the time dimension and the convolution operation of the spatial dimension are performed sequentially. This means that the capture and interaction of temporal and spatial features are carried out sequentially, and the complex relationship between them cannot be fully captured. STSGCN designs a local spatiotemporal subgraph to capture local spatiotemporal correlations simultaneously, but ignores global information. In the STFIFN model, GTC, GCN, and MHSA are used to fully capture the long-term and short-term relationships of temporal features and the global and local spatial relationships, respectively, which helps to improve the prediction accuracy. In addition, after fully capturing the temporal and spatial features, the spatiotemporal feature interaction layer is used to interact with each other. The spatiotemporal feature interaction layer realizes the dual interaction of spatiotemporal features. Therefore, the prediction accuracy of STFIFN is further improved and stronger than that of STGCN, GMAN, and STSGCN. Since the CNN-LSTM model can extract local spatial features from hot information data, its prediction accuracy is lower than that of STGCN and STFIFN. The STFIFN and STGCN models surpass the traditional temporal prediction models. The LSTM and TCN models can only extract temporal features from hot information data, so their prediction performance is lower than that of spatiotemporal models. LSSVM cannot capture temporal relationships, resulting in poor prediction performance. Fig.18 and Table 5 illustrate the relationship between TE and spatiotemporal features, emphasizing that only temporal features or spatial features are not sufficient to improve prediction accuracy.

[0259] In summary, the STFIFN model outperforms other models in terms of prediction accuracy, including data-driven models such as LSSVM, temporal prediction models such as LSTM, and even other spatiotemporal models such as STGCN. This can be attributed to its comprehensive approach to capturing complex spatiotemporal relationships and the effective interaction of these features, resulting in the lowest RMSE, MSE, and MAE values ​​and the highest prediction ability η in the evaluation. The prediction residual is the deviation between the actual measured TE and the model predicted value. The prediction residual under the second condition is shown in Fig.19 shown.

[0260] Fig.19 (a) Again, the residuals of the STFIFN model are generally closer to zero than those of the LSSVM, LSTM, and TCN, especially beyond 100 minutes. The residuals of the STFIFN also appear to exhibit less variance and fewer spikes, indicating that the predictions are more stable over time. Fig.19In (b), the residual of the STFIFN model is always close to zero compared to other models such as CNN-LSTM, STGCN, GMAN, and STSGCN. Its performance shows that the prediction error is smaller. These patterns indicate that the STFIFN model has a smaller residual magnitude, which means that it has better prediction accuracy and stability than the other proposed models.

[0261] Fig. 20 The probability density function (PDF) of the prediction residuals of the STFIFN model calculated using the kernel density estimation (KDE) method is shown. Using the mean and standard deviation obtained by the KDE method, the upper and lower bounds of the prediction residuals at a given confidence level can be determined. The upper and lower bounds of the prediction residuals at 80% and 95% confidence levels are calculated based on the mean and variance. The TE prediction intervals at 80% and 95% confidence levels are then calculated based on the deterministic prediction results of the proposed STFIFN model. The TE prediction intervals of STFIFN at 80% and 95% confidence levels are shown in Figure 2. Fig.21 The TE prediction intervals at 80% and 95% confidence levels are shown in light green and dark green, respectively.

[0262] The prediction performance of the existing Gaussian process regression (GPR) model

[36] and the STFIFN model are compared. Specifically, when the confidence level is 80% and 95%, the prediction interval of STFIFN is as follows: Fig.21 (a) and (b). When the confidence level is 80% and 95%, the prediction interval of GPR is as follows Fig. 22 As shown in Figure 2. When the confidence level is 80% and 95%, the prediction intervals are the light green and dark green areas respectively.

[0263] The reliability of the TE prediction interval is assessed by the prediction interval coverage probability (PICP), which is expressed as the ratio of the actual TE values ​​that fall between the upper and lower limits of the TE prediction interval:

[0264]

[0265] Among them: when y i ∈[L i ,U i ], C i =1, otherwise C i =0;L i and U i They are The lower and upper bounds of .

[0266] The PICP values ​​of the TE prediction interval and the evaluation results of STFIFN and GPR are shown in Table 6. Among them, the PICP values ​​of the TE prediction intervals obtained at the 80% and 95% confidence levels are greater than the corresponding confidence levels. Therefore, the TE prediction intervals obtained using the kernel density estimation (KDE) method and GPR are credible. For the GPR model, the RMSE, MSE, and MAE are 1.0061, 1.0122, and 0.8786, respectively. These evaluation indicators obtained by the GPR model, including RMSE, MSE, and MAE, are greater than those obtained by the STFIFN model. The R 2 and the predictive ability η are 0.9956 and 96.50% respectively. The R 2 and prediction ability η are 0.9993 and 98.51% respectively. These evaluation indicators including R2 and prediction ability η obtained by GPR model are lower than those obtained by STFIFN model.

[0267] In addition, at the 80% and 95% confidence levels, the PICP values ​​of the GRP model are significantly lower than those of the STFIFN model. It is obvious that the prediction accuracy of the STFIFN model is much higher than that of the GPR model, and the prediction interval obtained by STFIFN is much smaller than that obtained by the GRP model. When the STFIFN model is combined with the KDE method, the prediction accuracy is more reliable.

[0268] Table 6 PICP and prediction performance evaluation of TE prediction interval

[0269]

[0270] 4.1.2 Cross-Validation

[0271] Then, the thermal information data from the high-speed precision machine tool under the second working condition is used as a training data set, and the thermal information data from the high-speed precision machine tool under the first working condition is used as a test data set for cross-validation. The prediction results are shown in Fig.23 The evaluation results are shown in Table 7. The prediction residual under the first condition is Fig.24 The results show that the training dataset consists of TE data of a high-speed precision machine tool under the second condition, and the test dataset includes TE data of the same high-speed precision machine tool under the first condition. The following is a more in-depth analysis and emphasis on the advantages of the STFIFN model.

[0272] The fact that STFIFN consistently outperforms other models under different operating conditions demonstrates its robustness and generalization ability. STFIFN maintains the highest predictive ability η among all models, with a value of 98.74%. This means that the STFIFN model can accurately predict the TE data under the first operating condition, surpassing all other models, including the traditional LSSVM and the more advanced LSTM, CNN-LSTM, TCN, STGCN, GMAN, and STSGCN. STFIFN again provides the lowest RMSE, MSE, and MAE values ​​in Table 7. These metrics are critical for evaluating prediction accuracy, and the consistently superior performance of STFIFN highlights its ability to make predictions that are very close to the actual values. The performance of STFIFN is particularly noteworthy compared to other spatiotemporal models. Although STGCN, GMAN, and STSGCN are spatiotemporal models, STFIFN consistently outperforms them, indicating that its unique architecture and feature interaction mechanism provide superior prediction accuracy.

[0273] In summary, the results obtained under the first operating condition highlight the following key points: STFIFN is very effective in cross-validation scenarios and can be generalized from one operating condition to another. The prediction ability ηmetric shows that STFIFN performs best, indicating its ability to provide highly accurate predictions. STFIFN consistently outperforms other models, including traditional models and other spatiotemporal models such as STGCN, in terms of RMSE, MSE, and MAE. Together, these results illustrate the superiority of the STFIFN model in capturing complex spatiotemporal relationships and making accurate predictions under different operating conditions. STFIFN maintains strong robustness under various operating conditions. Among the above spatiotemporal models, the reason why STFIFN has the strongest robustness under various operating conditions is that the STFIFN model is able to extract spatiotemporal features with small sample thermal information data as input. Among the above temporal models, the reason why STFIFN has the strongest robustness under various operating conditions is that the STFIFN model is able to extract spatial features of small sample thermal information data.

[0274] 4.1.3 Model Robustness

[0275] The robustness and effectiveness of the TE prediction model are verified using the data collected under the third working condition. The trained TE model in Section 4.1.1 uses the thermal information dataset under the third working condition as the test dataset to verify the robustness and generalization ability of the TE model. The prediction results are shown in Fig.25 The evaluation results are shown in Table 8. The prediction residual under the third working condition is shown in Fig.26As shown. The prediction ability η of the STFIFN model is the highest among all TE models, which is 98.54%. Therefore, the STFIFN model can effectively predict the TE data under the third working condition, and its prediction accuracy is higher than that of other TE models. STFIFN obtained the lowest RMSE, MSE and MAE values, with RMSE of 0.4424, MSE of 0.1958 and MAE of 0.3207. The prediction accuracy of STFIFN is higher than that of STGCN, GMAN and STSGCN, highlighting its ability to provide more accurate predictions under different working conditions. STFIFN is better than STGCN, GMAN and STSGCN in extracting spatiotemporal features. The prediction accuracy of traditional TE models including LSSVM, LSTM and TCN is high, but worse than that of STGCN, GMAN, STSGCN and STFIFN, emphasizing the importance of considering spatiotemporal relationships in TE modeling.

[0276] In summary, the TE prediction results obtained under the third working condition reinforce the following key points: STFIFN has stronger robustness and strong generalization ability than STGCN, GMAN, STSGCN, SSVM, LSTM, and TCN. The prediction performance of STFIFN is much stronger than other TE models, including traditional models and spatiotemporal models such as STGCN. These results emphasize the advantages of the STFIFN model in capturing complex spatiotemporal relationships and providing accurate predictions under different working conditions, further verifying its prediction accuracy and robustness. The proposed STFIFN model realizes the modeling of small sample thermal information data and the fusion of spatiotemporal features. With large sample thermal information data as input, STGCN, GMAN, and STSGCN have good prediction accuracy and robustness.

[0277] Table 8 Prediction performance evaluation of the third operating condition

[0278]

[0279] 4.2 Ablation Experimental Study

[0280] The effectiveness of MHSA, hybrid adjacency matrix, and spatiotemporal feature interaction layer in STFIFN is verified by ablation experiments. Table 9 lists the values ​​of the evaluation indicators. The models without MHSA, hybrid adjacency matrix, and spatiotemporal feature interaction layer are represented by STFIFN2, STFIFN3, and STFIFN4, respectively. The RMSE of STFIFN, STFIFN2, STFIFN3, and STFIFN4 models are 0.4082, 0.7578, 0.6797, and 0.7952, respectively. The prediction ability η of STFIFN, STFIFN2, STFIFN3, and STFIFN4 models is 97.36%, 97.74%, 97.42%, and 98.51%, respectively. The MHSA mechanism is able to extract long-term temporal relationships and global spatial relationships in thermal information data. The hybrid adjacency matrix combines spatial location information and temporal similarity information, which can more comprehensively describe the characteristics of thermal information data. The spatiotemporal feature interaction layer allows GCN and GTC to exploit spatiotemporal features simultaneously, thus improving prediction accuracy. The results show that STFIFN exhibits superior prediction accuracy compared to STFIFN2, STFIFN3, and STFIFN4. This demonstrates the effectiveness of MHSA, hybrid adjacency matrix, and spatiotemporal feature interaction layer.

[0281] The results show that STFIFN (with MHSA, hybrid adjacency matrix, and interaction layer) has the best prediction accuracy with RMSE of 0.4082 and a predictive ability η of 98.51%. This shows that the full STFIFN model is very effective in making accurate predictions. Comparing STFIFN and STFIFN2 (without MHSA), it is clear that the MHSA mechanism contributes significantly to the prediction accuracy of the model. STFIFN outperforms STFIFN2 in terms of RMSE (0.4082 vs. 0.7578) and predictive ability η (98.51% vs. 97.36%). MHSA helps to extract long-term temporal relationships and global spatial relationships, and its absence leads to a less accurate model. Comparing STFIFN and STFIFN4 (without interaction layer), it is clear that the spatiotemporal feature interaction layer is also crucial. STFIFN outperforms STFIFN4 in terms of RMSE (0.4082 vs. 0.7952) and predictive ability η (98.51% vs. 97.42%). The interaction layer enables GCN and GTC to exploit spatiotemporal features simultaneously and improve prediction accuracy. The results jointly demonstrate that the STFIFN model is superior in prediction accuracy compared to the two ablated versions (STFIFN2 and STFIFN4). This highlights the effectiveness of MHSA and the spatiotemporal feature interaction layer in capturing complex relationships and improving prediction performance.

[0282] In summary, ablation experiments confirm that the MHSA mechanism, hybrid adjacency matrix, and spatial-temporal feature interaction layer play a crucial role in the prediction accuracy of the STFIFN model. The full STFIFN model effectively combines these components to produce superior predictions. MHSA helps capture temporal and spatial relationships, while the interaction layer improves the utilization of spatial and temporal features. These results reinforce the overall advantage of the STFIFN model in capturing complex spatial and temporal relationships and making high-precision predictions.

[0283] Table 9 Prediction performance evaluation of different models

[0284]

[0285] 4.3 Thermal Error Compensation Verification

[0286] like Fig. 27 As shown, the small sample thermal error compensation system of high-speed precision machine tools based on the space-time feature interactive fusion network in this embodiment includes a data acquisition system, a thermal error prediction module and a control module; the data acquisition system includes a temperature sensor installed on the high-speed precision machine tool and a signal processing module for processing the data collected by the temperature sensor; the thermal error prediction module adopts the space-time feature interactive fusion network model, and uses the small sample thermal error prediction method of high-speed precision machine tools based on the space-time feature interactive fusion network as described in this embodiment to predict the thermal error; the control system uses an NC program to convert the predicted thermal error into an error compensation component, and controls each motion axis of the machine tool to move according to the movement amount after subtracting the corresponding error compensation component through a CNC controller.

[0287] Specifically, Fig. 27The complex process of TE compensation is depicted in Figure 1. The proposed model is seamlessly integrated into the error prediction module to carefully calculate the error compensation components. These compensation components are subsequently transferred to the computer numerical control (CNC) interface. Subsequently, the compensation components are seamlessly superimposed with the machining instructions to achieve TE compensation. The key control board is the core of the effectiveness of the error prediction module. The connection between the error prediction module and the CNC system is perfectly established through Ethernet. The connection between the error prediction module and the data acquisition system is professionally established through the universal serial bus (USB). Meanwhile, the connection between the error prediction module and the personal computer (PC) is seamlessly facilitated through the high-definition multimedia interface (HDMI). The core of the error prediction module is the field programmable gate array (FPGA), which is known for its inherent parallel computing capabilities, which is a great asset for performing TE prediction using the proposed model. It is worth noting that the CNC system used here is Siemens 840Dsl. The temperature data is carefully acquired through a dedicated processing module. The TE model is expertly embedded in the TE prediction module based on advanced algorithms including LSSVM, LSTM, CNN-LSTM, TCN, STGCN, and STFIFN. This symbiotic integration ultimately achieves real-time TE compensation.

[0288] The high-speed precision machine tool system was TE compensated, so its TE was re-evaluated. The comparison of these TE measurements in different models is shown in Figure 2. Fig.28The maximum, minimum, and average TE values ​​of each of these models are listed in Table 10. It is worth noting that the LSSVM model exhibits the highest maximum TE value at 40.2937 μm, indicating that it has the lowest control effect on TE. In contrast, the CNN-LSTM, TCN, and STFIFN models show excellent performance with significantly lower maximum TE values, highlighting their effectiveness in mitigating TE. The LSTM and STGCN models have intermediate minimum TE values, while the CNN-LSTM, TCN, and STFIFN models show more balanced and accurate control by avoiding extreme negative values. The absolute average TE value provides insight into the overall prediction stability and accuracy of the models. The LSSVM model has the highest absolute average TE value of 2.0123 μm, indicating that there are some inconsistencies in TE control. In contrast, the CNN-LSTM, LSTM, and TCN models show superior accuracy and achieve the lowest absolute average TE values. The STGCN and STFIFN models also perform well in this regard, indicating high control accuracy. The reduction rate is an important indicator for evaluating the effectiveness of TE compensation. It reveals the percentage by which the model reduces the TE value, with a higher percentage indicating more effective compensation. It is worth noting that the LSTM, STGCN, TCN, and STFIFN models achieve impressive reduction rates of over 95%. The TE reduction rate of the STFIFN model is 97.91%. This means that they are able to significantly reduce TE in high-speed precision machine tool systems. The maximum TE, minimum TE, average TE, and TE reduction rate of the STFIFN model are smaller than those of LSTM, STGCN, and TCN. The effectiveness of the proposed STFIFN model is then fully verified.

[0289] In summary, the analysis highlights that the CNN-LSTM, TCN, and STFIFN models outperform the other models in terms of maximum TE control and absolute average TE values, demonstrating their effectiveness in minimizing TE. In addition, the STFIFN model is more effective than the other models in TE compensation. Furthermore, the LSTM, STGCN, TCN, and STFIFN models exhibit strong reduction rates, highlighting their ability to effectively compensate for TE in high-speed precision machine tool systems.

[0290] Table 10 Comparison of different models

[0291]

[0292] 4.4 Results and Discussion

[0293] Through the above extensive discussion, several general conclusions are drawn on the effectiveness and superiority of the STFIFN model in spatiotemporal forecasting tasks. Specifically:

[0294] (1) The importance of considering both spatial and temporal features in spatiotemporal prediction of TE tasks is emphasized. Compared with spatiotemporal models such as STFIFN, STSGCN, GMAN, and STGCN, traditional models that only focus on temporal data or spatial data consistently perform poorly. The results show that STFIFN is robust under different operating conditions. It consistently outperforms other models, including traditional models and spatiotemporal models, under different conditions. This emphasizes its robustness and generalization ability. Ablation experiments highlight the importance of the MHSA mechanism and the spatiotemporal feature interaction layer in the STFIFN model. Both components contribute significantly to the prediction accuracy of the proposed model. The MHSA mechanism helps capture long-term temporal and global spatial relationships, while the interaction layer improves the utilization of spatiotemporal features. The STFIFN model consistently outperforms other models in terms of RMSE, MSE, MAE, and prediction ability η under different operating conditions. It provides predictions that are closer to the actual values ​​and achieves the highest prediction ability η in most cases, emphasizing its overall advantage. The architecture of the STFIFN model enables it to effectively capture the complex relationship between temporal and spatial features. This is especially valuable in spatiotemporal forecasting tasks where understanding the interactions between these features is crucial.

[0295] (2) STFIFN exhibits the most effective TE compensation, followed by STSGCN, GMAN, and STGCN, with CNN-LSTM taking the second place, followed by TCN, LSTM, and LSSVM. STFIFN exhibits the best control effect, followed by STSGCN, GMAN, and STGCN. Subsequently, CNN-LSTM exhibits commendable performance, followed by TCN, LSTM, and finally LSSVM. STFIFN is known for its complex and advanced design and excels in effectively understanding and mitigating TE. Complex models such as STSGCN, MAN, and STGCN rank second due to their ability to capture complex thermal patterns. CNN-LSTM’s deep understanding of temporal dependencies puts it in third place. The model is able to effectively establish complex relationships in which thermal information data changes over time. Although TCN is not as complex as the previous models, it effectively utilizes temporal convolutions, contributing to its strong performance in TE compensation. Despite LSTM’s versatility in handling a variety of sequence tasks, it ranks fifth due to the special requirements of TE control. It may not be optimized for this specific application. LSSVM is the simplest model in the lineup and struggles with the complexity of TE patterns, leading to the least effective compensation. Its limitations in handling nonlinearities and complex data explain its position at the bottom. In summary, the ranking reflects the models' ability to understand and compensate for TE. Models with higher complexity, advanced architectures, and a deeper understanding of temporal relationships tend to perform better in this context. Simpler models, such as LSSVM, tend to lag behind.

[0296] In summary, the discussion shows that the STFIFN model is very effective for spatiotemporal prediction tasks, demonstrating its robustness, generalization ability, and the importance of its individual components. The advantages of STFIFN are consistent across different conditions, highlighting its value in capturing complex spatiotemporal relationships and making accurate predictions. These conclusions can guide the adoption of advanced spatiotemporal modeling techniques in various fields. The STFIFN model has been shown to be very effective in the field of TE compensation. The STFIFN model provides excellent TE control effects, and its main feature is the ability to accurately predict and compensate TE in a real-time machining environment. STFIFN provides precise and tailored compensation values, effectively reducing TE during machining. This leads to a significant improvement in the geometric accuracy of the final product.

[0297] 5. Conclusion

[0298] In order to improve the machining accuracy of precision machine tools, a new STFIFN model for small sample TE modeling of high-speed precision machine tools based on the spatiotemporal feature interaction fusion network is proposed. The model consists of multiple STFI blocks connected in series. For the STFI blocks in the time dimension, MHSA and gated temporal convolution are used to capture long-term and short-term temporal relationships, respectively. In the spatial dimension, MHSA and GCN are used to capture global and local spatial relationships, respectively. Given the unique characteristics of thermal information data, when capturing temporal and spatial features, the spatiotemporal feature interaction occurs, enabling the proposed STFIFN model to simultaneously utilize spatiotemporal features. In order to further improve the prediction accuracy and robustness, a hybrid adjacency matrix is ​​used, including spatial position adjacency, semantic adjacency, and motion adjacency matrices. With the deepening of the network depth, the hybrid adjacency matrix can fully capture the spatiotemporal feature information. Finally, the extracted features are transferred to the spatiotemporal feature gated fusion layer, where a gating mechanism is applied to fuse the information. The proposed STFIFN model is used for TE compensation, which effectively reduces the TE of high-speed precision machine tools. The main conclusions are as follows:

[0299] (1) The STFI block combines MHSA with gated temporal convolution in the temporal dimension and pairs MHSA with GCN in the spatial dimension. This fusion captures both long-term and short-term temporal relationships as well as global and local spatial relationships. After extracting and fusing temporal and spatial features, the proposed STFIFN model includes a spatiotemporal feature interaction layer. This promotes the interaction of spatiotemporal features and enables the simultaneous utilization of temporal and spatial features.

[0300] (2) The proposed STFIFN model consists of multiple STFI blocks, spatiotemporal feature fusion layers, and residual structures. This architecture ensures the comprehensive capture of spatiotemporal feature information while maintaining data integrity, even for small samples of thermal information data. The practicality of the model is demonstrated by applying it to TE prediction under various working conditions of precision machine tools. The results show that the STFIFN model significantly outperforms other models in terms of volume, achieving a prediction accuracy of 98.74%. STFIFN maintains strong robustness under various working conditions. STFIFN excels in small sample thermal information data modeling and spatiotemporal feature fusion scenarios.

[0301] (3) New architectural features are introduced to combine MHSA with gated temporal convolution and MHSA with GCN to effectively capture various temporal and spatial relationships and highlight the innovation of the model. The use of hybrid adjacency matrix is ​​a noteworthy contribution that helps to capture comprehensive spatiotemporal feature information. The spatiotemporal feature fusion layer and gating mechanism improve prediction accuracy by allowing the simultaneous use of temporal and spatial features.

[0302] (4) Incorporating DTW in the creation of the adjacency matrix allows for a more accurate and nuanced assessment of the temporal similarities between measured nodes. Unlike traditional distance metrics, DTW takes into account the shape and temporal alignment of time series data, providing a more comprehensive understanding of their similarities. By leveraging DTW, the modeling of spatiotemporal relationships is enhanced. The resulting adjacency matrix captures the spatial location and dynamic evolution of hot information data over time.

[0303] (5) The proposed STFIFN models play a vital role in the field of TE compensation, ensuring that thermal fluctuations are not only acknowledged but also actively mitigated. They achieve this through advanced architecture, strong temporal understanding, and adaptability to dynamic conditions, providing highly accurate compensation values ​​in real time. The STFIFN model achieves a TE reduction of 97.91%. In addition, the proposed STFIFN model is more effective than the LSSVM, TCN, STGCN, CNN-LSTM, and LSTM models.

[0304] In summary, this paper contributes to the field of small-sample TE modeling for high-speed precision machine tools by introducing innovative architectural components and demonstrating the practical applicability of the proposed STFIFN model. The conclusions emphasize the significance of the STFIFN model in improving the machining accuracy of precision boring machines. The architecture of digital twin systems has attracted great attention in the field of intelligent manufacturing. In the future, the collaborative capabilities of cloud-edge computing technologies should be exploited to build digital twin systems for TE control of machine tools. Within this framework, cloud computing will be utilized to train deep learning-based TE models. In addition, dual models of machine tools and machining processes should be embedded in the digital twin system.

[0305] The above-described embodiments are only preferred embodiments for fully illustrating the present invention, and the protection scope of the present invention is not limited thereto. Equivalent substitutions or changes made by those skilled in the art based on the present invention are within the protection scope of the present invention. The protection scope of the present invention shall be subject to the claims.

Claims

1. A small sample thermal error prediction method for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, characterized by: The steps include: Step 1: Use multiple temperature sensors to collect thermal information data X of high-speed precision machine tools; divide the thermal information data X into training set D train ←(X train ,Y train ) and the test set D test ←(X test ,Y test ); Step 2: Construct a spatiotemporal feature interactive fusion network model, which includes a 1×1 CNN layer, L STFI blocks arranged in series, and a spatiotemporal feature fusion layer; the STFI block includes a time feature fusion layer and a space feature fusion layer arranged in parallel, and the time feature fusion layer and the space feature fusion layer are both connected to the spatiotemporal feature interactive layer; the time feature fusion layer uses the GTC and TMHSA mechanisms to extract the time features in the thermal information data and perform feature fusion, and the space feature fusion layer uses the GCN and SMHSA mechanisms to extract the space features in the thermal information data and perform feature fusion; the spatiotemporal feature interactive layer interacts the time features and the space features to dynamically adjust the importance of the time features and the space features, and obtains the time feature output and the space feature output after the interaction; In two adjacent STFI blocks, the temporal feature output of the previous STFI block is used as the input of the spatial feature fusion layer of the next STFI block, and the spatial feature output of the previous STFI block is used as the input of the temporal feature fusion layer of the next STFI block; Step 3: Initialize the parameters of the spatiotemporal feature interaction fusion network model and calculate the spatial position adjacency matrix A sp , time similarity adjacency matrix A se and the mixed adjacency matrix A h ; i = 1; Step 4: Use 1×1 CNN layer to extract temporal features X t and spatial feature X s ; l = 1 Step 5: Use GTC and TMHSA mechanisms to extract features and obtain the outputs of GTC and TMHSA mechanisms respectively and GCN and SMHSA mechanisms are used to extract features respectively, and the outputs of GCN and SMHSA mechanisms are obtained respectively. and Step 6: and Input the time feature fusion layer to obtain the fused time feature Will and Input the spatial feature fusion layer to obtain the fused spatial features Step 7: Time features and spatial characteristics Input to the spatiotemporal feature interaction layer to obtain the temporal feature output T t ' (k) And the spatial feature output S s ' (l) ; Step 8: Determine whether the number of layers l of the current STFI block is equal to the maximum number of layers L of the STFI block: If so, execute step 9; if not, use the temporal feature output of the previous STFI block as the input of the spatial feature fusion layer of the next STFI block, and use the spatial feature output of the previous STFI block as the input of the temporal feature fusion layer of the next STFI block; Let l=l+1, and execute step 5; Step 9: Input the temporal feature output and spatial feature output of the K-th layer STFI block to the spatiotemporal feature fusion layer to obtain the spatiotemporal feature after feature fusion Step 10: Calculate the fused spatiotemporal features Compared with the real spatiotemporal features Y in the training set train The loss function between Step 11: Update the spatiotemporal feature interaction fusion network model according to the loss function; Step 12: Determine whether the current number of iterations i is equal to the preset maximum number of iterations I: If yes, execute step 13; if not, set i=i+1 and execute step 4; Step 13: Use the test set to test the prediction performance of the trained spatiotemporal feature interactive fusion network model; Step 14: Use the spatial-temporal feature interactive fusion network model to predict thermal errors.

2. According to claim 1, the method for predicting thermal errors of high-speed precision machine tools with small samples based on the temporal-spatial feature interactive fusion network is characterized by: In the step three: The spatial position adjacency matrix A sp for: Among them, d ij is the spatial distance between node i and node j; σ is the standard deviation; κ is the threshold used to filter the connections between nodes; The temporal similarity adjacency matrix A se for: Among them, X i and X j denote the time series data of node i and node j respectively; DTW(·) denotes the dynamic time warping algorithm; Mixed adjacency matrix A h for:

3. According to claim 1, the method for predicting thermal errors of high-speed precision machine tools with small samples based on a temporal-spatial feature interactive fusion network is characterized by: In step 5, the time feature extracted by GTC is: h t =GTC(X t )=Tanh(Φ1*X t +a)⊙σ(Φ2*X t +b) Among them, Φ1 and Φ2 are independent dilated causal convolutions; a and b are bias terms; Tanh and σ are activation functions; ⊙ is the Hadamard product; The temporal features extracted using the TMHSA mechanism are: H t =TMHSA(X t )=Concat(head1,head2,…head n )W t Where n is the number of attention heads; W t is a learnable parameter; Softmax is an activation function; and: in, and is a learnable parameter; In step 6, the fused time features for: Where: W t z,1 and W t z,2 is a learnable parameter; b z is the bias term; z t It's a door.

4. According to claim 1, the method for predicting thermal errors of high-speed precision machine tools with small samples based on a temporal-spatial feature interactive fusion network is characterized by: The spatial features extracted by GCN are: h s f(X s ,AM sp ,AM se ,AM h )6σ(A h Reluctance(σ(A). se X s W se )⊙Tanh(A sp X s W sp ))W h ) Where: W se ,W sp and W h A se ,A sp and A h The weight matrix of the three adjacent matrices; The spatial features extracted using the SMHSA mechanism are: H s =SMHSA(X t )=Concat(head1,head2,…head n )W s Where: n is the number of attention heads; W s is a learnable parameter; Softmax is an activation function; and: Where: W s qi ,W s ki and W s vi is a learnable parameter; In step 6, the fused spatial features for: Where: W s z,1 and W s z,2 is a learnable parameter; b z is the bias term; z s It's a door.

5. The method for predicting small sample thermal errors of high-speed precision machine tools based on a spatiotemporal feature interactive fusion network according to claim 1 is characterized in that: In step 7, the time feature output T t ' (k) And the spatial feature output S s ' (l) They are: Where: T t ' (l) and S s ' (l) Represents the output of the STFI block at layer l; and is a learnable parameter; and is the bias term; f t and They respectively represent the intermediate variables and time feature extraction results after being processed by the Sigmoid activation function; represents the first intermediate variable after being processed by the Tanh activation function; f s and Represents the intermediate variables and spatial feature extraction results after being processed by the Sigmoid activation function; represents the second intermediate variable after being processed by the Tanh activation function; σ and Tanh are activation functions respectively.

6. The method for predicting small sample thermal errors of high-speed precision machine tools based on a spatiotemporal feature interactive fusion network according to claim 1 is characterized in that: In step nine, the spatiotemporal features after feature fusion for: H=z⊙T t ′ (l) +(1-z)⊙S s ′ (l) z=σ(T t ′ (l) W z,1 +S s ′ (l) W z,2 +b z ) Among them: H is the output of the spatiotemporal feature gating fusion layer, that is, the spatiotemporal feature after feature fusion W z,1 and W z,2 is a learnable parameter; b z is the bias term; z is the gate.

7. A small sample thermal error compensation system for high-speed precision machine tools based on a spatiotemporal feature interactive fusion network, characterized in that: It includes a data acquisition system, a thermal error prediction module and a control module; The data acquisition system includes a temperature sensor installed on a high-speed precision machine tool and a signal processing module that processes data collected by the temperature sensor; The thermal error prediction module adopts a spatiotemporal feature interactive fusion network model, and uses a high-speed precision machine tool small sample thermal error prediction method based on a spatiotemporal feature interactive fusion network as described in any one of claims 1 to 6 to predict the thermal error; The control system uses an NC program to convert the predicted thermal error into an error compensation component, and controls each motion axis of the machine tool to move according to the movement amount after subtracting the corresponding error compensation component through a CNC controller.

Citation Information

Cited By

  • Machine tool thermal error prediction method based on multi-modal deep learning and domain adaptation

    CN120234592A

  • Face gear worm grinding machine geometric-thermal error compensation system based on digital twinning

    CN120370840A