Underground pedestrian network generation from OSM. Level assumptions for Toronto PATH / Montreal RESO?

Hi all,

I’m building a game that procedurally generates underground pedestrian networks (Toronto PATH, Montreal RESO, etc.) from OSM data. The geometry generation is working well (corridors, shops, stairs, station enclosures) but I’m running into some challenges with level assignments and connectivity that I’d love community input on.

What works:

  • Extracting corridors, platforms, stairs/escalators from highway=footway + tunnel=yes / indoor=yes

  • Using level tags to separate floors

  • Placing shops from shop/amenity nodes with level tags (only kind of works because shops do not have structure footprint)

  • Identifying subway stations from station=subway nodes

Screenshot:

  • High overhead view of the generated network

  • Pink boxes = stairs to surface, grey boxes = elevators/underground stairs. Ceilings removed for debug visibility.

I know image looks bad, because of the challenges below:

  1. Inconsistent level tagging on subway platforms. Some platforms are tagged level=-2 (way 298852576, way 298852577), others level=-1 (way 34542613, way 63032409), and many have no level tag at all (way 684038824 “Yonge Street, King Station”, way 683577944 “University Avenue, St. Andrew Station”). Should I assume subway platforms are always one level below street, or respect the tagged level even when it creates disconnected islands?

  2. Half levels (level=-0.5). These appear as mezzanines in the PATH data (way 34121534, way 352702706). I’m currently snapping them to the nearest integer level. Is there a convention for how these should be interpreted, or are they genuinely distinct floors?

  3. Disconnected fragments. Many underground highway=service ways appear under buildings (parking garages, condo basements) but aren’t connected to the main pedestrian network (e.g. way 172728953). Is there a reliable way to distinguish “part of PATH” from “building basement service corridor” beyond checking PATH relation membership?

  4. Station to corridor connectivity. Station platforms often appear as isolated islands with no explicit corridor linking them to the pedestrian network. For example, King Station (node 34710076) has platform ways (way 684038824) but no mapped corridor connecting the platform to the PATH. Similarly St. Andrew (node 34710073, way 683577944). The connection is implied by proximity. Is there a tagging pattern I should look for, or is this a known mapping gap?

Assumptions I’m currently making:

  • Subway stations sit at level -1 (same as pedestrian network)

  • 5m floor to floor spacing (4m ceiling + 1m slab)

  • Escalators dropped for now (stairs only for vertical connections)

  • Service corridors not in the PATH relation are filtered out

If anyone has experience mapping or consuming underground networks, I’d appreciate any tips on tagging conventions, common data gaps, or better heuristics for level assignment.

Thanks!

1 Like

Hi, welcome! Here’s some Toronto-specific information that might help you:

Level tagging in OSM generally starts with ground level being 0 and counting from there.

This TMU platform is level=-1 because it is physically one level below the ground. At that station, there is no mezzanine. The passage between northbound and southbound platforms is actually below the platforms (level=-2), e.g. Way: ‪TMU Station Tunnel‬ (‪366868486‬) | OpenStreetMap

The St. Andrew platform is level=-2 because it is two levels underground. An underground concourse (Way: ‪St. Andrew Station Concourse‬ (‪34121539‬) | OpenStreetMap) is above the subway platform.

Way: ‪Yonge Street, King Station‬ (‪684038824‬) | OpenStreetMap and Way: ‪University Avenue, St. Andrew Station‬ (‪683577944‬) | OpenStreetMap are not subway platforms at all but instead streetcar platforms at street level. These are also tagged as railway=platform in OSM. However you can filter them out by checking for tram=yes tag.

Another issue you might run into is that level tagging differs in different buildings and areas, because of sloping ground: a level that’s underground at one end of the building is actually aboveground at the other end. This is especially the case for long buildings like the Eaton Centre. E.g. Way: ‪PATH Main Route‬ (‪96149584‬) | OpenStreetMap connects to TMU station southbound platform and has level=-1 as it is one level underground, but it corresponds to Eaton’s “Level 2”. If you follow that “Level 2”, it continues to Way: ‪Eaton Centre level 2‬ (‪127287708‬) | OpenStreetMap which connects to street level entrances even though it still has level=-1. Eaton’s “Level 1” is two levels below ground at Dundas Street, and one level below ground at Queen Street. Eaton’s “Level 3” is ground level at Dundas Street, one level above Queen Street, and connects to the second floor of the former Hudson’s Bay store.

Similarly, Way: ‪PATH Main Route‬ (‪1457181244‬) | OpenStreetMap at Union has level=-2;-1 and a note “Level -2 of Union Railway Station connects to Level -1 of Union Subway Station”. At south end of Union, Way: ‪PATH Main Route‬ (‪366040063‬) | OpenStreetMap similarly notes “Level -1 of Union Station connects to Level 0 of Scotiabank Arena”.

They might be distinct levels. Sometimes stairs or ramps connecting them to other levels might not be mapped. PATH has a fair amount of short stairs and ramps to connect height differences of a metre or two, and not all might be mapped yet.

To discuss a specific example, Way: ‪PATH Main Route‬ (‪61511478‬) | OpenStreetMap tagged level=-0.5 is below street level, but daylit, because the area to the south with the fountain and the reflecting pond is sunken. It connects to the staircase which connects it to Metro Centre’s level=-1 which is… more underground.

Depending on what you’re trying to map, just filtering out highway=service should do the job. Only look for footway, corridor, steps, elevator etc. I can’t think of a service roadway that’s part of what I would consider the PATH. (In real life, the walkway through Nathan Phillips Square parking garage has a bit of that characteristic, but in OSM it’s a footway anyway.)

See above - these particular ways are not subway platforms.

However, there are definitely cases of unconnected platforms. For example the Finch-bound platform at Union is connected only to the walkway to the (underground) streetcar platform. In real life, the subway platform also has connections to the main train station and the PATH, however they are not mapped yet. (This particular platform has a fixme tag noting this deficiency, but this is not guaranteed.)

4 Likes

Ce sera aussi un défi avec le réseau des corridors à Montréal qui s’étend sur des kilomètres avec un bon dénivellé de la rue Sainte-Catherine jusque plus bas dans le Vieux-Montréal. Déja un bon défi de représenter le trajet dans les corridors de la Place Ville-Marie au Palais des congrès où on monte descend, traversant des centres commerciaux, des tunnels sous les rues, parcourant de long corridors en pente. Plus évidemment quelques stations de métro.

Le tracé GraphHoper Place Ville-Marie au Palais des congrès par rues extérieures indique 1.2km.

https://www.openstreetmap.org/directions?engine=graphhopper_car&route=45.5022534%2C-73.5603967%3B45.5021778%2C-73.5682146#map=16/45.50242/-73.56342

Et il y a un important dénivellé tel qu’illustré sur la carte ci-dessous.

1 Like