A pmf-random forest coupled soil heavy metal tracing and dynamic evolution early warning method and system

A soil heavy metal source tracing and dynamic evolution early warning system was constructed by using the PMF-random forest coupling method. This system solved the problems of multi-source and dynamic changes of soil heavy metal pollution, and realized the refined identification of pollution sources and dynamic risk early warning.

CN123180459APending Publication Date: 2026-11-27HUBEI PROVINCIAL ACADEMY OF ECO-ENVIRONMENTAL SCIENCES(PROVINCIAL ECOLOGICAL ENVIRONMENT ENGINEERING ASSESSMENT CENTER)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611575309.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-12
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

Existing technologies are insufficient to accurately analyze the multi-source, spatiotemporal heterogeneity, and dynamic changes of heavy metal pollution in soil, and cannot effectively reveal the dynamic response relationship between pollution sources and changes in soil heavy metal concentrations.

Method used

The PMF-random forest coupling method is adopted. By constructing a spatiotemporal database of soil heavy metals, the pollution source factors are analyzed by using the positive definite matrix factorization PMF model. The nonlinear mapping relationship between the changes in pollution source contribution and the changes in soil heavy metal concentration is established by combining the random forest prediction model. A dynamic evolution model is constructed and risk warning is carried out.

Benefits of technology

It enables refined identification of soil heavy metal pollution sources, improves the accuracy of pollution evolution prediction and the timeliness of risk warning, and allows for dynamic analysis of soil heavy metal pollution processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123180459A_ABST
    Figure CN123180459A_ABST
Patent Text Reader

Abstract

The application provides a PMF-random forest coupling soil heavy metal source tracing and dynamic evolution early warning method and system, and the method comprises the following steps: obtaining target domain multi-source environmental monitoring data, decomposing a heavy metal concentration matrix and an uncertainty matrix by using a PMF model; constructing a random forest training sample set; constructing a PMF-constrained random forest prediction model, and outputting soil heavy metal concentration of the target area in a future time scale; calculating concentration change trend, pollution source contribution change trend and different pollution medium migration response relationship, and constructing a soil heavy metal dynamic evolution model; and constructing a risk early warning model, and outputting dynamic early warning results. The application introduces the characteristics of the pollution source into the random forest model by constructing a soil heavy metal space-time database and analyzing the pollution source by using the PMF, combines the prediction results, the pollution source contribution change trend and the medium migration response relationship to construct the dynamic evolution model, and improves the source tracing accuracy, the pollution evolution prediction reliability and the early warning timeliness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of soil heavy metal pollution prevention and control technology, and in particular to a PMF-random forest coupled method and system for tracing the source and dynamic evolution of soil heavy metals. Background Technology

[0002] With the continuous development of industrialization, urbanization, and agricultural production activities, the problem of heavy metal accumulation in the soil environment has become increasingly prominent. Heavy metals are characterized by their reluctance to degrade, easy accumulation, and ability to migrate through the food chain, posing a potential impact on ecosystem stability and agricultural product safety. Currently, pollution monitoring for soil heavy metal pollution typically employs methods such as on-site sampling analysis, pollution index assessment, and spatial distribution analysis. However, soil heavy metal pollution is influenced by multiple factors, including industrial emissions, agricultural fertilization, atmospheric deposition, transportation, and natural geological background. Pollution sources are multi-source, spatiotemporally heterogeneous, and dynamically changing. Traditional monitoring methods struggle to accurately analyze the contribution levels of different pollution sources and reveal the dynamic response relationship between pollution sources and changes in soil heavy metal concentrations. Summary of the Invention

[0003] This invention aims to at least solve the technical problems existing in the prior art, and innovatively proposes a PMF-random forest coupled method and system for tracing the source and dynamic evolution of heavy metals in soil.

[0004] To achieve the above-mentioned objectives of this invention, this invention provides a PMF-random forest coupled method for source tracing and dynamic evolution early warning of heavy metals in soil, the method comprising: S1. Acquire multi-source environmental monitoring data of the target area, and perform time-scale unification, spatial gridding and data fusion processing on the multi-source environmental monitoring data to construct a soil heavy metal spatiotemporal database; the soil heavy metal spatiotemporal database includes soil heavy metal concentration data, atmospheric deposition data, sediment data, agricultural product data, spatial location data and environmental driving factors. S2. Based on the spatiotemporal database of soil heavy metals, a heavy metal concentration matrix and a corresponding uncertainty matrix are constructed. The heavy metal concentration matrix is ​​decomposed using the positive definite matrix factorization (PMF) model to obtain source spectrum information and source contribution information corresponding to multiple pollution source factors. Among them, the source spectrum information is used to characterize the heavy metal element composition characteristics in each pollution source factor and to determine the corresponding pollution source type based on the heavy metal element composition characteristics. The source contribution information is used to characterize the contribution intensity of each pollution source factor at different spatial locations and time scales. S3. Based on source spectrum information and source contribution information, construct pollution source characteristic parameters, integrate pollution source type, pollution source contribution intensity with environmental driving factors and historical heavy metal concentration data in the soil heavy metal spatiotemporal database, and construct a random forest training sample set. S4. Based on the random forest training sample set, a PMF-constrained random forest prediction model is constructed. By using the pollution source characteristic parameters as input features of the random forest model, the PMF-constrained random forest prediction model establishes a nonlinear mapping relationship between the changes in pollution source contribution, the changes in environmental driving factors, and the changes in soil heavy metal concentration, and outputs the predicted results of soil heavy metal concentration in the target area at future time scales. S5. Based on the predicted soil heavy metal concentration, source contribution information and historical monitoring data, calculate the trend of soil heavy metal concentration change, the trend of pollution source contribution change and the migration response relationship between different pollution media, and construct a dynamic evolution model of soil heavy metals to obtain the evolution characteristics of soil heavy metal pollution in the target area. S6. Construct a source-concentration-trend coupled risk early warning model based on the evolution characteristics of soil heavy metal pollution. Determine the risk level based on the current concentration of soil heavy metals, the predicted change trend, and the change rate of pollution source contribution, and output the dynamic early warning results of soil heavy metals in the target area.

[0005] In another aspect, the present invention also provides a PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning system, characterized in that the system includes a processor and a memory for storing processor-executable instructions; wherein the processor is configured to implement the PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning method when executing the executable instructions.

[0006] The beneficial effects of this invention are as follows: By constructing a spatiotemporal database of heavy metals in soil and utilizing a positive definite matrix factorization (PMF) model to analyze pollution sources from multi-source environmental monitoring data, this invention obtains source spectrum information and source contribution information of different pollution source factors, achieving refined identification of soil heavy metal pollution sources. Furthermore, by constructing pollution source type and pollution source contribution intensity as pollution source characteristic parameters and introducing a random forest prediction model, a PMF-constrained random forest prediction model is formed. This model can simultaneously consider the nonlinear relationship between pollution source information, changes in environmental driving factors, and changes in soil heavy metal concentration, improving the accuracy of soil heavy metal concentration prediction and the ability to explain pollution sources. Simultaneously, by combining the soil heavy metal concentration prediction results, the trend of pollution source contribution changes, and the migration response relationship between different pollution media, a dynamic evolution model of soil heavy metals is constructed, enabling dynamic analysis of the evolution process of soil heavy metal pollution. Furthermore, based on the current pollution level, future trends, and the rate of change of pollution source contribution, a source-concentration-trend coupled risk early warning model is constructed, realizing the transformation from traditional static pollution assessment to dynamic risk early warning. Therefore, this invention can improve the accuracy of soil heavy metal pollution source tracing, the reliability of pollution evolution prediction, and the timeliness of risk early warning.

[0007] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description

[0008] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a flowchart of a PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning method according to the present invention. Detailed Implementation

[0009] Embodiments of the present invention are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0010] Example 1 like Figure 1 As shown, a PMF-random forest coupled method for source tracing and dynamic evolution early warning of soil heavy metals includes: S1. Acquire multi-source environmental monitoring data of the target area, and perform time-scale unification, spatial gridding and data fusion processing on the multi-source environmental monitoring data to construct a soil heavy metal spatiotemporal database; the soil heavy metal spatiotemporal database includes soil heavy metal concentration data, atmospheric deposition data, sediment data, agricultural product data, spatial location data and environmental driving factors. In this embodiment, the multi-source environmental monitoring data includes soil heavy metal concentration data, atmospheric deposition data, sediment data, agricultural product data, spatial location data, and environmental driving factors. Specifically, soil heavy metal concentration data can be obtained by gridding sampling points within the target area according to different land use types, soil types, and the distribution of potential pollution sources, and then measuring the heavy metal content of the collected soil samples; atmospheric deposition data can be obtained by setting up several dry and wet atmospheric deposition sampling points within the target area, periodically collecting deposition samples, and measuring their heavy metal content; sediment data can be obtained by collecting surface sediment samples from major rivers, lakes, and reservoirs in the target area and measuring their heavy metal content; agricultural product data can be obtained by collecting edible samples of major crops within the target area and measuring their heavy metal content; spatial location data includes the latitude, longitude, elevation, and administrative division of the sampling points; environmental driving factors include meteorological data, topographic data, soil physicochemical property data, land use data, population density data, industrial enterprise distribution data, and road distribution data.

[0011] Time scale unification processing includes unifying the original time resolution of different monitoring data to a target time scale. For example, for high-frequency monitoring data, methods such as arithmetic mean, cumulative summation, or extreme values ​​can be used to aggregate the data to a monthly, quarterly, or annual scale; for data with low time resolution or missing data, methods such as linear interpolation, time series trend interpolation, or imputation using the mean of adjacent time periods can be used to complete the data, ensuring that all types of environmental monitoring data are aligned at the same time scale.

[0012] Spatial gridding processing includes: determining the grid resolution based on the target area, spatial heterogeneity, and monitoring point density, dividing the target area into regular grids; assigning each monitoring point's data to its corresponding grid according to its spatial coordinates, and averaging or weighted aggregation of multiple monitoring point data within the same grid; for grids without monitoring point coverage, spatial estimation can be performed using Kriging interpolation, inverse distance weighted interpolation, spline interpolation, or a spatial matching method combining land use and pollution source distribution, thereby forming spatially continuous grid data covering the entire target area.

[0013] Data fusion processing includes: unifying coordinate systems and data units for multi-source environmental monitoring data, identifying and removing outliers, imputing missing values, and matching and correlating multi-source data. Outliers can be identified by setting reasonable concentration ranges for each heavy metal element or using statistical anomaly detection methods, and confirmed outliers are removed or corrected. Missing values ​​can be imputed based on the time-series characteristics of historical data from the same location or spatial interpolation results from adjacent grids. Finally, using spatial location and time identifiers as the primary keys, soil heavy metal concentrations, atmospheric deposition, sediment, agricultural products, and various environmental driving factors are matched and fused to construct a soil heavy metal spatiotemporal database with unified spatiotemporal identifiers.

[0014] S2. Based on the spatiotemporal database of soil heavy metals, a heavy metal concentration matrix and a corresponding uncertainty matrix are constructed. The heavy metal concentration matrix is ​​decomposed using the positive definite matrix factorization (PMF) model to obtain source spectrum information and source contribution information corresponding to multiple pollution source factors. Among them, the source spectrum information is used to characterize the heavy metal element composition characteristics in each pollution source factor and to determine the corresponding pollution source type based on the heavy metal element composition characteristics. The source contribution information is used to characterize the contribution intensity of each pollution source factor at different spatial locations and time scales. S3. Based on source spectrum information and source contribution information, construct pollution source characteristic parameters, integrate pollution source type, pollution source contribution intensity with environmental driving factors and historical heavy metal concentration data in the soil heavy metal spatiotemporal database, and construct a random forest training sample set. S4. Based on the random forest training sample set, a PMF-constrained random forest prediction model is constructed. By using the pollution source characteristic parameters as input features of the random forest model, the PMF-constrained random forest prediction model establishes a nonlinear mapping relationship between the changes in pollution source contribution, the changes in environmental driving factors, and the changes in soil heavy metal concentration, and outputs the predicted results of soil heavy metal concentration in the target area at future time scales. S5. Based on the predicted results of soil heavy metal concentration, source contribution information and historical monitoring data, calculate the trend of soil heavy metal concentration change, the trend of pollution source contribution change and the migration response relationship between different pollution media, and construct a dynamic evolution model of soil heavy metal to obtain the evolution characteristics of soil heavy metal pollution in the target area. S6. Construct a source-concentration-trend coupled risk early warning model based on the evolution characteristics of soil heavy metal pollution. Determine the risk level based on the current concentration of soil heavy metals, the predicted change trend, and the change rate of pollution source contribution, and output the dynamic early warning results of soil heavy metals in the target area.

[0015] Optionally, obtaining source spectrum information and source contribution information corresponding to multiple pollution source factors in step S2 includes: S201. Based on the soil heavy metal spatiotemporal database, extract soil heavy metal concentration data at different spatial locations and time scales within the target area, and arrange them according to spatial location, time information, and heavy metal element type to construct a heavy metal concentration matrix; wherein, the row elements in the heavy metal concentration matrix represent soil heavy metal samples corresponding to different spatial locations and time scales, the column elements represent different heavy metal elements, and the matrix elements represent the heavy metal concentration values ​​at the corresponding spatial locations and time scales. In step S201, the heavy metal concentration data of the target area extracted from the soil heavy metal spatiotemporal database has been organized according to a unified spatial grid and time scale. Therefore, each row of samples can be determined by a spatial grid identifier and a time identifier. Specifically, the soil heavy metal concentration monitoring records of each spatial grid in the target area at each time node can be treated as an independent sample, arranged sequentially according to the spatial grid number and then the time sequence to form the rows of a matrix. The columns of the matrix correspond to the actual monitored heavy metal elements such as cadmium, mercury, arsenic, lead, chromium, copper, zinc, and nickel. The matrix elements are the measured concentration values ​​of the corresponding elements in the sample, usually measured in mg / kg. For element monitoring values ​​missing at a certain time node for a certain spatial grid, a missing mark is made in the matrix, and the reliability is subsequently characterized by an uncertainty matrix and used for processing by the PMF model. The heavy metal concentration matrix constructed in the above manner can systematically reflect the distribution characteristics of soil heavy metal concentration in the target area with spatial location and time.

[0016] S202. Based on the data detection error, detection limit, and concentration change characteristics of heavy metal concentration data, calculate the uncertainty corresponding to each heavy metal element, and construct an uncertainty matrix that matches the heavy metal concentration matrix; wherein, the uncertainty matrix is ​​used to characterize the reliability of each heavy metal concentration data in the heavy metal concentration matrix. The uncertainty matrix maintains a row-column correspondence with the heavy metal concentration matrix, with each matrix element characterizing the reliability of the corresponding heavy metal element concentration data in the same sample. For concentration data above the detection limit, the uncertainty can be determined by combining the data detection error and concentration variation characteristics, according to the synthesis method of measurement error and detection limit. For example, the uncertainty calculation formula U=√((a×C)2+(b×L)2) can be used for estimation, where C is the heavy metal concentration value, L is the detection limit of the corresponding heavy metal element, a is the relative error coefficient, and b is the detection limit coefficient, which can be determined based on laboratory quality control data, instrument accuracy, and method validation results. For concentration data below the detection limit or missing data, the concentration matrix can be filled with 1 / 2 of the detection limit or other preset substitution values, and the corresponding uncertainty can be set to a corresponding multiple of the detection limit or directly assigned a large value to reduce the interference of low-quality data on the PMF model decomposition results. When multiple monitoring points exist within the same grid and time scale, the aggregated concentration values ​​can be used as matrix elements based on the data aggregation processing in S201. The corresponding uncertainty is determined according to the dispersion between monitoring points or the errors introduced during aggregation. Simultaneously, for heavy metal elements with large concentration fluctuations within the same spatial grid or time series, the uncertainty can be adjusted based on their coefficient of variation or the deviation from repeated measurements, ensuring that the uncertainty reflects the temporal or spatial instability of the data. The uncertainty matrix constructed in this way serves as the weight input to the PMF model, participating in the iterative minimization of the objective function. This reduces the contribution weight of high-uncertainty data in the model decomposition process, thereby improving the robustness and reliability of the pollution source apportionment results.

[0017] S203. Input the heavy metal concentration matrix and uncertainty matrix into the positive definite matrix factorization (PMF) model. Perform non-negative matrix decomposition on the heavy metal concentration matrix through the positive definite matrix factorization (PMF) model to establish the mapping relationship between pollution source factors and heavy metal elements, and obtain the initial source spectrum information and initial source contribution information corresponding to multiple pollution source factors. In the PMF model solution process, the heavy metal concentration matrix X and uncertainty matrix U are first standardized to eliminate the influence of differences in concentration magnitudes among different heavy metal elements on the decomposition results. Then, the number of pollution source factors p is set, and the source spectrum matrix F and source contribution matrix G are non-negatively initialized. Initialization methods can include random non-negative initialization, eigenvector initialization based on principal component analysis, or constraint initialization based on prior source spectrum information to accelerate model convergence and improve solution stability. In the iterative solution phase, optimization algorithms such as alternating least squares or conjugate gradient methods are used. While maintaining the non-negativity of G and F, one matrix is ​​alternately fixed while the other is updated, gradually reducing the weighted sum of squared residuals Q. In each iteration, missing values ​​or data below the detection limit in the concentration matrix are assigned smaller weights based on their corresponding uncertainties, or substitute values ​​from the detection limit are used when calculating the residuals, thereby reducing their interference with the decomposition results. The iterative process continues until the relative change in the Q value is less than the preset convergence threshold, or the maximum number of iterations is reached. After convergence, G and F are obtained as the initial source contribution matrix and the initial source spectrum matrix, respectively. Subsequently, the columns of the source spectrum matrix F are normalized to make the elemental composition characteristics of each source spectrum factor easier to interpret. Finally, by comparing the relative proportions of characteristic elements in the source spectrum with the characteristic spectra of known pollution sources, the pollution source type of each pollution source factor is determined, such as industrial emission sources, agricultural non-point sources, transportation sources, or natural parent material sources; meanwhile, the source contribution matrix G reflects the contribution intensity of different pollution sources in each sample.

[0018] S204. Based on the initial source spectrum information, initial source contribution information, and fitting results of the heavy metal concentration matrix, the number of different pollution source factors is iteratively calculated. The optimal number of pollution source factors is determined according to the model fitting degree, residual change characteristics, and the rationality of the pollution source factor interpretation. The source spectrum information and source contribution information corresponding to the optimized pollution source factors are obtained.

[0019] First, based on the prior number of potential pollution source types in the target area and the feasibility of PMF model decomposition, a candidate range for the number of pollution source factors p is set, typically starting with a smaller value and gradually increasing. For each candidate number of factors, the decomposition process from S201 to S203 is repeated, recording the corresponding weighted sum of squared residuals Q, explained variance, residual distribution characteristics, source spectrum, and source contribution results. Regarding model fit, the decrease in Q value under different numbers of factors is compared, and the ratio of Q to the theoretical expected value is used to determine whether the model is overfitting or underfitting. When the number of factors increases, the Q value usually continues to decrease, but if the decrease slows significantly, further increasing the number of factors has limited effect on improving the fit. Regarding residual variation characteristics, it is checked whether the residuals of each heavy metal element are approximately randomly distributed and the values ​​are mainly concentrated in a small range. If the residuals show systematic bias or the residuals of some elements are consistently large, it indicates that the current number of factors cannot effectively explain the changes of the corresponding elements. Regarding the reasonableness of the pollution source factors' interpretation, the relative contributions of each heavy metal element in the source spectrum are considered to determine whether each factor corresponds to a known pollution source type within the target area. Simultaneously, the spatiotemporal distribution characteristics of the source contributions are analyzed to verify whether there is a spatial and temporal correlation with prior information such as the distribution of industrial enterprises, main traffic arteries, agricultural land, or natural parent material. Based on these indicators, the optimal number of pollution source factors is selected based on a gradual decrease in Q-value, no significant structural features in the residuals, strong interpretability of the source spectrum, and a reasonable spatiotemporal distribution of source contributions. When multiple candidate factor numbers show similar fitting effects, the option with fewer factors and better interpretability is prioritized to reduce model complexity and avoid redundant factors. After determining the optimal number of factors, the corresponding source spectrum matrix and source contribution matrix are used as optimized source spectrum and source contribution information for subsequent pollution source feature parameter construction and prediction model training.

[0020] Optionally, constructing the random forest training sample set in step S3 includes: S301. Based on source spectrum information, analyze the composition characteristics of different heavy metal elements in each pollution source factor, identify the pollution source type corresponding to each pollution source factor according to the composition characteristics of heavy metal elements, and establish the correspondence between pollution source factors and pollution source types. The normalized concentrations or relative contributions of heavy metal elements corresponding to each pollution source factor are extracted from the optimized source spectrum information to eliminate the influence of absolute concentration differences between different source spectra on type identification. For each pollution source factor, the dominant elements and characteristic element combinations can be identified by sorting the relative contributions of each heavy metal element from high to low. For example, if the relative contributions of cadmium, lead, and zinc in a certain factor are significantly higher than those of other elements, and are consistent with the emission characteristics of typical non-ferrous metal smelting, electroplating, or chemical industries in the target area, it can be identified as an industrial emission source; if the relative contributions of elements such as arsenic, copper, and chromium in a certain factor are relatively prominent, and their spatial distribution has a good correspondence with concentrated agricultural land areas, historical pesticide application areas, or livestock and poultry breeding areas, it can be identified as an agricultural non-point source; if the combination characteristics of elements such as lead, zinc, and copper in a certain factor are obvious, and the high-value areas of the source contribution are distributed along major traffic arteries, it can be identified as a traffic source; if a factor is dominated by elements such as nickel, chromium, and arsenic, and the high-value areas are consistent with the regional geological background or parent material type, it can be identified as a natural parent material source. To further improve the reliability of type identification, existing pollution source fingerprint spectra in the target area or characteristic spectra of similar pollution sources reported in the literature can be introduced as references. Similarity coefficients between the source spectrum and the reference spectrum, such as Pearson correlation coefficient, cosine similarity, or Euclidean distance, can be calculated. The reference pollution source type with the highest similarity and meeting a preset threshold is used as the type label for that factor. When the elemental composition of a factor has high similarity to multiple pollution sources, a comprehensive judgment should be made by combining the spatial distribution and temporal variation characteristics of source contributions with regional pollution source survey data to avoid misjudgment based solely on elemental composition. For factors that cannot be clearly classified, they can be marked as mixed sources or undetermined sources, and further identified in subsequent analyses by combining other auxiliary information. Based on this, a correspondence between pollution source factor numbers, pollution source types, and main characteristic elements is established, forming pollution source type labels for subsequent random forest modeling.

[0021] S302. Based on source contribution information, extract the contribution intensity of each pollution source factor at different spatial locations and time scales, and associate the contribution intensity with the corresponding pollution source type based on the correspondence relationship to obtain pollution source contribution intensity information at different spatial locations and time scales. The contribution values ​​of each pollution source factor for each sample can be directly read from the optimized source contribution matrix. The rows of the source contribution matrix correspond one-to-one with the rows of the heavy metal concentration matrix. Each row represents a soil sample determined by both spatial grid identifiers and temporal identifiers. Each column represents a pollution source factor, and the matrix elements represent the contribution intensity of that factor to the sample. The unit is the same as that in the heavy metal concentration matrix, typically mg per kg. To facilitate comparisons between different samples and subsequent feature input, the relative contribution rate of each factor to each sample can be further calculated. This involves dividing the contribution value of a factor by the sum of the contribution values ​​of all factors in that sample to obtain the percentage contribution of that factor in that sample. Alternatively, the contribution values ​​can be converted to concentration units or retained in their original units as needed for analysis. Based on this, according to the correspondence between pollution source factors and pollution source types established in S301, the factor number in each column is replaced with the corresponding pollution source type label. When multiple factors are identified as belonging to the same pollution source type, the contribution values ​​of each factor under the same type can be summed or weighted to obtain the comprehensive contribution intensity of that pollution source type in the sample. If it is necessary to distinguish different subclasses or different main contribution pathways of the same type, factor-level information can also be retained and used as multiple independent feature inputs in subsequent modeling. After the above processing, a structured data table with spatial location identifier, time identifier, pollution source type, and contribution intensity as fields can be formed, where each row corresponds to the contribution intensity information of a sample on each pollution source type. For factors with low contribution intensity that may be caused by model decomposition noise, a cutoff threshold can be set in combination with uncertainty or contribution significance tests to set contribution values ​​below the threshold to zero or mark them as insignificant, so as to reduce the interference of invalid features on the training of the random forest model. The pollution source contribution intensity information obtained in this way at different spatial locations and time scales can be directly used to construct the random forest training sample set in step S3.

[0022] S303. Construct pollution source characteristic parameters based on pollution source type and pollution source contribution intensity information, wherein the pollution source type is feature-encoded and the pollution source contribution intensity information is used as pollution source contribution features to form pollution source characteristic parameters used to characterize the pollution source impact features. When encoding pollution source types, the number of pollution source types identified in the target area can be used to convert each pollution source type into a numerical category feature using one-hot encoding. For example, if four types of pollution sources are identified in the target area—industrial emission sources, agricultural non-point sources, transportation sources, and natural parent material sources—four binary features are generated. Each sample takes a value of 1 on the feature corresponding to its pollution source type, and 0 on the others. If the same sample is affected by multiple pollution sources simultaneously, it can be marked as 1 on the feature corresponding to each pollution source type to reflect the fact that the sample is affected by multiple sources. For factors identified as mixed sources or undetermined sources, they can be encoded as a separate type, or retained or removed in the subsequent feature screening stage based on the importance assessment results. Regarding pollution source contribution features, the contribution intensity information of each pollution source type obtained in S302 can be converted into continuous features for each sample, including at least the contribution concentration, relative contribution rate, and spatiotemporal variation features of the contribution intensity of each pollution source type. The contribution concentration feature directly uses the contribution value of each pollution source type under the current spatial grid and time scale, with units consistent with heavy metal concentration. The relative contribution rate feature is calculated by dividing the contribution value by the sum of the contribution values ​​of all pollution sources in the same sample, to eliminate the influence of the total concentration difference between different samples on the model input. The spatiotemporal variation feature can be based on the contribution sequence of the same spatial grid at multiple continuous time scales, calculating the amount and rate of change of contribution value between adjacent time nodes, or using a sliding window to statistically analyze the mean and standard deviation of contribution intensity to reflect the dynamic evolution trend of pollution source contribution. For the above continuous contribution features, standardization or normalization can be performed first to match them in magnitude with the environmental driving factor features of subsequent inputs. After concatenating the category coding features with the continuous contribution features, the pollution source feature vector corresponding to each sample can be formed. To avoid the model training efficiency decreasing or overfitting due to too many feature dimensions, correlation analysis and importance pre-screening can be performed on the contribution features to remove features that are highly correlated with other features and have weak predictive ability, or methods such as principal component analysis can be used to reduce the dimensionality of high-dimensional features. The final pollution source characteristic parameters are fused with the environmental driving factors and historical heavy metal concentration data described in S3 to form the input features of the random forest training sample set, while the output variable is the predicted value of soil heavy metal concentration for the corresponding sample at future time scales.

[0023] S304. Match and fuse the pollution source characteristic parameters with the environmental driving factors in the soil heavy metal spatiotemporal database according to the corresponding spatial location and time scale, and use the historical heavy metal concentration data under the corresponding spatial location and time scale as training labels to construct a random forest training sample set containing pollution source characteristic parameters, environmental driving factors and historical heavy metal concentration data.

[0024] Using a unified spatial grid identifier and temporal identifier as the primary key, the pollution source characteristic parameters constructed in S303 are aligned with the environmental driving factors in the spatiotemporal database of soil heavy metals. Environmental driving factors can include multi-source data such as soil physicochemical properties, climate and meteorology, topography, land use types, industrial enterprise distribution, transportation networks, and agricultural management measures. Before matching, each factor should be unified to the same spatial grid and temporal node as the pollution source characteristic parameters. For environmental driving factors with inconsistent temporal resolution, the temporal scale unification method in S1 can be used, employing time-weighted averaging, nearest-neighbor matching, or linear interpolation to aggregate them to a unified time node. For factors with inconsistent spatial resolution, the target grid is used as the reference, and they are unified to the same spatial grid through area-weighted averaging, spatial interpolation, or nearest-neighbor matching. During the matching process, the complete spatial location and temporal identifiers of each sample should be preserved to avoid misalignment of features between different time nodes or different grids. For missing environmental driving factors at individual grids or time points, methods such as the mean of adjacent grids, the mean of the same historical period, or moving window interpolation are preferentially used to fill in the missing factors. The source of the missing factors can be used as an additional identifier so that it can be weighted or filtered in conjunction with data quality information during subsequent random forest model training. In terms of training label construction, historical heavy metal concentration data at the corresponding spatial location and time scale are used as the learning target of the random forest model. When the prediction target is the soil heavy metal concentration at a future time step, the pollution source characteristic parameters and environmental driving factors at the current time point can be mapped to the measured heavy metal concentration values ​​after that time step to form supervised learning samples. When the target area contains multiple consecutive time points, a rolling training sample set can be constructed sequentially, starting from each time point and using the measured concentration values ​​of subsequent time points as labels to expand the number of effective samples. For different heavy metal elements, single-element training labels can be established separately, or multiple heavy metal element concentration vectors can be used as multi-target labels for simultaneous training, depending on the prediction requirements and model complexity. After feature and label matching is completed, each sample is organized into a row, with pollution source characteristic parameters and environmental driving factors listed as input features, and historical heavy metal concentration data listed as labels, forming a structured random forest training sample set. Before inputting into the random forest model, continuous features can be standardized or normalized, and categorical features can be numerically encoded to unify feature representation. Simultaneously, feature importance pre-screening and correlation analysis can be combined to remove features with weak predictive contribution or high redundancy, reducing model complexity and overfitting risk. For outliers in the labels or data that significantly deviate from the reasonable concentration range, verification should be performed according to the outlier identification rules in S1. If necessary, the corresponding samples should be removed or marked as low-weight samples to avoid interfering with model training. Finally, the sample set can be divided according to spatial partitioning or temporal order, retaining a portion of the samples as a validation set for subsequent evaluation of the random forest model's training effect and parameter optimization.

[0025] In step S4, the predicted soil heavy metal concentrations for the target area over future time scales are output, including: S401. Determine the input features and output labels of the random forest model based on the random forest training sample set. The pollution source feature parameters and environmental driving factors are used as input features, and the historical heavy metal concentration data at the corresponding spatial location and time scale are used as output labels to construct the random forest model training data. Sample records are read one by one from the random forest training sample set constructed in S304. The pollution source characteristic parameters and environmental driving factors in each record are used as the input feature vector. Pollution source characteristic parameters include the pollution source type coding features formed in S303, as well as the pollution source contribution concentration, relative contribution rate, and spatiotemporal variation features. These features reflect the analytical results of the PMF model on the pollution source contribution and constitute the pollution source constraint input of the random forest model. Environmental driving factors include factors such as soil physicochemical properties, climate and meteorology, topography, and land use type, unified to the same spatial grid and time node. The output labels are historical heavy metal concentration data at the corresponding spatial location and time scale. Labels can be established separately for a single heavy metal element, or a vector composed of multiple heavy metal concentrations can be used as a multi-target label. When constructing training data, the consistency between the input features and output labels in spatial grid identification and time identification should be checked for each sample to ensure that the time difference between the prediction target time node and the input feature time node conforms to the preset prediction step size relationship. For data with labels below the detection limit or missing, half of the detection limit can be used to replace the missing data, and the weight information of the corresponding samples can be recorded. Alternatively, low-quality labels can be weighted by incorporating uncertainty. After completing the above processing, the input feature matrix and output label vector are stored aligned with the sample numbers to form numerical training data that can be directly used for training the random forest model. For categorical environment-driving factors, their encoding results in S3 should be maintained to avoid changes in feature semantics caused by re-encoding.

[0026] S402. Construct multiple decision tree models based on the training data of the random forest model. By randomly sampling and selecting the input features, and using historical heavy metal concentration data to train each decision tree model, multiple decision tree prediction models are obtained. Based on the input feature matrix and output label vector, multiple Bootstrap training subsets are extracted from the original training sample set using sampling with replacement. Each subset corresponds to a decision tree to be constructed. The number of Bootstrap training subsets is consistent with the number of decision trees in the pre-defined random forest. Samples not included in the current subset form the out-of-bag samples of that decision tree, used for subsequent generalization ability estimation and feature importance calculation. For each Bootstrap training subset, a binary regression decision tree is recursively constructed starting from the root node. When splitting a node, instead of traversing all input features, a pre-defined proportion of feature subsets are randomly selected from the feature set consisting of pollution source feature parameters and environmental driving factors as candidate splitting features. Then, for each candidate feature, possible splitting thresholds are traversed after sorting by feature value. The optimal feature and optimal splitting threshold are selected based on minimizing the sum of the mean square errors of the heavy metal concentration labels of the two child nodes after splitting. When sample labels correspond to different uncertainties, the reciprocal of the uncertainty or the weight related to the uncertainty can be included in the splitting criterion to reduce the impact of low-quality labels on the tree structure. For multi-target labels, the splitting criterion can be to minimize the sum of the weighted mean square errors of multiple heavy metal elements, and output the average concentration vector of each heavy metal element at the leaf node. The above splitting process is recursively executed until preset stopping conditions are met, including but not limited to: the number of samples within a node being less than a preset minimum number of samples in a leaf node; the tree depth reaching a preset maximum depth; the mean square error of the labels within a node being less than a preset threshold; and the number of samples in any child node after further splitting being less than a preset minimum number of split samples. The leaf node output is the arithmetic mean of the training sample labels within that node, or a weighted average based on sample weights. After all decision trees are constructed, multiple decision tree prediction models with differences are obtained; these models together constitute the basic prediction unit of the PMF-constrained random forest prediction model, and their prediction results will be ensembled and averaged in subsequent steps to obtain the final predicted value of soil heavy metal concentration.

[0027] S403. Introduce pollution source characteristic parameters into the input feature system of multiple decision tree prediction models. Among them, the pollution source characteristic parameters include pollution source type and pollution source contribution intensity, so that multiple decision tree prediction models can jointly learn the nonlinear mapping relationship between changes in pollution source contribution, changes in environmental driving factors and changes in soil heavy metal concentration. And construct a PMF-constrained random forest prediction model by integrating the prediction results of multiple decision trees. Based on multiple decision tree prediction models constructed using S402, pollution source characteristic parameters are incorporated into the random forest model as input features with constraint significance, rather than ordinary environmental variables. Each decision tree incorporates pollution source type encoding features and pollution source contribution intensity features into the candidate splitting feature set, participating in random feature sampling along with environmental driving factors. When a node split selects a pollution source contribution class feature, its splitting threshold and branch direction directly reflect the nonlinear impact of changes in pollution source contribution as analyzed by PMF on changes in soil heavy metal concentrations. When a pollution source type encoding feature is selected, samples of different dominant pollution source types are divided to learn differentiated concentration response relationships. Thus, the pollution source type and contribution intensity information in the PMF source apportionment results are embedded into the nonparametric mapping process of the random forest, forming prior constraints. To stably learn nonlinear mapping relationships, differentiated processing can be applied in the node splitting criteria: the contribution intensity feature uses the contribution significance information or uncertainty constraint threshold search range from S302 to avoid overfitting low contribution or noise; the type encoding feature combines the type label with the average concentration value at the leaf node output to highlight its moderating role; the environmental driving factors select features and thresholds by minimizing the sum of the mean square errors of the concentration labels of the child nodes, maintaining comparability. In the integration phase, each decision tree provides a prediction, and the PMF-constrained random forest prediction model uses the arithmetic mean as the final prediction value. If the out-of-bag sample evaluation finds that a certain tree's prediction error is significantly too large or its importance to pollution source characteristics is significantly too low, its weight can be reduced or it can be removed to strengthen the constraints. The output of multi-objective heavy metal elements can be averaged element-by-element or directly averaged over the concentration vector output of leaf nodes to maintain the correspondence between elements. The importance of features is calculated using out-of-bag samples. If the pollution source contribution class features and type coding features have high importance or high explanation ratio, it indicates that the PMF-constrained features are effective; otherwise, the coding method, contribution feature scale, or feature sampling ratio can be adjusted. Through the above process, multiple decision trees, guided by pollution source feature parameters, jointly learn the nonlinear mapping relationship between changes in pollution source contribution, changes in environmental driving factors, and changes in soil heavy metal concentration, and are integrated to form the PMF-constrained random forest prediction model.

[0028] S404. The PMF-constrained random forest prediction model is trained and optimized based on the random forest training sample set. The model parameters of the PMF-constrained random forest prediction model are adjusted according to the difference between the model prediction results and historical heavy metal concentration data to obtain the optimized PMF-constrained random forest prediction model. Based on the sample size, input feature dimensions, and label features of the random forest training sample set, the main hyperparameters of the PMF-constrained random forest prediction model are initialized, including the number of decision trees and the maximum depth of a single tree. Under the PMF constraint, a minimum sampling ratio or importance retention threshold for pollution source features is set to ensure sufficient representation of these features. After initialization, the model is trained using the training samples, and the out-of-bag prediction results for each decision tree are recorded synchronously. The validation set or out-of-bag samples are input into the model to obtain predicted values, which are then compared with historical data to calculate the prediction error and evaluate the model. When there are uncertainties in the label samples, the sample weights are included in the error statistics. For multi-element outputs, the error is calculated using separable elements or a comprehensive index is used. Simultaneously, out-of-bag samples are used to estimate the generalization error to avoid overestimating model performance. Based on the error evaluation results, strategies such as grid search and Bayesian optimization are used to iteratively optimize the hyperparameters in multiple rounds, searching for the parameter combination that minimizes the error within a preset search range. The optimal parameters and model structure are updated iteratively. Cross-validation can be introduced to improve the stability of parameter selection; when the sample size is small and noise is high, the number of cross-validation folds can be increased or repeated cross-validation can be used. During optimization, the importance of pollution source features is calculated using out-of-bag samples to determine whether the constraints are met. The sampling ratio or constraint range of pollution source features is adjusted to balance the relationship between pollution source constraints and environmental driving factors. Pollution source factors with low or insignificant contributions are temporarily excluded, and their retention is determined by error changes. To reduce the risk of overfitting, the complexity of the decision tree structure is limited during training. The constraint strength is adjusted based on the error changes between the training and validation sets. Samples with high prediction errors or abnormal labels are marked as low-weight samples to reduce their impact on the next round of training, allowing the model to focus more on high-quality, representative training samples. After training, evaluation, and parameter adjustment, the hyperparameter combination that minimizes the difference between the model's predictions and historical heavy metal concentration data and has stable generalization ability is determined, resulting in the optimized PMF-constrained random forest prediction model. The model's decision tree structure, leaf node outputs, feature splitting paths, hyperparameter configurations, and feature importance rankings are saved for subsequent predictions of future timescale soil heavy metal concentrations in the target area, and to provide uncertainty estimates or confidence interval references for the prediction results.

[0029] S405. Based on the information on changes in environmental driving factors and pollution source characteristic parameters in the target area over future time scales, input the information on changes in environmental driving factors and pollution source characteristic parameters into the optimized PMF-constrained random forest prediction model, and output the predicted results of soil heavy metal concentration at the corresponding spatial location in the target area over future time scales.

[0030] Based on the target timescale of the prediction task, the acquisition methods for environmental driving factors and pollution source characteristic parameters of the target area at the future prediction time node are determined: Environmental driving factor change information is based on future prediction data or scenario settings for the target area, projected according to the unified timescale and spatial grid identifier of S1 to form input data conforming to the training sample format; when different factors have inconsistent change cycles and resolutions, the scale is unified according to the training stage rules; predictable factors are directly used from the prediction data, while factors that are difficult to predict and have stable spatial locations use the current values, with a change range of ±5% to represent uncertainty. Pollution source characteristic parameter change information is combined with future emission trends, governance scenarios, and regional planning to extrapolate or set scenarios for the pollution source types and contribution intensity identified in S302 and S303; after adjusting the contribution intensity, combined with PMF analysis results, future pollution source contribution characteristics are formed, which can extrapolate trends or set change rates according to scenarios; all pollution source characteristic parameters must be consistent with the environmental driving factors in terms of spatial and temporal identifiers, and processed using the same method as S303 to ensure a unified input distribution. Before inputting into the model, dimensionality reduction results are filtered based on features from the training phase, retaining only the feature fields used by the model, and the input matrix is ​​organized according to the feature order determined during training. Newly added, untrained pollution source types are categorized as mixed / undefined sources, or mapped to existing types and recorded. Outliers in environmental driving factors are handled using the methods from the training phase; for outliers with excessively large missing ranges that cannot be imputed, the corresponding grid prediction results are marked as low confidence. After input preparation, both types of information are input into the optimized PMF-constrained random forest prediction model sample by sample. Each decision tree is propagated along the splitting path to the leaf node, and the mean or weighted mean of heavy metal concentrations in the training samples at the leaf node is output as the single-tree prediction result. For multi-element outputs, each tree simultaneously outputs the concentration vectors of each element. The model integrates and averages all decision tree prediction results to obtain the final prediction value, using an arithmetic mean or weighted average according to the rules from the training phase. When outputting prediction results, the dispersion of each decision tree prediction result is used to measure prediction uncertainty, and the standard deviation or quantile interval is calculated to obtain the prediction confidence interval. The model is run separately for multi-scenario prediction tasks, outputting the spatial distribution prediction results of soil heavy metal concentrations corresponding to each scenario. The relative contributions of changes in pollution sources and environmental driving factors to the spatiotemporal evolution of soil heavy metal concentrations are analyzed. The final results are organized according to a unified spatial grid identifier and time identifier to form a dataset for predicting soil heavy metal concentrations in the target area at future time scales. This dataset can be used to draw spatial distribution maps, temporal evolution curves, or risk zoning maps of exceeding standards.

[0031] Optionally, obtaining the evolution characteristics of heavy metal pollution in the target area soil in step S5 includes: S501. Based on historical monitoring data and soil heavy metal concentration prediction results, construct historical soil heavy metal concentration sequences and predicted soil heavy metal concentration sequences according to corresponding spatial locations and time scales, and continuously correlate the historical soil heavy metal concentration sequences and predicted soil heavy metal concentration sequences in time to obtain time series data of soil heavy metal concentration in the target area. Measured heavy metal concentration data from different historical monitoring time nodes across unified spatial grids in the target area are extracted from a soil heavy metal spatiotemporal database and sorted chronologically to form a historical soil heavy metal concentration sequence. For multiple monitoring points or duplicate sampling at the same time node within the same spatial grid, representative concentration values ​​are obtained by merging them using the same time aggregation rules for constructing training sample sets. Missing historical monitoring time nodes are filled using linear interpolation, mean imputation, or moving window interpolation, and the imputation nodes are marked. Individual historical concentration sequences for different heavy metal elements are constructed separately. If a comprehensive pollution level is required, normalization can be used to form a comprehensive pollution index sequence. From the future results output by the S4-optimized PMF-constrained random forest prediction model, predicted concentrations for each future time node are extracted according to spatial grid identifiers and sorted by time step to form a predicted soil heavy metal concentration sequence. The time step is consistent with the historical sequence or a unified resolution is set according to the task. For multi-scenario prediction results, each scenario constructs an independent sequence, retaining the scenario identifier. A temporally continuous correlation is established between the historical and predicted sequences, connecting the predicted sequences with the last time node of the historical sequence as the connection point, forming a continuous time axis covering both the past and the future. For nodes with time intervals, interpolation or smoothing is used to generate transition concentrations, and the generation method is recorded. For nodes with continuous time, they are directly spliced. After association, each spatial grid corresponds to a continuous curve, retaining the data source identifier for each time node. Then, consistency checks are performed on the associated sequences, including time order, dimensions, grid encoding, and sequence integrity checks. Outliers are corrected, future end noise is moderately smoothed, and trend information is preserved. Finally, using the spatial grid identifier as the primary key, the concentration values ​​of each heavy metal element, data source, and uncertainty information are recorded to form a time-series dataset of heavy metal concentrations in the soil of the target area.

[0032] S502. Based on the time series data of soil heavy metal concentration, analyze the changes in soil heavy metal concentration at different spatial locations and time scales, calculate the trend of soil heavy metal concentration changes, and obtain the evolution characteristics of soil heavy metal concentration at different spatial locations and time scales in the target area. Based on time-series data of heavy metal concentrations in soil of the target area, the concentration trends of each heavy metal element were calculated for each spatial grid during the historical monitoring period, the future prediction period, and the entire period connecting the historical and future periods. Trend calculations could employ methods such as linear regression slope estimation, Theil-Sen slope estimation, or the Mann-Kendall trend test. Before trend calculation, consistency weighting was applied to the series to ensure reasonable weighting for data from different sources and of different quality in trend estimation; the prediction standard deviation of future prediction data was included in the robustness assessment of trend estimation to avoid low-confidence nodes excessively influencing the overall trend. After trend calculation, the spatial distribution of heavy metal concentration trends in soil of the target area was obtained by summarizing the data by spatial grid; spatial autocorrelation analysis, hotspot analysis, or spatial clustering methods were used on adjacent grids to identify the spatial clustering characteristics of different trend regions and determine whether there are trend differences caused by specific pollution sources or environmental factors; for non-monotonic grids, stage-specific local features were extracted to distinguish different evolution types. For different time scales, short-, medium-, and long-term change rates are calculated separately. Trends within a sliding time window can be estimated to obtain a trend intensity sequence, identifying acceleration, deceleration, or turning points in the trend. Multi-scenario prediction sequences are used to calculate the change trends under each scenario, comparing trend differences across different scenarios within the same grid to reflect the impact of different control measures or environmental pathways on the direction of concentration evolution. Finally, time-series data, trend results, and stage-extracted information on soil heavy metal concentrations in the target area are integrated to form the characteristics of soil heavy metal concentration evolution at different spatial locations and time scales in the target area. This includes concentration values ​​at each time node in each grid, as well as the direction, rate, trend significance, and multi-scenario trend differences over time.

[0033] S503. Based on source contribution information, conduct time series analysis on the contribution intensity of different pollution source factors at different spatial locations and time scales, calculate the changing trend of pollution source contribution intensity, and obtain the evolution characteristics of pollution source contribution corresponding to different pollution source types. Pollution source contribution information for each spatial grid and historical time window in the target area is extracted from the S3 source apportionment results, including the relative contribution rate, contribution concentration, factor score, and uncertainty of each pollution source type. Historical contributions are arranged according to the S302 identification results and the S303 contribution intensity sequence, and are processed for consistency using the S302 standardization process. Multiple analysis results at the same time node are aggregated according to the same rules as S501, and the aggregation identifier is retained. Future contributions are based on the pollution source emission change trends, governance measure implementation scenarios, and regional development plans set in S405. Using the historical contribution intensity of S303 as a benchmark, extrapolation is performed according to the pollution source activity level change coefficient, maintaining the same coding and standardization method as S303, satisfying the non-negativity constraint and the sum of contribution rate constraint, and smoothing or piecewise linear interpolation is performed when anomalies occur. The historical and future contribution sequences are continuously correlated over time, and transition segments are generated at intervals using linear interpolation, exponential smoothing, or piecewise continuous generation, and the source identifier is recorded. For each spatial grid and each pollution source type, the historical, forecast, and full-time contribution intensity variation trends were calculated. Linear regression, Theil-Sen, or Mann-Kendall methods were used, weighted according to data source reliability and uncertainty. Historical measured contributions had higher weights, while extrapolated contributions were weighted according to scenario reliability. The spatial distribution of trends was summarized to identify spatial clustering characteristics of areas with rising, falling, or basically stable contributions. For non-monotonic grids, stage types such as continuous accumulation, fluctuating increase, fluctuating decrease, initial increase followed by decrease, or initial decrease followed by increase were extracted. Sliding time windows were set to calculate short-term, medium-term, and long-term change rates to identify acceleration, deceleration, or turning points. Trends were calculated for multiple scenarios and differences were compared. The relative rates of change in contributions from different pollution sources were calculated to identify pollution source types that were gradually becoming dominant or being reduced. Finally, the evolution characteristics of pollution source contributions corresponding to different pollution source types were formed, including contribution time series data, direction of change, rate of change, trend significance, spatial clustering patterns, and differences in evolution paths across multiple scenarios.

[0034] S504. Based on historical monitoring data, including atmospheric deposition data, sediment data, soil heavy metal concentration data, and agricultural product data, the data are matched according to their corresponding spatial locations and time scales to construct time series data of heavy metal concentrations among different polluting media. The response relationship of heavy metal concentration changes among different polluting media is analyzed to obtain the migration response characteristics of polluting media. From the spatiotemporal database of heavy metals in soil, atmospheric deposition, sediment, soil, and agricultural product heavy metal monitoring data at different monitoring time nodes in each unified spatial grid of the target area were extracted and organized according to spatial grid identifiers and time identifiers: For multiple sampling points in the same grid at the same time node, representative values ​​were obtained using the S501 same-time aggregation rule, and the aggregation method was recorded as the data source identifier; for missing time nodes, linear interpolation, historical average values, or adjacent medium correlation interpolation were used to fill in missing time nodes based on monitoring frequency and change characteristics, and the interpolation nodes were marked; atmospheric deposition data were converted into comparable time average deposition flux; sediment data were converted into heavy metal concentration sequences for corresponding time nodes; agricultural product data retained crop type and edible part information, and sequences were established for multiple crops in the same grid, or normalized according to standard limits to form a comprehensive agricultural product heavy metal index. To unify the time scale of different media: when the time resolution of different media is inconsistent, the soil heavy metal concentration time series after S501 association is used as the benchmark to perform time aggregation or interpolation on the sequences of each media to ensure that the concentrations at the same time node are comparable; for agricultural product data with strong seasonality, the nearest neighbor matching is performed according to the harvest cycle and the soil sampling time to avoid using asynchronous observations for inter-media relationship analysis; the unified multi-media time series data is organized into a coupled time series dataset according to spatial grid and time node, and the dimensions, detection limits, data sources and matching method identifiers of each medium are retained. Based on multi-media time-series data analysis, the response relationships of heavy metal concentration changes among different polluting media are analyzed: Between atmospheric deposition and soil, time-lag correlation analysis, distributed lag regression, or panel vector autoregression models are used to estimate the contribution and lag time, and S3 source apportionment results are combined to distinguish between natural and anthropogenic deposition; between soil and agricultural products, the enrichment coefficient or migration coefficient is calculated as a function of soil concentration within the same grid according to crop type, identifying linear or nonlinear absorption responses, and quantile regression or piecewise regression is used to determine whether a soil concentration threshold effect exists; between sediment and soil or agricultural products, spatial correlation and response intensity are analyzed by combining river network distance, water flow direction, and sediment migration characteristics; for multi-element comprehensive cases, single-element response relationships can be established separately followed by cross-element comparisons. The direction, intensity, lag characteristics, and spatial differences of the response relationships among various media are summarized to form the pollution media migration response characteristics, including enrichment coefficients or transfer coefficients along each migration path, response significance patterns, and differences among different heavy metal elements.

[0035] S505. Based on the evolution characteristics of soil heavy metal concentration, the evolution characteristics of pollution source contribution, and the migration response characteristics of pollution media, a dynamic evolution model of soil heavy metals is constructed. The evolution characteristics of soil heavy metal pollution in the target area are obtained through the dynamic evolution model of soil heavy metals.

[0036] The soil heavy metal concentration evolution characteristics obtained in S502, the pollution source contribution evolution characteristics obtained in S503, and the pollution medium migration response characteristics obtained in S504 are aligned according to a unified spatial grid identifier and time nodes to form a dynamic evolution characteristic dataset. During alignment, missing feature nodes are filled in using the same rules as in S501, while retaining the source identifier; scenario identifiers are retained for each scenario feature. Based on this, a dynamic evolution model of soil heavy metals is constructed, which can employ models such as system dynamics, multiple regression, Bayesian networks, or long short-term memory networks, using changes in pollution source contribution intensity, changes in environmental driving factors, and medium migration flux as explanatory variables, and changes in soil heavy metal concentration as the response variable. Model training uses historical monitoring period and partial prediction period data as the training set, and the remaining prediction period as the validation set, with cross-validation to determine parameters; each scenario feature can be established with a corresponding model or a unified model incorporating scenario variables. During construction, migration paths and lag orders are determined based on pollution medium migration response characteristics, and influence coefficients are determined based on pollution source contribution evolution characteristics; variance decomposition, Shapley values, or local sensitivity analysis are used to extract the time series contribution rates of each driving factor to concentration changes. The model is used to conduct historical simulation and future evolution projection: historical simulation compares the model output with the measured sequence, and the goodness of fit is evaluated using the coefficient of determination and root mean square error; future projection combines different scenario inputs to output the concentration evolution path. Finally, by integrating the concentration change trend, the change trend of driving factor contribution, the change of media migration response intensity, and simulation uncertainty, the evolution characteristics of soil heavy metal pollution in the target area are formed, including: the dominant spatiotemporal evolution mode of soil heavy metal concentration, the evolution path of pollution source contribution structure, the response changes of key migration media and pathways, and the differences in pollution risk evolution under different scenarios.

[0037] Optionally, the output of the target area soil heavy metal dynamic early warning results in step S6 includes: S601. Based on the evolution characteristics of soil heavy metal pollution, extract the current concentration, concentration trend, and pollution source contribution trend of soil heavy metals at different spatial locations and time scales in the target area. Calculate the pollution source contribution change rate based on the pollution source contribution change trend to construct dynamic early warning characteristic parameters for soil heavy metals. From the dynamic evolution characteristic dataset constructed in S505, extract the soil heavy metal concentration status characteristics, concentration change trend characteristics, and pollution source contribution change trend characteristics of each unified spatial grid in the target area at the early warning baseline time node. The current soil heavy metal concentration is based on the early warning task time benchmark, selecting the historical monitoring period end concentration, the most recent node concentration in the predicted sequence, or the current measured update data as the concentration status representation. For multiple heavy metal elements within the same grid, single-element concentrations can be retained as needed, or normalized according to standard limits to form a comprehensive pollution index. The soil heavy metal concentration change trend characteristics are extracted from the trend results in S502, extracting the short-, medium-, and long-term change directions, rates, and significance of each heavy metal element, and transforming them into unified trend characteristic parameters that can be used for early warning determination. The pollution source contribution trend characteristics are extracted from the pollution source contribution evolution characteristics obtained from S503. The direction, rate, and significance of the contribution intensity changes of each pollution source type under the same spatial grid and time scale are extracted, and the pollution source contribution change rate is calculated based on this. The change rate can be calculated using the difference in contribution intensity between adjacent nodes, the change per unit time, or the ratio of the trend slope to the baseline contribution intensity. A lower limit threshold for the change rate is set for pollution source types with contribution intensity close to zero or below the detection limit. The change rate for each scenario is calculated separately for multiple scenario development paths, and scenario identifiers are retained. After completing the above extraction and calculation, the current concentration status, concentration change trend, and pollution source contribution change rate are structured according to a unified spatial grid identifier, time identifier, heavy metal element type, and pollution source type to form a dynamic early warning characteristic parameter set for soil heavy metals. When there are dimensional differences in characteristic parameters, range standardization, Z-score standardization, or risk threshold-based grading and normalization can be used to ensure a unified scale for subsequent risk level determination. The final parameter set uses the spatial grid as the primary key, sorts by early warning time node, records each characteristic parameter for each grid, and includes data source identifiers, scenario identifiers, and uncertainty information.

[0038] S602. Based on the dynamic early warning characteristic parameters of soil heavy metals, the current concentration of soil heavy metals, the trend of soil heavy metal concentration change and the rate of change of pollution source contribution are quantified to obtain the corresponding concentration risk indicators, trend risk indicators and pollution source risk indicators. First, from the soil heavy metal dynamic early warning characteristic parameter set constructed by S601, the current concentration status, concentration change trend parameters and contribution change rate parameters of each heavy metal element are extracted according to the unified spatial grid identifier and time node, and risk characteristics are quantified respectively.

[0039] For concentration risk indicators, based on the current concentration of heavy metals in the soil, the concentration value of each heavy metal element is compared with the corresponding soil environmental quality standard limit, risk screening value, or control threshold. A single-factor pollution index method can be used to calculate the ratio of each heavy metal element concentration to the standard limit, serving as the single-element concentration risk index. For situations where multiple heavy metal elements coexist within the same grid, the Nemerow comprehensive pollution index method or the weighted comprehensive index method can be used to synthesize the degree of exceedance of each element into a grid-wide comprehensive concentration risk index. For concentrations that do not exceed the standard limit but are close to it, a warning threshold range can be set. For example, grids with concentration values ​​exceeding 20% ​​of the limit can be designated as areas of concern, allowing the concentration risk index to reflect areas that have not yet exceeded the standard but have potential cumulative risks. During the calculation process, the single-element risk index of each heavy metal element should be retained for subsequent refined warnings targeting specific pollutants. For trend risk indicators, the direction and rate of change in soil heavy metal concentration are converted into quantitative trend risk values. For upward trends, the rate of increase can be categorized into slow, moderate, and rapid increases based on the slope and significance level, with progressively increasing trend risk scores assigned. For downward or relatively stable trends, the risk score can be set to a low value or no increase should be applied. For grids whose trend significance fails the test, even if the slope is positive, their weight in the trend risk index should be reduced or they should be marked as trend uncertainty areas to avoid misjudging statistical noise as continuous cumulative risk. For trend characteristics across multiple time scales, the results of superimposing short-term, medium-term, and long-term trends can be combined, and a weighted summation method can be used to calculate the trend risk index, with a higher weight given to the continuous upward trend in the long term. For multi-scenario characteristics, the trend risk index should be calculated separately for each scenario, retaining scenario identifiers to reflect the differences in trend risk under different future development paths. For pollution source risk indicators, both the rate of change in pollution source contribution and the intensity of pollution source contribution should be included in risk quantification. For pollution source types with high contribution intensity and a positive, continuously rising contribution rate, a higher pollution source risk score should be assigned, indicating that the pollution source is exacerbating the risk of heavy metal pollution in regional soil. For pollution source types with high contribution intensity but a change rate approaching zero or showing a downward trend, a medium or low risk score can be set, indicating that their contribution is stabilizing or declining. For pollution source types with low contribution intensity and no significant increase in the change rate, a lower risk score can be set. The calculation of the pollution source contribution change rate can be combined with the change rate results in S601, weighting and integrating the contribution change rates at different time scales so that the pollution source risk index can reflect both short-term fluctuations and medium- to long-term structural changes. When multiple pollution source types coexist, the pollution source risk scores can be weighted and summarized according to the relative weight of each pollution source contribution rate to obtain a grid-based comprehensive pollution source risk index, while retaining the individual risk scores for each pollution source type.After quantifying the three types of risk characteristics mentioned above, the concentration risk indicators, trend risk indicators, and pollution source risk indicators can be normalized to the same risk dimension or score range, forming a comparable risk indicator system. For issues of correlation and information overlap among indicators, correlation coefficients can be calculated. If necessary, principal component analysis or factor analysis can be used for dimensionality reduction and fusion to avoid double-weighting that could distort the risk level determination results. The final risk indicator system uses a spatial grid as the primary key, recording the concentration risk indicators, trend risk indicators, and pollution source risk indicators for each grid, along with their corresponding heavy metal element or pollution source type components, while retaining data source identifiers, scenario identifiers, and uncertainty information.

[0040] S603. A source-concentration-trend coupled risk early warning model is constructed based on concentration risk indicators, trend risk indicators, and pollution source risk indicators. This model calculates the comprehensive risk assessment results for the target area at different spatial locations and time scales by linking the current concentration of heavy metals in the soil, the future trend of heavy metal changes in the soil, and the changes in pollution source contributions. First, from the concentration risk indicators, trend risk indicators, and pollution source risk indicators obtained in S602, the risk quantification values ​​of each grid are extracted according to a unified spatial grid identifier and early warning time node. The three types of indicators are then organized according to spatial grid alignment. When multiple heavy metal elements or multiple pollution source types exist within the same grid, the risk components of single elements and single pollution source dimensions are retained respectively, and scenario identifiers are retained for multi-scenario systems. After alignment, a coupled risk assessment input dataset is formed with the spatial grid as the primary key and the risk indicator type and scenario identifier as dimensions. Based on this, a source-concentration-trend coupled risk early warning model is constructed. This model takes the three types of risk indicators as input and, through a coupling mechanism, links the current concentration status, future trend of heavy metal changes in the soil, and changes in pollution source contributions to output comprehensive risk assessment results. Coupling methods can be adopted, such as weighted linear combination, multiplicative synthesis, fuzzy comprehensive evaluation, Bayesian networks, or evidence-based reasoning, depending on the relevant structure of the indicators, data availability, and regional management needs. Weighted linear combination can be achieved through the analytic hierarchy process, entropy weighting, or sensitivity inversion weighting based on historical risk events. When the interaction between indicators is strong, multiplicative synthesis or Copula functions can be used to describe joint risks. For multiple scenario development paths, coupling models can be established separately, or a unified model incorporating scenario indicator variables can be established to ensure the comparability of results between scenarios. The model is used to calculate the comprehensive risk assessment results of each spatial grid and each early warning time node in the target area. The comprehensive risk values ​​are then aggregated and normalized to a unified score range. The risk values ​​of single elements or single pollution sources can be calculated separately first, and then aggregated at the grid level according to the contribution weight, retaining the information of the main risk contribution factors. For risk indicators with uncertainties, Monte Carlo simulation and other methods can be used to transfer the uncertainty and output the probability distribution or confidence interval of the comprehensive risk score. According to the comprehensive risk score distribution and regional environmental management objectives, low, medium, high and extremely high risk level thresholds are set to verify the rationality of the level boundaries. Grids close to the threshold can be set as risk transition zones. The final result uses the spatial grid as the primary key and records the comprehensive risk score, risk level, main risk contribution factors, components of each risk indicator and uncertainty interval for each grid, with scenario identification and data source identification.

[0041] S604. Based on the comprehensive risk assessment results, determine the corresponding risk level, and generate dynamic early warning results for heavy metals in the soil of the target area according to the risk level under different spatial locations and time scales.

[0042] Extract the comprehensive risk score, risk level, main risk contributing factors, and uncertainty interval for each spatial grid at the warning time node from the comprehensive risk assessment results. For grids with output probability distributions or confidence intervals, the risk level can be determined based on the upper confidence bound of the risk score or the probability of exceeding the high-level threshold, avoiding underestimation of extreme risks due to taking only the mean. For results using deterministic scores, the level is directly classified according to the low-risk, medium-risk, high-risk, and extremely high-risk thresholds set in S603. The level of the same grid may change at different warning time nodes or under different scenarios, so it needs to be determined and recorded separately for spatial grids, time nodes, and scenario identifiers. Generate dynamic warning results for heavy metals in the target area soil. Spatially, using a unified spatial grid as the unit, map the risk level corresponding to each heavy metal element or comprehensive risk to the warning level, forming a spatial distribution result of warning levels for each grid. For cases where multiple heavy metal elements coexist, the overall warning level of the grid can be determined according to the principle of the highest risk level of any element or the highest comprehensive risk level, while retaining the warning level of a single element to identify the main warning factors. In terms of time, the risk levels of each grid are recorded sequentially based on the early warning time nodes. Grids with rising, persistently high, or rapidly increasing risk levels are marked as trend warning focus areas, and cross-checked with the trend risk indicators in S602 to avoid misjudgments based solely on concentration status at a single moment. For multiple scenario development paths, early warning results corresponding to each scenario should be generated separately, and information on the differences in early warning levels between scenarios should be output to reflect the dynamic changes in soil heavy metal risk under different pollution control or development paths.

[0043] The final dynamic early warning results include: a spatial distribution map or data table of risk levels for each grid in the target area, a time-by-time sequence of early warning level changes, identification results of major early warning factors, and comparison results of early warning levels under different scenarios. The early warning results can be further color-coded or coded according to risk level to form a visual early warning map, accompanied by data source identification, scenario identification, and uncertainty explanation.

[0044] Example 2 A PMF-Random Forest Coupled Soil Heavy Metal Source Tracing and Dynamic Evolution Early Warning System includes: a processor and a memory for storing processor-executable instructions; wherein the processor is configured to implement the PMF-Random Forest Coupled Soil Heavy Metal Source Tracing and Dynamic Evolution Early Warning system when executing the executable instructions. It should be noted that the computer device includes a processor and a memory, and may also include one or more of a multimedia component, an input / output (I / O) interface, and a communication component. The processor controls the overall operation of the computer device, completing all or part of the steps of the PMF-Random Forest Coupled Soil Heavy Metal Source Tracing and Dynamic Evolution Early Warning system. The memory stores various types of data to support device operation and can be implemented by volatile or non-volatile storage devices or combinations thereof, such as SRAM, EEPROM, etc. The multimedia component includes a screen (such as a touch screen) and an audio component. The audio component has a microphone to receive external audio signals and at least one speaker to output audio signals. The I / O interface provides an interface for the processor and other interface modules (such as a keyboard, mouse, buttons, etc.). The communication component is used for wired or wireless communication between devices. Wireless communication includes Wi-Fi, Bluetooth, etc., and the communication component includes a Wi-Fi module, etc. As a preferred option, the computer device can be implemented using electronic components such as ASIC and DSP to execute the PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning method.

[0045] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

Claims

1. A PMF-random forest coupled method for source tracing and dynamic evolution early warning of soil heavy metals, characterized in that, The method includes: Multi-source environmental monitoring data of the target area were acquired, and the data were processed by unifying the time scale, spatial gridding, and data fusion to construct a spatiotemporal database of soil heavy metals. The spatiotemporal database of soil heavy metals includes soil heavy metal concentration data, atmospheric deposition data, sediment data, agricultural product data, spatial location data, and environmental driving factors. Based on the spatiotemporal database of soil heavy metals, a heavy metal concentration matrix and the corresponding uncertainty matrix were constructed. The heavy metal concentration matrix was decomposed using the positive definite matrix factorization (PMF) model to obtain source spectrum information and source contribution information corresponding to multiple pollution source factors. Based on source spectrum information and source contribution information, pollution source characteristic parameters are constructed. Pollution source type, pollution source contribution intensity and environmental driving factors and historical heavy metal concentration data in the soil heavy metal spatiotemporal database are fused to construct a random forest training sample set. A PMF-constrained random forest prediction model is constructed based on a random forest training sample set. By using pollution source characteristic parameters as input features of the random forest model, the PMF-constrained random forest prediction model establishes a nonlinear mapping relationship between changes in pollution source contribution, changes in environmental driving factors, and changes in soil heavy metal concentration, and outputs the predicted results of soil heavy metal concentration in the target area at future time scales. Based on the predicted results of soil heavy metal concentration, source contribution information and historical monitoring data, the trend of soil heavy metal concentration change, the trend of pollution source contribution change and the migration response relationship between different pollution media are calculated. A dynamic evolution model of soil heavy metal is constructed to obtain the evolution characteristics of soil heavy metal pollution in the target area. Based on the evolution characteristics of soil heavy metal pollution, a source-concentration-trend coupled risk early warning model is constructed. The risk level is determined according to the current concentration of soil heavy metals, the predicted trend of change, and the rate of change of pollution source contribution, and the dynamic early warning results of soil heavy metals in the target area are output.

2. The method for early warning of soil heavy metal source tracing and dynamic evolution coupled with PMF-random forest as described in claim 1, characterized in that, Obtaining source spectrum information and source contribution information for multiple pollution source factors includes: Based on the spatiotemporal database of soil heavy metals, soil heavy metal concentration data at different spatial locations and time scales within the target area were extracted and arranged according to spatial location, time information, and heavy metal element type to construct a heavy metal concentration matrix. Based on the data detection error, detection limit, and concentration change characteristics of heavy metal concentration data, the uncertainty corresponding to each heavy metal element is calculated, and an uncertainty matrix matching the heavy metal concentration matrix is ​​constructed based on the uncertainty. The heavy metal concentration matrix and uncertainty matrix are input into the positive definite matrix factorization (PMF) model. The heavy metal concentration matrix is ​​decomposed into a non-negative matrix by the positive definite matrix factorization (PMF) model. The mapping relationship between pollution source factors and heavy metal elements is established, and the initial source spectrum information and initial source contribution information corresponding to multiple pollution source factors are obtained. Based on the initial source spectrum information, initial source contribution information, and fitting results of the heavy metal concentration matrix, the number of different pollution source factors is iteratively calculated. The optimal number of pollution source factors is determined according to the model fitting degree, residual change characteristics, and the rationality of the pollution source factor interpretation, so as to obtain the source spectrum information and source contribution information corresponding to the optimized pollution source factors.

3. The method for early warning of soil heavy metal source tracing and dynamic evolution coupled with PMF-random forest as described in claim 1, characterized in that, Constructing the training sample set for a random forest includes: Based on source spectrum information, the compositional characteristics of different heavy metal elements in each pollution source factor are analyzed. Based on the compositional characteristics of heavy metal elements, the pollution source type corresponding to each pollution source factor is identified, and the correspondence between pollution source factors and pollution source types is established. Based on source contribution information, the contribution intensity of each pollution source factor at different spatial locations and time scales is extracted, and the contribution intensity is associated with the corresponding pollution source type based on the correspondence relationship to obtain pollution source contribution intensity information at different spatial locations and time scales. Based on pollution source type and pollution source contribution intensity information, pollution source characteristic parameters are constructed, pollution source type is feature-encoded, and pollution source contribution intensity information is used as pollution source contribution feature to form pollution source characteristic parameters used to characterize the pollution source impact characteristics. Pollution source characteristic parameters and environmental driving factors in the soil heavy metal spatiotemporal database are matched and fused according to their corresponding spatial location and time scale. Historical heavy metal concentration data at the corresponding spatial location and time scale are used as training labels to construct a random forest training sample set containing pollution source characteristic parameters, environmental driving factors, and historical heavy metal concentration data.

4. The method for early warning of soil heavy metal source tracing and dynamic evolution coupled with PMF-random forest as described in claim 1, characterized in that, The predicted soil heavy metal concentrations for the target area over future timescales include: The input features and output labels of the random forest model are determined based on the training sample set of the random forest. The pollution source characteristic parameters and environmental driving factors are used as input features, and the historical heavy metal concentration data at the corresponding spatial location and time scale are used as output labels to construct the training data of the random forest model. Multiple decision tree models were constructed based on training data from the random forest model. By randomly sampling and selecting input features, and training each decision tree model using historical heavy metal concentration data, multiple decision tree prediction models were obtained. Pollution source characteristic parameters are introduced into the input feature system of multiple decision tree prediction models. The pollution source characteristic parameters include pollution source type and pollution source contribution intensity, so that multiple decision tree prediction models can jointly learn the nonlinear mapping relationship between changes in pollution source contribution, changes in environmental driving factors and changes in soil heavy metal concentration. A PMF-constrained random forest prediction model is constructed by integrating the prediction results of multiple decision trees. The PMF-constrained random forest prediction model was trained and optimized based on the random forest training sample set. The model parameters of the PMF-constrained random forest prediction model were adjusted according to the difference between the model prediction results and historical heavy metal concentration data to obtain the optimized PMF-constrained random forest prediction model. Based on the changes in environmental driving factors and pollution source characteristic parameters in the target area over future time scales, the changes in environmental driving factors and pollution source characteristic parameters are input into the optimized PMF-constrained random forest prediction model, and the predicted soil heavy metal concentration at the corresponding spatial location in the target area over future time scales is output.

5. The method for early warning of soil heavy metal source tracing and dynamic evolution coupled with PMF-random forest according to claim 1, characterized in that, The characteristics of the evolution of heavy metal pollution in the target area soil include: Based on historical monitoring data and soil heavy metal concentration prediction results, historical soil heavy metal concentration sequences and predicted soil heavy metal concentration sequences were constructed according to corresponding spatial locations and time scales, and the historical soil heavy metal concentration sequences and predicted soil heavy metal concentration sequences were continuously correlated in time to obtain time series data of soil heavy metal concentration in the target area. Based on time series data of soil heavy metal concentration, the changes in soil heavy metal concentration at different spatial locations and time scales are analyzed, the trend of soil heavy metal concentration changes is calculated, and the evolution characteristics of soil heavy metal concentration at different spatial locations and time scales in the target area are obtained. Based on source contribution information, time series analysis is performed on the contribution intensity of different pollution source factors at different spatial locations and time scales to calculate the changing trend of pollution source contribution intensity and obtain the evolution characteristics of pollution source contribution corresponding to different pollution source types. Based on historical monitoring data, including atmospheric deposition data, sediment data, soil heavy metal concentration data, and agricultural product data, the data were matched according to their corresponding spatial locations and time scales to construct time series data of heavy metal concentrations among different polluting media. The response relationship of heavy metal concentration changes among different polluting media was analyzed to obtain the migration response characteristics of polluting media. Based on the evolution characteristics of soil heavy metal concentration, the evolution characteristics of pollution source contribution, and the migration response characteristics of pollution media, a dynamic evolution model of soil heavy metals is constructed, and the evolution characteristics of soil heavy metal pollution in the target area are obtained through the dynamic evolution model of soil heavy metals.

6. The method for early warning of soil heavy metal source tracing and dynamic evolution coupled with PMF-random forest as described in claim 1, characterized in that, The output of dynamic early warning results for heavy metals in the target area soil includes: Based on the evolution characteristics of soil heavy metal pollution, the current concentration of soil heavy metals, the trend of soil heavy metal concentration change, and the trend of pollution source contribution change are extracted at different spatial locations and time scales in the target area. The pollution source contribution change rate is calculated based on the trend of pollution source contribution change, and the dynamic early warning characteristic parameters of soil heavy metals are constructed. Based on the dynamic early warning characteristic parameters of soil heavy metals, the current concentration of soil heavy metals, the trend of soil heavy metal concentration change and the rate of change of pollution source contribution are quantified to obtain the corresponding concentration risk indicators, trend risk indicators and pollution source risk indicators. A source-concentration-trend coupled risk early warning model is constructed based on concentration risk indicators, trend risk indicators and pollution source risk indicators. By associating the current concentration of heavy metals in the soil, the future trend of heavy metal changes in the soil, and the changes in the contribution of pollution sources, the comprehensive risk assessment results of the target area at different spatial locations and time scales are calculated. Based on the comprehensive risk assessment results, the corresponding risk level is determined, and dynamic early warning results of heavy metals in the soil of the target area are generated according to the risk level under different spatial locations and time scales.

7. A PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning system, characterized in that, The system includes: processor; Memory used to store processor-executable instructions; The processor is configured to implement the PMF-random forest coupled soil heavy metal source tracing and dynamic evolution early warning method of any one of claims 1 to 6 when executing executable instructions.