Quick workflow to setup and cut an osm file with a polygon file
##install osmconvert
wget -O - http://m.m.i24.cc/osmconvert.c | cc -x c - -lz -O3 -o osmconvert##move it to bin folder
cp osmconvert /usr/local/bin/osmconvert| # Table Population: The Facebook population data, inputted by CSV. Points | |
| # Table tzadmin: Tanzania administration boundaries. Polygons | |
| # Table fb_pop: The sum of population for a given admin feature ID | |
| # Table tzadmin_fbpop: The joined table that sums the sum of population and geographic features. | |
| #Generate the table with the right values | |
| CREATE TABLE population | |
| ( | |
| gid serial NOT NULL, | |
| the_geom geometry, |
| /* | |
| This has been generated by the overpass-turbo wizard. | |
| The original search was: | |
| “newer:"2016-07-14T19:01:00Z" and building=*” | |
| */ | |
| [out:json][timeout:25]; | |
| // gather results | |
| ( | |
| // query part for: “newer:"2016-07-14T19:01:00Z" and building=*” | |
| node(newer:"2016-07-14T19:01:00Z")["building"]({{bbox}}); |
Quick workflow to setup and cut an osm file with a polygon file
##install osmconvert
wget -O - http://m.m.i24.cc/osmconvert.c | cc -x c - -lz -O3 -o osmconvert##move it to bin folder
cp osmconvert /usr/local/bin/osmconvert| #!/bin/sh | |
| # To the extent possible under law, the person who associated CC0 | |
| # with this work has waived all copyright and related or neighboring | |
| # rights to this work. | |
| # http://creativecommons.org/publicdomain/zero/1.0/ | |
| SCRIPT_DIR=`dirname $0` | |
| if [ -e $1 ] ; then |