Geohazards have become one of the major threats for pipeline safety as catastrophic consequences can be induced by the ground displacement. To prevent pipe failure, multi-source monitoring technics have been adopted by pipeline operators in engineering practice. While the strain gauge monitored strain results are discretely distributed along the pipeline, which makes the most dangerous pipe section might be not derived directly via sensors. Therefore, it is of great significance to establish an accurate numerical simulation model based on digital twin technology in the geological disaster areas to predict the actual stress and strain status in pipelines. In this paper, an automatically generated parametrical finite element model was established by combining using the general nonlinear finite element software package ABAQUS and the numerical calculation software MATLAB. Numerous numerical strain results were generated as database for a multi-layer backpropagation artificial neural network regressing pipe’s strain state and the geohazard loading conditions (i.e. soil displacement, length of the geohazard areas etc.). Finally, particle swarm optimization algorithm was employed to obtain the most fitting geohazard loading conditions based on monitoring data. An actual case of a buried X65 crude oil pipeline in northeast China was considered as an example, results show that after 5 iterations a relatively accurate strain distribution along the pipe was obtained via the optimization results. The proposed method can be adopted in the integrity management of pipeline crossing geohazard areas.