Abstract:The construction of a regional ecological security pattern (ESP) is often based on the analysis of different levels and different depths of various environmental factors. Few scholars directly analyze the relationship between ecological security patterns and environmental factors and instead, tend to study only the general model. In this paper, using the logistic regression (LR) model of the big data computing framework Apache Spark machine learning library, we trained and tested the relationship between the ESP planning data and environmental factors and obtained the guaranteed security pattern model (GSPM). The ESP planning data were obtained from Gaoming, Sanshui, and Shunde districts in Foshan City. The environmental factors include 17 variables: lithology, soil texture, soil type, land cover, vegetation normalization index, elevation, slope, yin and yang aspect, curvature, distance to fault, distance to road, distance to river, distance to construction land, annual average rainfall, annual average temperature, annual average wind speed, and population density. GSPM was used to predict the ESP of Guangdong province. The results showed that (1) the accuracy of the GSPM reached 90.58%, the proportion of the high-probability area of the guaranteed ESP in Guangdong Province was 50.56%, and there is a certain reference value of this model; (2) The overall ESP of the prediction results is similar to the existing plans, but the model is susceptible to the uniformity of sample distribution; (3) GSPM prediction results are more in line with the needs of ecological resource protection, while the results of conventional method construction need further optimization; and (4) SPARK-LR machine learning has certain advantages on the prediction of urban expansion.