Pollution poses a huge threat to the water ecosystem and human production and life, and emergency response to water pollution (WP) incidents has become an important issue. The simulation of the pollution dispersion process is particularly important, and the simulation results can provide an important reference for emergency rescue and emergency drills, helping to predict WP incidents and reduce the risk of accidents. With the development of computer technology and GIS technology, pollution dispersion simulation results can be expressed in numerical form or in the form of graphical data. In addition, this paper also combines the random forest (RF) algorithm to assess the risk of water environment pollution, analyze the characteristics of pollutant content in a river basin, and assess the health risk of groundwater quality in the basin. The results show that the contribution of carcinogenic risk of groundwater in the region is high for Cr in the dry period and as in the flat and abundant periods.