mapbox / road-diff

A Tile Reduce script for vector tiles road network comparison.
ISC License
9 stars 9 forks source link

Improve documentation and code comments #1

Closed miles-dev closed 7 years ago

miles-dev commented 7 years ago

Working on a project to better understand how to use this repo. Using South Sudan as a sample use case for diff'ing.

Goals:

  1. Primary: use this project to produce geojson which represents the new roads in OSM within South Sudan when comparing January 2017 with January 2016.
  2. Secondary goal is to document the steps necessary to produce this and update the README.md in this repo for future use.

Resources:

/cc @tcql

miles-dev commented 7 years ago

Current status:

miles-dev commented 7 years ago

@tcql - Inspecting the geojson I got back, I noticed that I'm getting results which doesn't look like roads to me. As an example, https://www.openstreetmap.org/edit?way=466049354#map=16/8.7761/27.4289. The large straight line marking the edge of the grasslands there is coming back in my diff. Given that isn't a road I wouldn't expect it to be part of my results. Does this look like an incorrectly mapped feature or something not being filtered out in this repo?

mourner commented 7 years ago

@miles-dev the diff.js script only considers lines with highway property and Tiger roads with FULLNAME property. You may need to modify this line: https://github.com/mapbox/road-diff/blob/master/diff.js#L61

mourner commented 7 years ago

I'll close this since this is not an actual, actionable issue with the repository. It's a working example of using linematch for road diffing in TileReduce, and tweaks when using other data sources are expected.

mourner commented 7 years ago

On a second thought, let's keep this open until we improve the readme and code comments to make it easier to customize for various use cases.

miles-dev commented 7 years ago

Created a new branch osm_to_osm_diff which includes the updated README.md as well as changes to the index.js and diff.js to specifically target OSM vs OSM diffing. End goal here is for that to be 'walk up usable' with little to no code adjustment when diffing two OSM mbtiles files.

miles-dev commented 7 years ago

Question for @mourner and @aaronlidman - What're your thoughts on me merging my new osm_to_osm_diff into master? The differences as I'm tracking them:

mourner commented 7 years ago

@miles-dev I'm not sure about making OSM vs OSM the default implementation. I think OSM vs Tiger is a more common use case (comparing different datasets).

miles-dev commented 7 years ago

@mourner - Sounds good. I'll leave this as a separate branch for now then. I think I'm all set here with updating the readme and updating the code for osm-to-osm diffing. Closing out this ticket.