## 5 Conclusions  
To improve the accuracy of the in situ stress inversion, a PSO-BP in situ stress numerical analysis method was proposed and applied to the in situ stress inversion of the Shuangjiangkou Hydropower Station underground engineering. Based on the results of the numerical simulation, the feasibility of the method was verified, and the characteristics of the in situ stress distribution around the underground caverns were obtained. The main conclusions are drawn as follows:  
1. The complex geological movements can be decomposed into six basic boundary conditions for numerical simulation, and the PSO-BP neural network can then identify the optimal boundary conditions that best represent the measured in situ stresses.
2. The average relative error of the inversion results obtained by the proposed method is 3.45% lower than those obtained by the traditional method; thus, the proposed method is more effective and the inversed in situ stress distribution is more reasonable.
3. The distribution of in situ stresses increases as the buried depth of rock increases. The first principal stress ranges from 20 to 26 MPa, with stress concentration around the river valley. The third principal stress ranges from 14 to 18 MPa and is oriented approximately vertically.
4. Fault F1 and the lamprophyre notably influence the stress distribution in the main powerhouse area, with 15-30% localized stress reduction in the rock mass within 10m, which may provide a reference for similar engineering with weak structural planes.  
Conceptualization, H.-C.Y., H.-Z.L. and L.Z.; Data curation, Y.L. and K.-P.C.; Formal analysis, H.-C.Y.; Funding acquisition, H.-Z.L.; Investigation, H.-C.Y.; Methodology, H.-C.Y., H.-Z.L. and L.Z.; Project administration, M.-L.X.; Resources, H.-Z.L. and Y.L.; Software, H.-C.Y. and J.-M.W.; Validation, H.-C.Y.; Writing--original draft, H.-C.Y.; Writing--review and editing, H.-C.Y., H.-Z.L., L.Z., M.-L.X., K.-P.C., J.-M.W. and J.-L.P. All authors have read and agreed to the published version of the manuscript.  
This research was funded by the National Natural Science Foundation of China (No. 52109135), and the Postdoctoral Research Foundation of China (2019M653402).  
Data Availability Statement: Data sharing is not applicable.  
\begin{table}
\begin{tabular}{c c c c c c c c} \hline
**Test No.** & **Algorithm** & \(\sigma_{\textbf{y}}\)**/MPa** & \(\sigma_{\textbf{y}}\)**/MPa** & \(\sigma_{\textbf{z}}\)**/MPa** & \(\tau_{\textbf{x}\textbf{y}}\)**/MPa** & \(\tau_{\textbf{y}\textbf{z}}\)**/MPa** & \(\tau_{\textbf{x}\textbf{y}}\)**/MPa** \\ \hline \multirow{4}{*}{1} & Measured & 16.92 & 23.50 & 15.04 & 4.44 & \(-\)3.19 & 1.54 \\  & BP & 14.50 & 21.07 & 13.47 & 0.69 & \(-\)2.18 & 1.29 \\  & PSO-BP & 18.33 & 20.07 & 14.83 & 1.02 & \(-\)2.63 & 1.22 \\ \hline \multirow{4}{*}{2} & Measured & 19.26 & 22.74 & 16.66 & 0.33 & \(-\)7.11 & 4.71 \\  & BP & 14.36 & 21.87 & 13.31 & 0.47 & \(-\)1.88 & 1.45 \\  & PSO-BP & 18.08 & 20.91 & 14.45 & 1.12 & \(-\)2.18 & 1.27 \\ \hline \multirow{4}{*}{3} & Measured & 10.21 & 15.95 & 9.10 & 0.86 & \(-\)2.60 & -0.52 \\  & BP & 10.52 & 19.21 & 8.75 & 1.21 & \(-\)0.21 & 0.71 \\  & PSO-BP & 11.98 & 18.10 & 9.41 & 1.63 & \(-\)0.80 & 0.37 \\ \hline \multirow{4}{*}{4} & Measured & 18.64 & 21.86 & 13.56 & 4.29 & \(-\)2.47 & 6.81 \\  & BP & 14.22 & 23.49 & 13.21 & 1.30 & \(-\)1.92 & 1.82 \\  & PSO-BP & 17.72 & 22.48 & 14.02 & 1.69 & \(-\)2.34 & 0.73 \\ \hline \multirow{4}{*}{5} & Measured & 15.84 & 22.18 & 24.01 & 1.64 & \(-\)3.61 & 1.37 \\  & BP & 14.27 & 24.38 & 13.33 & 1.61 & \(-\)2.07 & 0.95 \\ \cline{1-1}  & PSO-BP & 17.96 & 23.49 & 14.00 & 2.65 & \(-\)2.45 & 0.79 \\ \hline \end{tabular}
\end{table}
Table 6: Computational stress components at test points. A comparison of the computational stress of the two back analysis methods.  
Conflicts of Interest: The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.