From b3b097ca16a77b51b736d9be014ceedacb494a9b Mon Sep 17 00:00:00 2001 From: randogoth Date: Wed, 26 Feb 2025 14:22:22 +0000 Subject: [PATCH] just lookup --- .gitignore | 3 ++- .justfile | 17 ++++++++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index b2cb0f9..3ca0331 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ *.parquet -*.pbf \ No newline at end of file +*.pbf +*.png \ No newline at end of file diff --git a/.justfile b/.justfile index 47b44fc..157d50e 100644 --- a/.justfile +++ b/.justfile @@ -10,4 +10,19 @@ convert input output: plot file: #!/usr/bin/env bash stem=$(basename {{file}} .parquet) - python3 plot.py -i {{file}} -o ${stem}.png \ No newline at end of file + python3 plot.py -i {{file}} -o ${stem}.png + +process file: + #!/usr/bin/env bash + stem=$(basename {{file}} .pbf) + echo "Extracting Data from OpenStreetMaps PBF" + quackosm {{file}} --osm-tags-filter-file tags.json --compact --output ${stem}.parquet + echo "Generating geohash parquet files" + python3 slice.py --input ${stem}.parquet --output geohash + echo "Cleaning up" + rm ${stem}.parquet + +lookup lat lon: + #!/usr/bin/env bash + lat=$(echo "{{lat}}" | tr ',' ' ') + python3 lookup.py $lat {{lon}} \ No newline at end of file