%0 Journal Article %T Pre-training enhanced spatio-temporal graph neural network for predicting influent water quality and flow rate of wastewater treatment plant: Improvement of forecast accuracy and analysis of related factors. %A Wu X %A Chen M %A Zhu T %A Chen D %A Xiong J %J Sci Total Environ %V 951 %N 0 %D 2024 Aug 10 %M 39134280 %F 10.753 %R 10.1016/j.scitotenv.2024.175411 %X Efficient management of wastewater treatment plants (WWTPs) necessitates accurate forecasting of influent water quality parameters (WQPs) and flow rate (Q) to reduce energy consumption and mitigate carbon emissions. The time series of WQPs and Q are highly non-linear and influenced by various factors such as temperature (T) and precipitation (Precip). Conventional models often struggle to account for long-term temporal patterns and overlook the complex interactions of parameters within the data, leading to inaccuracies in detecting WQPs and Q. This work introduced the Pre-training enhanced Spatio-Temporal Graph Neural Network (PT-STGNN), a novel methodology for accurately forecasting of influent COD, ammonia nitrogen (NH3-N), total phosphorus (TP), total nitrogen (TN), pH and Q in WWTPs. PT-STGNN utilizes influent data of the WWTP, air quality data and meteorological data from the service area as inputs to enhance prediction accuracy. The model employs unsupervised Transformer blocks for pre-training, with efficient masking strategies to effectively capture long-term historical patterns and contextual information, thereby significantly boosting forecasting accuracy. Furthermore, PT-STGNN integrates a unique graph structure learning mechanism to identify dependencies between parameters, further improving the model's forecasting accuracy and interpretability. Compared with the state-of-the-art models, PT-STGNN demonstrated superior predictive performance, particularly for a longer-term prediction (i.e., 12 h), with MAE, RMSE and MAPE at 12-h prediction horizon of 2.737 ± 0.040, 4.209 ± 0.060 and 13.648 ± 0.151 %, respectively, for the algebraic mean of each parameter. From the results of graph structure learning, it is observed that there are strong dependencies between NH3-N and TN, TP and Q, as well as Precip, etc. This study innovatively applies STGNN, not only offering a novel approach for predicting influent WQPs and Q in WWTPs, but also advances our understanding of the interrelationships among various parameters, significantly enhancing the model's interpretability.