## 3 Materials and Methods
### Local Estnet  
Whether in the central cloud or edge, we deploy an ESTNet with the same structure. As shown in Figure 2, ESTNet consists of four components: input embedding layer, gating fusion layer, spatio-temporal learning layer, and prediction layer. Specifically, ESTNet was designed as a hierarchical architecture. In the following, we detail how the data flows through each component from the the perspective of the local ESTNet deployed on the ECS \(i\). _(1) Input Embedding Layer_: For the local dataset \(D_{i}\), considering the collaborative training of urban \(PM_{2.5}\) and external factors, it is necessary to standardize the dimensions of these two data types. Assuming historical \(P\) timesteps of urban \(PM_{2.5}\) observations \(X=(X_{t_{1}},X_{t_{2}},\ldots,X_{t_{p}})\in\mathbb{R}^{P\times n_{i}\times F}\), we adopt two-layer FCs to convert \(X\) from \(F\) into \(d_{model}\) dimensions, which can be denoted as \(HX=(H_{t_{1}},H_{t_{2}},\ldots,H_{t_{p}})\in\mathbb{R}^{P\times n_{i}\times d _{model}}\), where \(n_{i}\) represents the number of air quality monitoring sites in an urban region \(i\). External factors, e.g., meteorological conditions, have a significant impact on urban \(PM_{2.5}\). There are discrepancies in the impact of different external factors [10; 11; 12]. In this work, we chose weather conditions, temperature, and wind speed as external factors. To highlight different degrees of impact, we classified weather conditions into five different types: sunny, overcast, rainy, snowy, and hazy, and then employ one-hot encoding to convert each type into a vector. According to experience, we categorized the temperature into 10 levels, with a temperature difference of 5 \({}^{\circ}\)C for each level. Based on the official classification, wind speed was projected into 13 levels. Temperature and wind speed were normalized proportionally in the range [0, 1]. Finally, we concatenated all external  
Figure 2: The architecture of the local ESTNet deployed on the ECS \(i\). First, fully connected networks (FCs) are adopted to transform urban \(PM_{2.5}\) and external factors into \(HX\in P\times n_{i}\times d_{\text{model}}\)  and, respectively. Then, the gating fusion layer is utilized to fuse these two features, which is represented as \(H\in P\times n_{i}\times d_{\text{model}}\). Here, the fused feature at timestep \(t_{j}\) is \(H_{t_{j}}\in n_{i}\times d_{\text{model}}\). Furthermore, a spatio-temporal learning layer is proposed to mine spatio-temporal correlations and the output representations of timestep \(t_{j}\) are \(HST_{t_{j}}\in n_{i}\times d_{\text{model}}\). Finally, we leverage the decoder of seq2 seq joint FCs to produce the prediction sequences, where \(Y_{t_{p+i}}\in n_{i}\times F\) denotes the predicted value of \(n_{i}\) sensors in the urban region \(i\) at the predicted timestep \(t_{p+k}\). In addition, \(\odot\) is a dot product. \(\sigma\) and \(tan\) stand for the activation functions _sigmoid_ and \(tanh\). factors of the same timestep into a one-dimensional tensor \(E\in\mathbb{R}^{Z}\), where \(Z\) stands for the dimension of the concatenated tensor. The external factors of the different sites and timesteps were concatenated to obtain the external factor representations of urban region \(i\), which is formalized as \(TE\in\mathbb{R}^{P\times n_{i}\times Z}\). To facilitate follow-up processing, two-layer FCs are utilized to transform the \(TE\) to \(d_{model}\)-dimension, which can be represented as \(HTE\in\mathbb{R}^{P\times n_{i}\times d_{\text{model}}}\). _(2) Gating Fusion Layer_: A common strategy, i.e., to extract the impact of external factors on urban \(PM_{2.5}\), is to directly concatenate external factor data with urban \(PM_{2.5}\) data [30,31]. Unfortunately, it is unreasonable to view the effects of external factors through concatenating with urban \(PM_{2.5}\) features with the same weight.