TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Flatmap – a new tool to make vector tiles from OpenStreetMap data fast

158 pointsby zylepeover 3 years ago

14 comments

zylepeover 3 years ago
Creator here. I maintain <a href="https:&#x2F;&#x2F;onthegomap.com" rel="nofollow">https:&#x2F;&#x2F;onthegomap.com</a> as a side project. I originally used Google Maps API but after their price hike switched to OpenStreetMap data. I self-host GraphHopper for routing and tried to self-host OpenMapTiles but gave up and used Stadia Maps since it would have taken over 100 days [1] to generate a map of the world myself. Stadia Maps has been great and I highly recommend them, but the problem continued to nag me, so earlier this year I started prototyping a new way to generate vector tiles faster. The idea worked and ended up being able to generate a ~100GB planet.mbtiles file in as little as 59 minutes on a single c5ad.16xlarge instance with 64 cpus and 128GB RAM (although smaller machines appear to be more economical).<p>I’m open-sourcing Flatmap today. Let me know what you think, or if you have any suggestions!<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;openmaptiles&#x2F;openmaptiles&#x2F;issues&#x2F;654#issuecomment-724606293" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;openmaptiles&#x2F;openmaptiles&#x2F;issues&#x2F;654#issu...</a>
评论 #28990692 未加载
stevageover 3 years ago
Looks great! Potentially a game changer for projects that need a basemap for a smallish area (like one country), get a fair bit of traffic, but don&#x27;t have budget for ongoing tile subscriptions to Mapbox or MapTiler.
tony_cannistraover 3 years ago
This is really sweet, awesome work. I really love onthegomap too.<p>I maintain an openmaptiles pipeline, and we&#x27;ve got our planet runtimes down to about ~4 days on AWS.<p>Would be excited to see if we could use this tool, but we really heavily depend on PostGIS data manipulation to ensure that the data we want ends up in our output tiles. How difficult do you think migrating this SQL to your tool would be? It seems like you can support modifying the data fairly heavily, both before and after MBtile creation.
评论 #28992923 未加载
RicoElectricoover 3 years ago
Nice :)<p>There&#x27;s an ongoing effort to research vector tile solutions for openstreetmap.org. I wonder how your software stack compares to tilemaker, which has seen some optimization lately.<p><a href="https:&#x2F;&#x2F;github.com&#x2F;openstreetmap&#x2F;operations&#x2F;issues&#x2F;565" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;openstreetmap&#x2F;operations&#x2F;issues&#x2F;565</a>
评论 #28988530 未加载
lalaland1125over 3 years ago
Nice tool OP, but I think we as a community should try to avoid creating tools that use already common names.<p>Googling &quot;flatmap&quot; gives a bunch of bad results. There is a value in having unique names.
评论 #28994272 未加载
MattBlissettover 3 years ago
This looks great!<p>I hacked around with OpenMapTiles to generate vector tiles in Arctic, Antarctic and WGS84 projections (the latter with 2×1 tiles at zoom 0) [1]. The time spent waiting for PostGIS to do reprojections etc made development very slow, and I&#x27;ve put off updating the tiles.<p>This tool is reprojects from WGS84 to Web Mercator while reading the tiles, so optimistically changing that would be much of what&#x27;s needed.<p>[1] See the map at the bottom of gbif.org, there&#x27;s a button to change the projection
willcodeforfooover 3 years ago
Thanks so much for this tool! Looks like one could generate a planet with less than $5 on Digital Ocean.
评论 #28992692 未加载
epaulsonover 3 years ago
A bit off-topic, but do people who host their own map tiles worry that other apps will use&#x2F;abuse their tileserver? I would worry that I&#x27;d come in one Monday morning and discover that I&#x27;ve got a $20K bandwidth bill because someone else got popular.
评论 #28994871 未加载
ryantgtgover 3 years ago
We self-host OpenMapTiles, but are super lazy about replacing them with updated tiles (and we don’t love the watermark). I’m really glad that there are options for generating them ourselves! Starred, and will give it a try soon.
durkieover 3 years ago
at that cost it almost feels like something internet archive or aws open data could provide on a regular basis. the cost of pre-made vector tiles is huge, and making them yourself has been a huge ordeal before this...
jmnicolasover 3 years ago
&gt; at least 1.5x as much free RAM as the input .osm.pbf file size<p>Ouch! Is there any plan to reduce the amount of ram or it&#x27;s impossible?<p>I&#x27;m currently building a tile server with Europe&#x27;s map, the PBF is 28GB, I have 32GB ram.
评论 #28995037 未加载
评论 #28994103 未加载
tschesnokover 3 years ago
This is cool. I will dig in deeper and take a look. I&#x27;m working on a spherical display.. so maps with fast zoom will be a must.
reichardtover 3 years ago
Fantastic work! Are the vector tiles compatible with OpenMapTiles styles?
评论 #28992549 未加载
tantalorover 3 years ago
Clever name... but not exactly unique.