WikimapsAtlas / WikimapsAtlas-generator

A command line utility to convert heavy GIS sources into elegant administrative & topographic topojson files, raster files, and web friendly svg maps.
MIT License
46 stars 6 forks source link

Consider GADM as source for admin module #24

Open hugolpz opened 4 years ago

hugolpz commented 4 years ago

Sources

Npm toolchain

Former:

Output can be chained:

# download data
# source: https://gadm.org/download_country_v3.html 
curl \
    -L -C - 'https://biogeo.ucdavis.edu/data/gadm3.6/shp/gadm36_KHM_shp.zip' \ 
    -o ./KHM_adm.zip \
unzip -n ./KHM_adm.zip -d ./

topojson \
    --bbox \
    --id-property none \
    -p name=NAME_1 \
    -p code=ID_1 \
    -p L0=NAME_0 \
    -q 1e4 \
    --filter=small \
    -o KHM_adm.topo.json \
    -- admin_1=KHM_adm1.shp admin_2=KHM_adm2.shp

Shapefile

Screenshot_2020-10-09_14-21-30 Screenshot_2020-10-08_23-16-21 Screenshot_2020-10-08_23-18-20

Topojson

Command

npx topojson     --bbox     --id-property none     -p name=NAME_1     -p code=ID_1     -p L0=NAME_0     -q 1e4     --filter=small     -o KHM_adm.topo.json     -- admin_1=gadm36_KHM_1.shp admin_2=gadm36_KHM_2.shp

Screenshot_2020-10-09_14-24-28

curran commented 4 years ago

This would be epic. I'm interested in this.

See also https://github.com/mtraynham/gadm-topo

hugolpz commented 4 years ago

@curran, thanks for this hint it has great value :D This repository is ancient but that gives opportunity to upgrade it to gadm 3.6.

If you want to see the edge of what I'am doing, visually, it's on wikipedia. I'am in a friendly competition with an Belgian developer. He is damn good !

(These below are the output of my repository) Cambodia,_Rôtânôkiri_locator_map,_admin-topographic_relief_(2020)-en Cambodia,_Rôtânôkiri_locator_map,_admin_relief_(2020)-en Cambodia,_Rôtânôkiri_locator_map,_admin_blue_(2020)-en

curran commented 4 years ago

Very cool!