Skip to content
Aaron Pulver edited this page Nov 7, 2016 · 7 revisions

##Welcome to the PySpatialOpt wiki!

PySpatialOpt is an open-source spatial optimization library. It has bindings for arcpy and pyqgis. PySpatialOpt uses PuLP to build and solve the optimization models. PuLP supports several solvers so these spatial optimization models can easily be solved with the optimizer of your choice.

Coverage Configurations

PySpatialOpt uses dictionary/json to store the relationships between facilities and demand units. Details can be found in Generating the coverage configurations.

Models

Currently the main focus is on coverage modeling though other optimization models may be added over time. See choosing the right model for information about each model. The following models are supported:

  • Maximum Coverage Location Problem (MCLP)
    • Church, Richard, and Charles R. Velle. "The maximal covering location problem." Papers in regional science 32.1 (1974): 101-118.
  • Maximum Coverage Location Problem with Complementary Coverage (MCLPCC)
    • Tong, D. (2012). Regional coverage maximization: a new model to account implicitly for complementary coverage. Geographical Analysis, 44(1), 1-14.
  • Threshold Model
    • Church, Richard, and Alan Murray. 2009. Coverage. In Business Site Selection, Location Analysis, and GIS. Hoboken, New Jersey: Wiley.
  • Complementary Coverage Threshold Model
    • Church, Richard, and Alan Murray. 2009. Coverage. In Business Site Selection, Location Analysis, and GIS. Hoboken, New Jersey: Wiley.
    • Tong, D. (2012). Regional coverage maximization: a new model to account implicitly for complementary coverage. Geographical Analysis, 44(1), 1-14.
  • Backup Coverage Location Problem (BCLP)
    • Hogan, Kathleen, and Charles Revelle. 1986. Concepts and Applications of Backup Coverage. Management Science 32 (11):1434-1444.
  • Location Set Covering Problem (LSCP)
    • Toregas, Constantine, et al. "The location of emergency service facilities." Operations Research 19.6 (1971): 1363-1373.
  • Backup Coverage Location Problem (BCLPCC)
    • Pulver, Aaron and Ran Wei. Presentation given at AAG 2016. San Fransico, CA.
    • Paper in review
  • Trauma Resource Allocation Model for Ambulances and Hospitals (TRAUMAH)
    • Branas, C. C., MacKenzie, E. J., & ReVelle, C. S. (2000). A trauma resource allocation model for ambulances and hospitals. Health Services Research, 35(2), 489.

Basic Workflow

  1. Load a spatial data into a feature (vector) layer
  2. Create a coverage(s) dictionary/json object by performing spatial operations to determine which facilities cover which demand areas (overlay, intersect ...)
  3. Merge any coverages created, if you want to incorporate multiple facility types (optional)
  4. Determine the serviceable demand assuming all facilities are used by performing spatial operations and update the coverage (optional)
  5. Generate the desired model (optionally write to file)
  6. Solve the model using whatever tools are supported py PuLP (Gurobi, GLPK...)
  7. Do something with the results (Map them, get stats...)

Several examples have been provided which show the basic usage. Sample data has also been provided; details can been found in Sample Data. It is very easy to integrate this into larger workflows. For example, you can automate the creation/exportation of maps showing the output configuration. In addition, you could tie this into a larger script that pre-process the features.

Clone this wiki locally