2.1. Preparation and Formation of a Training Geospatial Dataset
Data analysis was structured as a sequential, reproducible workflow to prepare a valid feature space for probabilistic modeling of potentially favorable groundwater distribution zones. The main objective of the data analysis stage was not only to generate a feature table but also to ensure the scientific validity of the sample: eliminating features with the risk of leakage of the target variable, quality control of initial values, checking the class structure, spatial partitioning of the data, and selecting informative variables only from the training set.
The resulting dataset is a point-sampling dataset with supervised learning designed to evaluate whether multimodal geospatial predictors can distinguish documented groundwater-related observations from spatially filtered pseudo-absence locations. Each observation is represented by 89 environmental predictors extracted from independent geospatial layers. Although the initial number of predictors is relatively large compared to the number of observations, feature selection was performed exclusively on the training data, allowing the final predictor set to be reduced to 69 variables before model development. This procedure limits model complexity while retaining only informative environmental predictors.
Table 1 presents the basic mathematical notations used to formally describe the process of generating and preparing a geospatial dataset. The notations cover the study area, spatial observation points, coordinates, target variable, feature vector, final analytical dataset, feature sets, spatial blocks, and training, validation, and test samples. This table is necessary for a consistent understanding of subsequent formulas and stages of probabilistic modeling of groundwater potential.
The initial sample was formed as a set of two types of spatial points: positive groundwater-related observations and spatially filtered pseudo-absence points. Each point is treated as a geographic observation with coordinates and a target label (1):
The target variable was defined as follows (2):
where
is the set of known or probable groundwater-related objects, and
is the set of filtered pseudo-absence points. The positive class reflects points associated with known groundwater manifestations or objects, such as springs and water wells. The negative class is not interpreted as a proven absence of groundwater. It represents spatially sampled pseudo-absence points used to construct a contrast sample in binary probability modeling. The final class structure after quality control (3):
This class ratio preserves the real imbalance between known groundwater-related objects and spatially distributed pseudo-absence points but remains suitable for training binary classification models using appropriate quality metrics. The pseudo-absence points were formed not as random points, but as a spatially filtered sample. The main principle was to eliminate obvious intersections with known positive objects and reduce the likelihood of negative points falling in close proximity to groundwater-related observations. Formally, the spatial filtering condition can be written as follows (4):
where
is a pseudo-absence point,
is the minimum distance from this point to the nearest positive observation, and
is the minimum spatial filtering buffer. This condition does not prove the absence of groundwater at pseudo-absence points but makes the negative class more appropriate for probabilistic modeling for probabilistic mapping tasks. Therefore, in what follows, the class
is treated as filtered pseudo-absence, and not as confirmed absence. For each point
, a feature vector
was formed, obtained by extracting values from a set of open geospatial layers. These layers described the topographic, hydro-topographic, climatic, soil, landscape, radar, and water-balance characteristics of the territory. The selected predictors were chosen because they represent key environmental factors influencing groundwater availability. Topographic variables describe relief configuration and runoff accumulation, climate variables characterize long-term water availability, soil properties influence infiltration and reservoir capacity, Sentinel-1 SAR data provide information on surface moisture conditions, and water balance indicators reflect regional hydrological processes. Their integration allows for a more comprehensive understanding of environmental conditions associated with groundwater potential. If we denote the set of initial spatial layers as (5):
then the feature vector for each point is defined as (6):
Thus, each row of the final table corresponds to one spatial point, and each feature column corresponds to the value of a specific geospatial layer or derived indicator at that point. The final initial analytical feature matrix had the form (7):
At this stage, it was important that the features were derived from actual source-sampled geospatial layers, not from synthetic fallback values. This increases the reproducibility and scientific validity of further analysis. After generating the source table, quality control of the observations and features was performed. At the row level, the proportion of missing values for each point was analyzed (8):
where
is the proportion of gaps in the
-th row,
is an indicator function that takes the value 1 when the condition is met and 0 otherwise. Rows with an excessive proportion of gaps were excluded from further analysis (9):
where
is the acceptable threshold for missing values at the observation level. After quality control, the final dataset contained (10):
Additionally, the proportion of omissions for each characteristic was analyzed (11):
where
is the proportion of missing values in the
k-th feature. This step allowed us to identify features with potentially low reliability, verify the missingness structure, and prepare the data for subsequent processing without distorting the target variable. One of the key requirements of the analysis was the exclusion of leakage features. Leakage is defined as variables that can directly or indirectly convey information to the model about the target variable, point identifier, coordinates, spatial block, or known groundwater-related objects. The complete set of features was divided into acceptable and unacceptable (12):
The set of features allowed for modeling was defined as (13):
The set included features potentially posing a risk of data leakage: the target variable, observation identifiers, point coordinates, spatial block identifiers, features directly associated with known groundwater/water features, distance variables to target objects, and technical fields that are not independent natural predictors. Excluding these variables is necessary to ensure that the model is trained on physically interpretable characteristics of the area, rather than on service information or technical traces of the sampling process.
To prevent overestimation of quality, spatial-block grouped partitioning was used. Each point was assigned to a spatial block
. The partitioning was performed at the spatial-block level rather than at the level of individual observations, to prevent closely located points with high spatial similarity from being included in both the training and test sets. Formally, this can be represented as follows (14):
where
is the function that assigns a point to a corresponding spatial block. The dataset was then divided into three disjoint parts (15):
subject to condition (16):
For spatial blocks, the condition of non-intersection between parts was also met (17):
The actual distribution of observations was as follows (18):
Model performance was assessed using the same type of observations, as there is no publicly available, independent, nationwide hydrogeological inventory for Kazakhstan confirming the absence or presence of groundwater. Therefore, validation was conducted on spatially independent subsets of the same dataset, obtained using point sampling, using a block partitioning into training, validation, and test sets. This protocol provides a more realistic assessment of spatial generalization than random partitioning, although it should not be interpreted as independent hydrogeological validation. All preprocessing parameters were evaluated exclusively on the training portion of
and then applied to the validation and test portions. This eliminates the transfer of information from validation/test to the training process. For numerical features, a transformation of the form (19) was used:
where
and
are the mean and standard deviation of the
-th feature, calculated using only the training set. If the feature required imputation of missing data, the imputation parameter was also calculated using only the training set (20):
where
is the imputation value determined from the training data. This processing procedure preserves the independence of the validation and test splits and complies with the leakage-safe data preparation principle. After basic data cleaning, an analysis of the feature space was performed. This included checking the distributions, differences between classes, correlation structure, and feature redundancy. For each feature
, its relationship with the target variable and stability in the training set were assessed. Generally, the informativeness of a feature can be represented as function (21):
where
is the estimate of the informativeness of the
-th feature, and Ψ(⋅) is the criterion for the relationship between the feature and the target variable, calculated only on the training data. To control for multicollinearity, the correlation between the features was analyzed (22):
If two features had an excessively high correlation, one of them could be excluded as redundant (23):
Here,
is the acceptable correlation threshold, and
is the set of features excluded due to redundancy. The final set of features was formed only during the training phase. Validation and test data were excluded from the feature-selection procedure to preserve the independence of the evaluation. The general selection principle can be written as follows (24):
After removing weak, unstable and redundant features, the final number of variables was (25):
The final feature matrix for modeling is (26):
Accordingly, the model was trained on a selected feature space that accounted for data quality, informativeness, redundancy, and leakage risk. After data preparation, the problem was reduced to binary probabilistic classification. For each point
, the model receives a feature vector
and estimates the probability of belonging to a class of potentially favorable groundwater-related conditions (27):
Here,
is not direct evidence for the presence of groundwater. It is an estimate of the probability that the natural conditions at point
are similar to those characteristic of known groundwater-related observations. The final binary decision can be obtained using the classification threshold (28):
where
is the classification threshold selected for the validation split, not the test split. Thus, the locked test split is retained only for the final independent quality assessment, not for model tuning, feature selection, or threshold selection. In a compact form, the entire data preparation process can be represented as a sequence of transformations (29):
where
is the original sample of points,
is the data after quality control,
is the data after excluding leakage features,
,
,
are spatially separated parts,
is the final matrix of 69 features for modeling. The final conceptual model of data preparation has the following form (30):
This formula reflects the main methodological principle of the work: features are first cleared of potential leakage, then processed with parameters calculated only for the train split, and only after that they undergo train-only selection.
2.2. Leakage-Safe Spatial Data Preparation Framework for Groundwater Potential Modeling
Figure 1 shows the sequential data preparation process prior to model training. The left side of the figure shows the composition of the final analytical sample: the objects of analysis are spatial points
, for which a binary target variable
and a vector of predictors
are formed. After quality control and feature selection, the final matrix
includes 69 predictors grouped into seven substantive blocks: topographic, hydrotopographic, climatic, soil, land-cover, Sentinel-1 SAR, and water-balance features. This structure reflects a physically interpretable description of the territory, rather than an arbitrary set of statistical variables. The right side of the figure shows the procedure for forming the leakage-safe sample. First, positive groundwater-related observations and filtered pseudo-absence samples are combined, after which the pseudo-absence points are spatially filtered relative to positive objects. Next, values from the actual geospatial layers are extracted for each point, forming an initial 2402 × 89 feature matrix. The following steps include gap checking, class consistency checking, and the exclusion of variables with the risk of information leakage: coordinates, identifiers, spatial block IDs, distances to target objects, and known groundwater/water indicators.
Data preprocessing to prevent leakage was conducted according to an established protocol. Before model development, metadata fields and all variables directly or indirectly related to the target object were excluded. These included unique identifiers, geographic coordinates, source labels, source credibility attributes, spatial block identifiers, water masks, direct groundwater measurements, and distance-to-target variables. Specifically, variables such as water table, groundwater depth, depth to water, well yield, discharge, pumping rate, NDWI, MNDWI, AWEI, JRC water occurrence frequency, JRC water seasonality, surface water mask, distance to source, distance to well, distance to known groundwater point, and existing groundwater potential maps were excluded from model training to prevent information leakage.
Rows containing more than 30% missing values were removed during quality control. After preprocessing, the dataset contained 2402 observations described by 89 environmental predictors. Feature selection was performed exclusively on the training set using a “training only” protocol. Pairwise correlations were assessed, highly redundant predictors exceeding a predetermined correlation threshold were removed, and the remaining variables were ranked according to their predictive contribution. The final feature set consisted of 69 predictors used in all subsequent experiments. All experiments were conducted using a fixed random number generator seed (42) to ensure reproducibility.
The key methodological element of the scheme is a spatial-block grouped split, in which the data is divided into train, validation, and test parts by spatial blocks, rather than randomly by rows. This reduces the risk of overestimating quality due to spatial autocorrelation. All preprocessing operations, information content assessment, and final feature selection are performed only on , while validation and locked test are not used to adjust the feature space. Therefore, the final matrix is passed to the modeling as a pre-cleaned, spatially controlled, and leakage-proof basis for estimating the probability .
Careful preparation of spatial observations is important because errors introduced during sampling or data pre-processing can significantly affect the reliability of groundwater potential predictions. The sequence of steps ensures traceability of the origin of each observation and each feature: from point generation and extraction of source-sampled layers to the final predictor matrix. This is necessary because, in groundwater-related occurrence suitability mapping, an error during sample preparation can lead to a greater distortion of the results than the choice of a specific classification algorithm. Excluding audit-only fields does not reduce the environmental information available to the model; instead, it prevents technical or spatial identifiers from influencing prediction. Such fields retain their value for quality assurance, data description, and reproducibility. However, these fields should not be used for model training because they may introduce spatially dependent or target-related information. Therefore, the final scheme establishes a strict boundary between the data used to document the sample and the features acceptable for prediction. This makes subsequent model comparison methods consistent and reduces the risk of overinterpreting the obtained metrics.
To further evaluate the robustness of the proposed branch selection strategy, an additional stability analysis of repeated spatial partitions was conducted using ten independent spatial partitions. The resulting branch selection frequencies, merge weights, and performance variability are presented in
Supplementary Table S1 and Figure S1, demonstrating that the HistGradientBoosting branch remained consistently active across all repeated partitions, while modality-specific branches contributed with varying frequencies depending on the spatial partition. These additional experiments further confirm the robustness of the proposed validation-guided fusion strategy.
Figure 2 shows the class balance in the final dataset, formed after constructing positive groundwater-related observations and spatially filtered pseudo-absence points. The sample contains 2402 observations: 601 points belong to the positive class and 1801 to the pseudo-absence class. Thus, the ratio of negative to positive classes is approximately 3:1.
This distribution reflects the problem’s deliberate design rather than a data preparation error. The positive class is limited to publicly available observations associated with groundwater occurrences or objects, while pseudo-absence points were generated in greater numbers to form a contrasting spatial background. The pseudo-absence class is not interpreted as a confirmed absence of groundwater; rather, it serves as a comparative category for training the probabilistic model. The presence of moderate class imbalance was taken into account in further analysis of the model quality. Therefore, for evaluation, not only accuracy but also more informative metrics for imbalanced data were used: PR-AUC, F1-score, balanced accuracy, and MCC. This avoids overinterpretation of results due to the dominant class and more accurately assesses the model’s ability to identify groundwater-related conditions.
Figure 3 shows the original structure of the observations used to form the target variable. The final sample includes three source categories: pseudo_absence, osm_spring, and osm_water_well. The largest portion consists of 1801 spatially filtered pseudo-absence points, which were used as a contrasting background for binary modeling. The positive class comprises 492 osm_spring and 109 osm_water_well objects, for a total of 601 groundwater-related observations.
This distribution demonstrates that the positive class is not homogeneous in origin: it combines two types of open groundwater-related features, springs and water wells. This enhances the substantive validity of the class, as it reflects not a single specific data source, but several categories of features associated with groundwater occurrence or use. At the same time, the figure highlights an important methodological limitation: the number of osm_water_well features is significantly smaller than that of osm_spring features, so the model should not be interpreted as a specialized well-finding model. In this study, both feature types are used to assess groundwater potential. The pseudo_absence category is considered only as a filtered comparison class and does not indicate the confirmed absence of groundwater.
The study was conducted across Kazakhstan, extending from approximately 40.0° N to 56.8° N and from 45.0° E to 88.5° E, covering an area of approximately 2.72 million km2. Kazakhstan is characterized by significant environmental heterogeneity, including vast plains, deserts, semi-deserts, steppes, foothills, and mountainous regions. Climatic conditions range from arid and semi-arid regions in the south and west to more humid continental conditions in the north and northeast, resulting in pronounced spatial variability in precipitation, temperature, evaporation, and water availability. From a hydrogeological perspective, groundwater is located in a variety of aquifer systems, including unconsolidated alluvial deposits, sedimentary basins, fractured bedrock, and mountain aquifers. Groundwater is an important source of drinking water, irrigation water, and industrial water supplies, especially in regions where surface water resources are limited or highly seasonal. The high environmental diversity and uneven spatial distribution of groundwater observations make Kazakhstan a suitable testing ground for spatially aware machine learning methods using multimodal geospatial predictors.
Figure 4 shows the geographic distribution of the final dataset points in the EPSG:4326 coordinate system. The contour delimits the study area, within which two types of observations are located: positive groundwater-related points and spatially filtered pseudo-absence points. This presentation allows visual verification that the sample covers the main analysis area and is not concentrated in isolated regions. Pseudo-absence points are distributed throughout the study area and form the spatial background necessary for comparison with positive observations. Positive points exhibit more pronounced clustering, which is expected for open data on springs and water wells: such objects are typically recorded unevenly and depend on both natural conditions and the availability of observations. Therefore, the spatial heterogeneity of the positive class was taken into account in subsequent stages through spatial block partitioning.
The figure also confirms that the analysis was performed on real coordinate objects, not on an abstract tabular sample. However, the coordinates themselves were used to construct the sample, control the spatial structure, and visualize it, but were not included in the final set of predictors. This reduces the risk of spatial leakage and ensures that subsequent modeling is focused on the natural features of the area, rather than on the direct memorization of point locations.
The proposed framework is based on multimodal geospatial datasets representing topographic, climate, hydrological, soil, land-use, and radar information. Because these datasets were obtained from different providers and have different spatial and temporal characteristics, they were harmonized prior to feature extraction.
Table 2 provides a summary of the geospatial datasets used in this study, including their source, temporal coverage, spatial resolution, preprocessing procedure, missing value handling, license, and role in the proposed framework.
All raster data were resampled to a common working resolution of 250 m before feature extraction. Predictor values were extracted only at observation sites, resulting in a feature table with point sampling. Missing values were estimated separately for each predictor and imputed exclusively using statistics obtained from the training set to prevent information leakage. All spatial datasets were processed in the EPSG:4326 coordinate system.
2.3. Study of Distributions and Information Content of Feature Space
Table 3 presents descriptive statistics for the first thirty features used in the initial analysis of the data structure. These variables belong to three key groups of factors: topography, hydrotopography, and climate. For each feature, the number of available observations, mean, standard deviation, minimum, quartile values, and maximum are shown. This table was used to control ranges, identify missing values, assess feature dispersion, and check the physical plausibility of values prior to model training.
Therefore, this table represents a fragment of the overall feature statistics, not a complete list of all variables in the dataset. The full original feature space contained 89 features, and after train-only selection, 69 features were used for modeling.
Figure 5 shows the distribution histograms of six numerical features selected for the initial validation of the data structure: elevation, slope, annual_precipitation_mean, VV_VH_ratio, annual_ET, and mean_clay_0_60 cm. These variables reflect different groups of factors—topography, climate, radar response, water balance, and soil characteristics so their joint analysis allows us to assess the heterogeneity of the feature space before model training.
The elevation and slope distributions exhibit a pronounced right-hand asymmetry: most observations are located in relatively low-lying, gently sloping areas. At the same time, isolated high-altitude and steeper areas are also present. A similar asymmetry is observed for annual_ET, indicating heterogeneity in evaporation conditions and water balance. The annual_precipitation_mean feature exhibits a multimodal distribution, reflecting the territory’s climatic heterogeneity and differences between drier and wetter zones. The VV_VH_ratio distribution appears more compact and closer to unimodal, indicating a relatively stable range of Sentinel-1 radar ratios in the sample. The soil indicator mean_clay_0_60 cm also shows a pronounced central range but retains sufficient variability to describe soil water-retention properties. Taken together, the figure confirms that the features have different scales, distribution shapes, and degrees of skewness, so supervised preprocessing procedures were required before modeling, including handling missing values, scaling, and selecting informative variables for training.
Figure 6 presents boxplots of six numerical features for the Pseudo-Absence and Positive classes. This visualization was used for an initial assessment of whether conditions at groundwater-related observation points differ from those of the spatially filtered background class before model training.
The elevation, slope, annual_precipitation_mean, and annual_ET features show that the positive class is, on average, biased toward higher values. This indicates that known groundwater-related points are more often associated with areas where topography, climatic moisture, and water balance differ from the conditions observed in most pseudo-absence locations. Differences are particularly noticeable for precipitation and evapotranspiration: the medians of the positive class are higher, and the interquartile ranges show a more pronounced concentration in relatively moist conditions. For VV_VH_ratio, the opposite pattern is observed: the positive class has a lower median compared to pseudo-absence. This may reflect differences in the surface radar response associated with cover type, landscape structure, or moisture conditions. The soil indicator mean_clay_0_60 cm shows partial overlap between classes but retains differences in ranges and outliers, indicating its potential additional information content. The presence of outliers in both classes was not considered an error in itself, as geospatial features naturally exhibit high spatial heterogeneity. The figure confirms that the selected variables contain a discriminatory signal between classes, but no single feature alone provides complete separation. Therefore, further modeling was based on a multi-feature approach, in which the final probability is derived from the combined use of topographic, climatic, SAR, soil, and water-balance factors.
Figure 7 shows the annotated Pearson correlation matrix for the group of most informative features identified during the preliminary analysis.
The matrix was used to assess linear relationships among variables and to identify potential redundancies in the feature space before final predictor selection. The most pronounced positive correlations are observed within homogeneous groups of features. The Sentinel-1 SAR metrics VH_mean, dry_season_VH, wet_season_VH, VV_mean, and dry_season_VV are strongly correlated, reflecting the similar nature of radar seasonal characteristics. Similarly, the climate metrics wet_season_precipitation, annual_precipitation_mean, and spring_precipitation exhibit high positive correlations, as they describe related components of the precipitation regime. The topographic metrics local_relief and slope are also highly correlated, as expected for areas with pronounced relief discontinuities.
Negative correlations are particularly evident for deficit_severity_index, which shows inverse relationships with precipitation variables and several SAR/terrain metrics. This is logical, as increasing climate deficits are typically contrasted with higher moisture conditions. The VV_VH_ratio feature also shows negative correlations with most SAR indices and moderate inverse correlations with climate variables, indicating its independent role relative to absolute VV/VH values. Thus, the figure confirms the presence of both informative relationships and partial multicollinearity between the predictors. Therefore, subsequent train-only feature selection was necessary to preserve the useful signal while simultaneously removing weak or redundant variables.
Figure 8 shows the annotated matrix of normalized nonlinear signal relationships between the selected features and the target variable. The evaluation was performed using three tree-based approaches: Extra Trees, Random Forest, and permutation-based evaluation for HistGradientBoosting. The cell values are normalized from 0 to 1 within each column, so the figure reflects the relative importance of the features within the respective method rather than the absolute magnitude of the effect. The most consistent signal is observed for the SAR features VH_mean, dry_season_VH, and wet_season_VH. These variables rank among the top in several models, indicating their strong ability to distinguish between positive groundwater-related points and pseudo-absence observations in the multi-feature space. Climate indicators, especially wet_season_precipitation, annual_precipitation_mean, and spring_precipitation, also demonstrate a significant relationship with the target class, consistent with the hydrological role of the moisture regime. The VV_VH_ratio feature shows a particularly high signal in the HistGradientBoosting permutation estimate, indicating its independent informativeness when accounting for nonlinear interactions.
In contrast, deficit_severity_index, dry_season_VV, and roughness have low values in most columns, so their individual contribution to the feature group under consideration is limited. Thus, the figure confirms that a single factor does not drive the strongest relationship with the target variable; rather, a combination of SAR, climatic, and individual topographic features does. The results show that groundwater-related observations are influenced by multiple interacting environmental factors rather than any single factor, highlighting the importance of integrating climate, elevation, radar and soil information to assess regional groundwater potential.
Figure 9 shows the annotated mutual information matrix for the group of features that demonstrated the strongest relationship with the target variable. Unlike correlation analysis, mutual information was used to identify not only linear but also more complex nonlinear relationships between individual predictors and the target class. The values in the figure reflect the information contribution of each feature to distinguish between positive groundwater-related points and pseudo-absence observations.
The highest mutual information values were obtained for the climatic features wet_season_precipitation (0.225), annual_precipitation_mean (0.221), and spring_precipitation (0.202). This demonstrates that the moisture regime and seasonal precipitation distribution contain the most pronounced individual signal relative to the target class. High values are also observed for deficit_severity_index (0.201) and aridity_index (0.194), which further confirms the importance of climatic water deficit and aridity in assessing groundwater potential.
Among the radar features, VH_mean (0.189), dry_season_VH (0.180), and wet_season_VH (0.176) have a significant contribution, indicating the informativeness of Sentinel-1 SAR indicators as a supplement to climatic factors. The topographic features local_relief (0.176) and roughness (0.174) demonstrate a moderate but stable relationship with the target variable. The features snow_storage_proxy and warm_season_temperature, with values of 0.173, are also included in the group of informative factors, although their contribution is lower than that of the leading precipitation-related variables. Thus, the figure demonstrates that the strongest individual signal is formed primarily by climatic and water-balance characteristics, while SAR and terrain indicators play a supporting but substantively important role. These results were used as part of a train-only analysis of feature informativeness and confirmed the feasibility of subsequent multi-feature modeling.