OpenStreetMap

happygo's Diary

Recent diary entries

vacation mapping #2

Posted by happygo on 13 January 2020 in English (English).

panorama-25 View of manhattan southern tip, from empire state building

Home: is it where I sleep each night, or where I dream of? Spectre of globalism, shadow of the coastal elite - I may be angemeldet in Berlin, but New York will always feel something like home. Inevitably, I’m in the city about once a year, frequent enough to keep up friendships, but infrequent enough to inspire nostalgia for the last visit. It’s a place perpetually in a simultaneous state of metamorphosis and stasis. Gotham, or Girls? Sex and the city Carrie voiceover: “I couldn’t help but wonder, where were all the NYC mappers?”

map_reference-25

New York on one intersection: a Bank of America, a gay bar, a gourmet pizzeria, a 99c slice joint, a rusting frame chained to the fence, a $2,000 bike in the shop window. But on the map: it’s nothing but building=yes and address numbers. A homeless man phones a friend on a LinkNYC terminal, a businessman crosses the street without looking up from his iPhone. They hail a taxis, they wait for the M22. In a city where some people have everything, and some people have nothing, there are more ironic things than the lack of POIs in OSM.

self_portrait I couldn’t find evidence of an official shop=postal, or amenity=shipping, though there are a lot of these kinds of stores!

We chose a sunny day. We printed the screenshots at a FedEx, leaving plenty of blank space in the margins. For the next few hours, we mapped East 9th and 10th streets between 1st and 2nd Ave in the East Village. The system went: for each business not found in the map, write down house number and side of the street. Take a picture of the storefront in case we forget what it is, or to get opening hours.

For a neighborhood that has such an extensive Wikipedia page, a lot of it just looks like empty buildings in the map.

What else about New York…sometimes it’s just a blur of faces in the subway, or a looming facade of buildings as you’re coming out of the Holland tunnel. But sometimes you can take your time and look in to every store, browse a few things, observe people and guess if they’re locals or tourists, like you, just visiting, trying to find what makes this place different from everywhere else.

Location: Manhattan, New York County, New York, United States
  1. export and save data from openstreetmap.org
    • map.osm
  2. open qgis
  3. in qgis top menu, select Vector > OpenStreetMap > Import Topology from XML…
    • “Input XML file” < map.osm
    • rename “Output Spatialite DB file” to something unique, unique.osm.db
    • rename “Connection name” to something unique, unique_connection
  4. in qgis top menu, select Vector > OpenStreetMap > Export OpenStreetMap Topology to SpatiaLite…
    • “Input DB file” < unique.osm.db
    • Select the “Export type” that you’re interested in
    • Put a meaningful name in “Output layer name”
    • Hit “Load from DB”, and select/deselect the export type features with the tags you’re interested in
    • Hit “OK”
    • Repeat for all OSM feature types you’re interested in
  5. Pan around and inspect the features
    • Select layer to inspect in the “Layers Panel”
    • View specific features with the “Identify Features” tool, ctrl + shift + i

Vacation mapping

Posted by happygo on 23 August 2019 in English (English).

Avoid the crowds and tripadvisor, a vacation is only an adventure if you find the escape velocity of your known universe and reach it, and you’ll find outside that, another version of yourself that just might follow you home.

We had seen the soaring ceilings of the Hagia Sofia, I was already used to the chingchonglinglongs from shopkeepers in the Grand Bazaar, we went to the Blue Mosque on a day it was closed to non-believers, we’d eaten homemade sigarabörek by her aunt for dinner, we’d taken the ferry to the tip of the Asian continent… It was day 3 of Istanbul, and my best friend had a family engagement that night. I wasn’t brave enough to venture back to the Asian side to visit a nightclub on my own, and had been advised against going out by myself anyway.

What else do you do in a big, unknown city on a Friday night?

Idleness must have spurred me into opening OSM to inspect the unspectacularly residential neighborhood I was staying in. Idleness intensified the quiet thrill of finding a virtually blank map, composed of only the spidery, nameless street geometries. Idleness became a pulling curiosity, so I found blank pages in my day planner and two pens of different colors, and traced the general street network. I closed the door on the sound of my AirBnb host having sex with her boyfriend, careful to keep the cats inside.

For a couple hours that night I deliberately wandered the streets of that neighborhood. I developed a system where I numbered the streets in my notebook with a kind of index and wrote the names I saw on the street signs next to the numbers. Knowing the basics of the Turkish alphabet, I could sound out the names to myself as I saw them, carefully noting the dotless ı’s and the rounded hats on the ğ’s.

When I returned to the flat, I eagerly entered each new tag: name, highway, lit, foot, oneway. I even added a couple small, unmapped alleys. Zooming out on my work, I was shocked at how insignificant the changeset seemed for how many kilometers I had walked. But, all the same, it was a small constellation of mapped streets in a web of unnamed Istanbul neighborhoods.

mapping

Day 4, after another day of sightseeing, I went out again and ventured a bit further west. Once I couldn’t found a street sign and felt brave enough to stick my head into a travel bureau to ask, “hangi caddesi?”, hoping that my approximation of Turkish grammar was good enough (it was!). One night from the second floor windows of a fish restaurant where I had dinner I mapped the businesses I could see across the street: Ekin cafe, Simit evi, several burger places.

Which worlds do we visit when we exist only between pinned places in Google? Do we really visit a place if we only remember the characters in its name long enough to type it into the search bar, but never hold the sounds in our mouths?

Location: Çeliktepe Mahallesi, Kağıthane, Istanbul, Marmara Region, Türkiye

Wir haben gerade v5.6 der Open Source Routing Machine (OSRM) veröffentlicht. Wie gewohnt mit Dokumentation, NodeJs Bindings und einem osrm/osrm-backend:v5.6.0 Docker Image. Mehr Details gibt es hier. Sieht auch die Release Notes und den kompletten Changelog.

Was ich in diesem Beitrag vorheben möchte ist das Hauptfeature des 5.6 Releases: Die Trennung von Geschwindigkeiten und Kantengewichten

Bis zum 5.6 Release konnten Nutzer nur die Geschwindigkeiten per Lua Profile anpassen and diese basierend auf Tags und Präferenzen verändern. Die Routenplanung hat dann den schnellsten Weg gefunden und dabei die Zeit minimiert.

Allerdings gibt es klare Fälle in denen Nutzer bestimmte Strassen vermeiden möchten: schmale Gassen und Passagen über die normalerweise nicht gerouted werden sollte. Bisher konnten Nutzer diese Wege entweder komplett aus dem Strassennetz entfernen oder aber die Geschwindigkeiten künstlich herabsetzen. Die Geschwindigkeiten zu modifizieren hat jedoch einen gravierenden Nachteil: wenn die Routenplanung nun doch über eine solche Strasse führt sind die Ankunftszeiten falsch!

Was wir stattdessen benötigen ist eine Trennung von Geschwindigkeiten (und damit Reisezeiten welche die Routenplanung aggregiert) und Kantengewichte auf denen die Routenplanung optimiert. Mit dem 5.6 Release haben wir diese grundlegende Trennung!

In den Profilen können Nutzer nun:

  • Die Geschwindigkeiten weiterhin basierend auf Tags setzen um realistische Ankunftszeiten zu erhalten und
  • Spezielle Strassen vermeiden indem Kantengewichte unabhängig zu den Geschwindigkeiten verwendet werden.

Zusätzlich erlaubt uns die Trennung von Geschwindigkeiten und Kantengewichten die Handhabung von access=destination und ähnlichen Tags, die es erlauben die Strasse nur zu verwenden wenn sich das Ziel dort befindet. Ein typisches Beispiel sind Gated Communities durch die Nutzer nicht gerouted werden möchten, ausser sie wollen explizit ihre Reise dort enden.

Wir können solche Tags nun behandeln indem wir nur die Abbiegevorgänge auf solche Strassen mit einem hohen Gewicht versehen und gleichzeitig die realistische Turn Penalty unberührt lassen. Die Routenplanung vermeidet dann z.b. Gated Communities ausser Nutzer wollen explizit dort hin. Ankunftszeiten werden dabei nicht beeinflusst!

Ein Beispiel für Destination Routing gibt es hier. Destination Routing

Wir können den selben Trick für weitere Tags verwenden, beispielsweise für delivery, private oder customer access restrictions. Sogar für HOV-Strassen falls Nutzer diese normalerweise vermeiden möchten, aber trotzdem eine Route möchten falls sie explizit auf diesen Strassen unterwegs sind.

Wir freuen uns gerne auf Feedback zu anderen Tags die wir ähnlich handhaben sollten; einfach in die Diskussion einsteigen.

Wir werden auch auf der FOSSGIS Konferenz dieses Jahr sein - Kommt vorbei und sagt Hallo!

Location: Mitte, Berlin, Germany

We’ve just released version 5.6 of our beloved Open Source Routing Machine (OSRM). The release comes with documentation, NodeJs bindings and a osrm/osrm-backend:v5.6.0 Docker image for an easy setup. More details here. See the Release Notes and the Full Changelog for more details.

What I want to highlight in this post is the 5.6 release’s main feature: Making Travel Time and Edge Weights Independent

Up until the 5.6 release users were able to adjust way speeds based on tags and their preferences via user-provided Lua scripts. The routing engine then did fastest path routing minimizing for duration.

Now there are use-cases for which you want to penalize certain ways: think alleys or small roads which you don’t want the routing engine to prefer. Before the 5.6 release all you could do was to either discard those ways completely or adjust their speeds and make them artificially slower. Adjusting speeds sounds like the way to go, but if the routing engine then really needs to route you over such a way your ETAs will be off by the adjusted amount.

What we instead need is a split between travel time the routing engine aggregates along the way and edge weights the routing engine minimizes. With 5.6 we finally made that major architectural switch.

In your profiles you can do both now:

  • Fine-tune way speeds based on tags to make for great and realistic ETAs and
  • Penalize ways by setting edge weights independently of speeds.

In addition we can handle restricted ways now, too. By restricted ways I mean access=destination and similar which you are only allowed to travel on if you are going to this area. A typical example are gated communities which you don’t want to get routed through except you explicitly want to go there.

We do this by penalizing the turns onto such restricted ways setting a very high turn weight but keeping the turn penalty duration untouched. The routing engine will now only ever route you e.g. into gated communities if there is no other option and the user explicitly wants to go there. The ETAs won’t be affected at all!

Here is an example of destination routing for when we really want to go there: Destination Routing

We can make use of this technique for certain other tags: think of delivery, private or customer access restrictions. Or even for HOV-ways if you normally want to avoid HOV ways but want the routing engine to still give you routes when you drive your car on a HOV way and re-routing triggers.

If you know of other tags we should penalize this way, feel free to jump into the discussion.

This feature is included in the latest OSRM v5.6 Release. We’re always glad for user feedback; in case you stumble over issues like this please talk to us! You can find us in the OSRM Repository on IRC and on the osrm-talk mailinglist.

We will also be at this year’s FOSSGIS conference - stop by and say Hi!

Location: Mitte, Berlin, Germany