Live data from Hacker News

City Roads – Draw all roads in a city at once

anvaka.github.io

31–40 of 145 posts

Re: City Roads – Draw all roads in a city at once

#31
post #20

Hey there, I'm the author of the tool! Just wanted to thank you for the comments, feedback and shares! I 'm very happy! PS: If you liked that project you may find my other stuff interesting: https://twitter.com/search?q=from%3Aanvaka%20min_retweets%3A... - it's just a hobby but I love it :D

It's pretty cool mate. Gonna make a wallpaper with it.

Re: City Roads – Draw all roads in a city at once

#32

> Something went wrong. The error was: > { "statusError": 504, "message": "Unexpected status code 504 when calling https://overpass.openstreetmap.ru/cgi/interpreter" } And the referenced url 404s

Try a smaller city. This rendered almost immediately for me: https://anvaka.github.io/city-roads/?q=La%20Plata%2C%20Argen...

Re: City Roads – Draw all roads in a city at once

#33

It's definitely missing a lot of roads in my city. Compare it's view to Beaverton, Oregon: https://anvaka.github.io/city-roads/?q=Beaverton%2C%20OR&are... With the Google Maps view: https://www.google.com/maps/@45.5029349,-122.8365195,13.75z It's like most of the Cedar Hills neighborhood doesn't exist. It also drew a line for a power line where there is no road.

OpenStreetMap's definition of Beaverton is quite complicated: https://www.openstreetmap.org/relation/423111 It includes several cut-outs for neighborhoods (including Cedar Hills) and other features. I'd guess that the OSM mappers were trying to represent a particular legal definition of the Beaverton city limits. How accurate it is, I wouldn't know.

Perhaps in situations like this, "City Roads" might consider ignoring the cut-out enclaves and just using the mulipolygon's outer boundaries.

The power line showing up as a road is a mystery. If you can locate the corresponding feature on OSM you might want to investigate it. (There may in fact be a road or trail of some sort, though -- it's common for powerlines to have a track for maintenance vehicles.)

Re: City Roads – Draw all roads in a city at once

#34

It's definitely missing a lot of roads in my city. Compare it's view to Beaverton, Oregon: https://anvaka.github.io/city-roads/?q=Beaverton%2C%20OR&are... With the Google Maps view: https://www.google.com/maps/@45.5029349,-122.8365195,13.75z It's like most of the Cedar Hills neighborhood doesn't exist. It also drew a line for a power line where there is no road.

What OSM shows as matching the relation to the city is very strange. The boundary is so folded that I can't tell which parts are inside and which parts are very carefully excluded... If you look at other cities vs yours on OSM you'll see that it looks like most of Cedar Hills is excluded on OSM or rather the roads are their but it doesn't consider them part of the city.

Denver, CO: https://www.openstreetmap.org/relation/253750

Beaverton, Oregon: https://www.openstreetmap.org/relation/423111

Re: City Roads – Draw all roads in a city at once

#35
post #20

Hey there, I'm the author of the tool! Just wanted to thank you for the comments, feedback and shares! I 'm very happy! PS: If you liked that project you may find my other stuff interesting: https://twitter.com/search?q=from%3Aanvaka%20min_retweets%3A... - it's just a hobby but I love it :D

I don't know if open street data let's you monetize like this, but consider adding a link to Shutterfly or some similar site that would let the user get their road network of choice be printed out on a mug or t shirt.

A site featured on hn a few weeks ago which showed height renderings of various locales let you do something like that.

Re: City Roads – Draw all roads in a city at once

#37
post #35
post #20

Hey there, I'm the author of the tool! Just wanted to thank you for the comments, feedback and shares! I 'm very happy! PS: If you liked that project you may find my other stuff interesting: https://twitter.com/search?q=from%3Aanvaka%20min_retweets%3A... - it's just a hobby but I love it :D

I don't know if open street data let's you monetize like this, but consider adding a link to Shutterfly or some similar site that would let the user get their road network of choice be printed out on a mug or t shirt. A site featured on hn a few weeks ago which showed height renderings of various locales let you do something like that.

Do you remember the site that was submitted?

Re: City Roads – Draw all roads in a city at once

#38
post #37
post #35

Earlier quoted context omitted.

I don't know if open street data let's you monetize like this, but consider adding a link to Shutterfly or some similar site that would let the user get their road network of choice be printed out on a mug or t shirt. A site featured on hn a few weeks ago which showed height renderings of various locales let you do something like that.

Do you remember the site that was submitted?

Peak map: Visualize the elevation of any area using a ridgeline chart

https://news.ycombinator.com/item?id=21968874

Re: City Roads – Draw all roads in a city at once

#39

> Something went wrong. The error was: > { "statusError": 504, "message": "Unexpected status code 504 when calling https://overpass.openstreetmap.ru/cgi/interpreter" } And the referenced url 404s

Try a smaller city. This rendered almost immediately for me: https://anvaka.github.io/city-roads/?q=La%20Plata%2C%20Argen...

Now the site is not loading at all for me. Oops, there it goes. I think it could be overwhelmed.

I think it just does not have data on smaller towns and cities. I've tried several US smaller cities and nothing works. However, your link does. I can get San Diego and Irvine, CA. But I can't get Redlands or Yucaipa, CA. I can't get Polson, MT (nor Kalispell nor Helena).

Edit: Update - Finally got some data on Polson, MT.

Re: City Roads – Draw all roads in a city at once

#40

> Something went wrong. The error was: > { "statusError": 504, "message": "Unexpected status code 504 when calling https://overpass.openstreetmap.ru/cgi/interpreter" } And the referenced url 404s

Try a smaller city. This rendered almost immediately for me: https://anvaka.github.io/city-roads/?q=La%20Plata%2C%20Argen...

To fetch the roads I use overpass turbo API. They are sometimes slow and timeout and sometimes limit amount of requests that we can send. So I found three endpoints of overpass turbo and rotate between them: in case when one fails I go to the next one. If none was able to handle the request, I bail out and show the error.

That said, I also cached 3,000 cities with population over 100k citizens and try the cache first, before going to overpass. That may be the reason why it is fast in some cases and slow in others.

By the way if someone has more stable/fast overpass endpoints - I will be happy to add them to the list!

Post reply on HN