DigitalGeographyLab/green-path-server

Implement research mode to GP server

Closed this issue · 0 comments

To be divided into sub-tasks later.

A separate run mode for scientific use of GP routing is needed due to the following reasons:

  • More sensitivity coefficients should be used
    • to get more alternative paths with different properties (added distances, exposures etc.)
    • to better assess availability of unpolluted & quiet paths
  • ODs should not be snapped to nearest nodes -> nearest edges should be used
    • so that OD nodes are close to the real OD locations (as opposed to approximate "snapped" locations)
  • OD nodes that are created during routing should be persisted in the graph (rather than removed after each routing result)
    • Same OD nodes are likely to be needed in subsequent routing requests
    • Hence routing can be made a lot faster
  • Previously found nearest edges & nodes should be cached for faster routing
  • Routing results should not include individual edges with exposure values, but only the paths (as one GeoJSON FeatureCollection)
    • Edges are used for showing exposures on the map in the UI, but are not suitable to be analysed in exposure studies
    • Again, opportunity for better performance for routing larger number of ODs
    • If exposures need to be assessed at individual edges, it is better to add list of edge identifiers to path properties and then find respective exposures from the street network data (after routing analysis)
  • Researchers may want to use the routing functions with pure Python
    • as opposed to routing request to GP API (either in localhost or online)

Researchers should not use the online GP API due to the same reasons. Routing large number of ODs would take a long time and cause unnecessary load to the server. More accurate and faster results can be achieved by implementing at least some of the above and running GP server locally.

Todo

  • Test and update the installation instructions of green-path-server (done)
  • Discover required changes and add comments to the code for others to find them
  • Implement a separate run mode for research that disables unnecessary features and does the other tweaks listed above