美文网首页工作生活
提取OSM行政边界的方法

提取OSM行政边界的方法

作者: 微雨旧时歌丶 | 来源:发表于2019-07-03 21:58 被阅读0次
boundary=administrative
admin_level=3 to 10
rel[admin_level=(level number)]
   [type=boundary]
   [boundary=administrative]
   [ (specific tag to identify the country, see below) ];
out geom;

--With the specific tags to identify the country (with XX=iso2 country code):
admin_level=2 > ["ISO3166-1"~"^XX"]
admin_level=3 > ["is_in:country"="XX"]
admin_level=4 > ["ISO3166-2"~"^XX"]

调用方法
URL:

https://wambachers-osm.website/boundaries/exportBoundaries?cliVersion=1.0&cliKey=52d97a3b-3fc1-44cd-bd9a-e8c1c9468bab&exportFormat=json&exportLayout=levels&exportAreas=land&union=false&selected=270056,913011,912940,913069,553303,153314,911844,286342,286937,2128285,912998,199073,407492,913110,913106,913073,161349,913012,913109,198590,912942,1867188,913101,153269,913100,913006,913067,913105,913068,912999,153292,153310,913094,553302

selected后边的数字就是relation的id号

使用命令 curl -f -o file.zip --url 'URL' 将会下载上述链接的内容,存储为文件
Don't forget the ' before and after the url!

相关文章

网友评论

    本文标题:提取OSM行政边界的方法

    本文链接:https://www.haomeiwen.com/subject/anwqhctx.html