## 2 Materials and Methods
### Geo-Positional Transformer-CNN
#### 2.5.1 GPTransformer Branch  
As shown in Figure 3, the GPTransformer branch is built upon a modified Transformer encoder architecture with the integration of a geographic positional encoding mechanism. At large spatial scales, SOM is typically influenced by a combination of macro-environmental factors such as climate and topography, resulting in pronounced spatial heterogeneity [42]. By embedding geographic positional information into the input features, this branch enhances the model's ability to perceive global spatial heterogeneity, thereby enabling more effective capture of large-scale SOM distribution patterns and the spatial correlations among environmental covariates. The GPTransformer branch consists of one Input Embedding module, one GeoPositional Encoding module, five Transformer encoder modules, one LayerNorm layer, and one fully connected layer. The Input Embedding module is designed to project the original input environmental covariates, including topographic and bioclimatic factors, into a unified high-dimensional feature space for ensuring consistent representation across features of different sources and scales. This enhances the model's ability to capture complex nonlinear relationships among the input variables. The GeoPositional Encoding module replaces the traditional positional encoding mechanism by incorporating geographic location information into the feature variables. Specifically, the latitude values \(\theta\in\mathbb{R}^{B\times L}\) (where \(B\) denotes the batch size and \(L\) is the  
Figure 3: The architecture of the GPTransformer. Path a denotes the route through the first Transformer Encoding Block where the initial LayerNorm layer is bypassed, after which the processing continues along path b for the remaining layers; \(\oplus\) denotes element-wise addition. sequence length) are first expanded into a three-dimensional tensor \(\theta^{\prime}\in\mathbb{R}^{B\times L\times 1}\). This tensor is combined with a fixed frequency term \(P\in\mathbb{R}^{M/2}\) (where \(M\) is the feature mapping dimension of the input \(X\)) via the Kronecker product, resulting in \(\bar{\theta}\in\mathbb{R}^{B\times L\times M/2}\). The latitude feature \(\bar{\theta}\) is then transformed using sine and cosine functions to generate two sets of encoding components. These components are concatenated to produce the final latitude encoding \(E_{lat}\in\mathbb{R}^{B\times L\times M}\), as defined by the following equations:  
\[\bar{\theta}=\theta^{\prime}\otimes P \tag{1}\]  
\[\bar{\theta}_{\rm{sim}}=\sin(\bar{\theta}) \tag{2}\]  
\[\bar{\theta}_{\rm{cos}}=\cos(\bar{\theta}) \tag{3}\]  
\[E_{lat}=Concat(\bar{\theta}_{\rm{sim}},\bar{\theta}_{\rm{cos}}) \tag{4}\]  
\[E=X\oplus E_{lat}\oplus E_{lon} \tag{5}\]  
where \(\otimes\) denotes the Kronecker product, \(\oplus\) denotes element-wise addition, and \(P\) is a learnable frequency modulation matrix (initialized as an all-ones vector in this study to reduce model complexity). Longitude encoding is performed in the same manner, yielding the longitude encoding \(E_{lon}\). Subsequently, \(E_{lat}\) and \(E_{lon}\) are added to the feature vector \(X\) to obtain the final feature representation \(E\) embedded with geographic positional information, which is then used as the input for the subsequent model. The Transformer encoder module adopts the encoder architecture of the Transformer to extract global features from the input data [43]. Based on the standard architecture, appropriate modifications were made: the LayerNorm layers were moved before the Multi-Head Attention and Feed Forward layers, and the LayerNorm layer before the Multi-Head Attention in the first encoder block was removed. Previous studies have shown that removing the LayerNorm layer from the first encoder block can improve the convergence speed and representation capability of the model when the input consists of non-sequential features [44].