## 2 Seismic Profile Signal Reconstruction Model
### Base Network
features into non-overlapping local windows to capture intra-window dependencies while reducing self-attention computational costs, whereas SW-MSA establishes cross-window feature interactions through window position shifting, achieving effective global context fusion without significant computation overhead. The fundamental module of Swin Transformer consists of Layer Normalization (LN), Window-Based Multi-Head Self-Attention (W-MSA) units, Shifted Window-Based Multi-Head Self-Attention (SW-MSA) units, and Multi-Layer Perceptrons (MLP). Here, LN normalizes features to provide stable inputs for subsequent attention calculations [17]. W-MSA and SW-MSA form a hierarchical feature extraction mechanism through alternating stacking, enabling joint modeling of local details and global dependencies. The MLP enhances feature representational power via nonlinear transformations. The specific architecture of this module is illustrated in Figure 2, showing the architecture of a Swin Transformer, while two consecutively stacked Swin Transformer units form a progressive contextual information aggregation system through hierarchical attention connections, as schematically depicted in Figure 3, Schematic diagram of the plates of the Swin Transformer. Based on this window segmentation mechanism, continuous swin transformer blocks can be formulaic as  
\[z^{l}=W-MSA(LN(z^{l-1}))+z^{l-1} \tag{3}\]  
\[z^{l}=MLP(LN(z^{l}))+z^{l} \tag{4}\]  
\[z^{l+1}=SW-MSA(LN(z^{l}))+z^{l} \tag{5}\]  
\[z^{l+1}=MLP(LN(z^{l+1}))+z^{l+1} \tag{6}\]  
where \(z^{l-1}\) denotes the input feature matrix of the \((l-1)\)-th layer; \(z^{l}\) and \(z^{l}\) represent the intermediate and output features of the \(l\)-th layer after \(W-MSA\) and \(MLP\) operations,  
Figure 3: Schematic diagram of the plates of the Swin Transformer. Figure 2: The architecture of a Swin Transformer. respectively; \(\hat{z}^{l+1}\) and \(z^{l+1}\) are the intermediate and output features of the (\(l+1\))-th layer after \(SW-MSA\) and \(MLP\) operations; and \(LN\) stands for Layer Normalization. The Window-Based Multi-Head Self-Attention (W-MSA) serves as a core component of Transformer architecture. It reduces computational complexity by partitioning the input feature map into non-overlapping windows and computing multi-head self-attention within each window. The computational process of W-MSA is as follows:  
Suppose the size of the input feature map is \(H\times W\times C\), and it is divided into the window of \(H_{w}\times W_{w}\). The calculation formula for multi-head self-attention within each window is  
\[\text{W}-\text{MSA}(\text{Q},\text{K},\text{V})=\text{softmax}(\frac{\text{QK} ^{T}}{\sqrt{d_{k}}})\text{V} \tag{7}\]  
In self-attention mechanisms, Q (Query), K (Key), and V (Value) correspond to feature matching, similarity measurement, and information aggregation, respectively, where \(d_{k}\) denotes the key dimension for dot product scaling and the softmax function enables normalization. The Window-Based Multi-Head Self-Attention (W-MSA) controls computational complexity effectively while preserving local feature dependencies by performing attention calculations within non-overlapping local windows. As a core innovation of Swin Transformer, the Shifted Window-Based Multi-Head Self-Attention (SW-MSA) captures long-range dependencies by shifting feature windows right and down by half the window size, creating overlapping regions for cross-window pixel interaction. Although its fundamental equations align with W-MSA, the input feature map is shifted prior to computation:  
\[\frac{W}{4}\times\frac{H}{4}\times C \tag{2}\]0  
The difference lies in that the input feature map of SW-MSA undergoes a shift operation before partitioning the window, thereby achieving cross-window attention calculation. Layer Normalization (LN) is a commonly used regularization technique, which is used to accelerate training and improve the generalization ability of the model.