Would be nicer if it would distinguish (just varying line thickness) between footpaths, roads, highways etc. Many European cities look messy in this view.
In the age of bloated resource hogs, I was pleasantly surprised that this rendered with no perceptible lag or stuttering, even on my phone. Impressive how everything is drawn so efficiently.
So, it's a filter on OpenStreetMap to retrieve all ways with a highway=* tag, and draw them identically?
I think a much faster and easier way to implement this would be using existing sources of vector tiles, but scaled down. You could probably even just use Mapbox GL JS, and scale the whole canvas down by a factor of 4 or something, to avoid the issue of small roads not being present at city-scale zoom levels.
I was intrigued by how many of the 3000 cities you’ve cached I had heard of. You used population size >100k as cutoff, it would be interesting to compare how many cities someone has heard of with their population size.
This would be a fun metric to rate someone’s “global orientation”.
Only recognize the cities with >1M people? Low GO score (or more charitably, high Local Focus score :-)
I'm in a city well under 50,000 people not in the Americas nor Europe. The site gave a message that it was retrieving the data from OSM, then rendered the map faster than the browser would render a png. Very impressive.
I'm at 10 minutes now, for a town of <15k. Render time might depend more on total area than number of lines to draw. Update: gave up after 20min. Something might be wrong with the particular city.
Render time for Seattle is a blink of the eye which has both area and density. I think the time people is observing is loading the raw data from open street map itself.
Because they cache the biggest cities in the world.
> To improve the performance of download, I indexed ~3,000 cities with population larger than 100,000 people and stored into a very simple protobuf format. The cities are stored into a cache in this github repositor
About 2 seconds for me to load and draw Los Angeles. It’s definitely the load time/network latency, depending on where it’s loading from. This is amazing! I might use it for a custom map or something
> To improve the performance of download, I indexed ~3,000 cities with population larger than 100,000 people and stored into a very simple protobuf format.
I was thinking that this would be a great gift, to print a set of dinner plates with every place that I know the couple lived in. Each plate a different city.
Though I'm a bit worried about paint near food, especially for custom jobs.
But I am a bit confused about the way it’s described. Is it unusual to see all the roads in a city drawn at once? Is the concept of ‘visualizing all the roads in a city’ one that we don’t have a name for? Is the creator from a parallel dimension where they only have tools that let you see one street at a time?
This is the level of projects that our GIS students deliver at the end of 60 hours of non-mandatory class. Perhaps 70%+ of visitors of HN can do it if they decide to, it is just an interdisciplinary area that not many explore. A project of similar complexity in the WEB or ML are would never get upvoted so much.
Are there are any tools that your GIS students use to create this? Or is it all code? Any libraries that you can recommend?
I was thinking that I would query the global database for roads and then take the nodes and their coordinates. Then I would need to convert those coordinates into points on a canvas and draw lines between them.
How would I get the boundaries of a city? Some places I've tried are just a point in osm. Is there some other data source you would use for that?
A combination of overpass turbo and a LLM would get you started pretty quick.
Regarding GIS tools, download QGis (it sucks on mac but is okay on linux or windows)
What is your point? That it's "undeserved" and that's bad somehow?
I think it was a cool visualization and fun to see. And still, 60 hours of research is more than I would put into it, so even if I technically was able to I would've never gotten around to actually do it. So nice to see something else than what I normally work with, even if it might be trivial in that domain.
IMO, prettymaps is quite a bit better: https://github.com/marceloprates/prettymaps
reply