Skip to content

Need to add some usage=* values to the type key in the vector tiles #676

Closed

Description

@1ec5

Andrew S. reports on the forum that the more prominent rail rendering only applies to railways that are incorrectly tagged as having a name of usage=main. The following legacy filter and five others like it should be rewritten to compare usage to main, not name to usage=main:

https://github.com/OpenHistoricalMap/map-styles/blob/9d4f3cf8111d1f802fc99476b22939a170296753/ohm_timeslider_tegola/tegola-ohm.json#L3610

The work-in-progress rail style is also affected:

https://github.com/OpenHistoricalMap/map-styles/blob/9d4f3cf8111d1f802fc99476b22939a170296753/rail/rail.json#L3825

Activity

  1. vknoppkewetzel commented on Jan 16, 2024

    @vknoppkewetzel

    Thank you! Will work on this this week

  2. vknoppkewetzel commented on Jan 22, 2024

    @vknoppkewetzel

    I do not see "usage" in v tiles attributes

    image

    image

    image

    image

    image

  3. vknoppkewetzel commented on Jan 22, 2024

    @vknoppkewetzel

    Checking v tiles itself

    I know that we have discussed wanting another attribute added on so that we dont use name=usage=main

    image


    What I do see here is that industrial is name=industrial which is different than the other rails name=usage=XYZ in OHM vtiles

  4. vknoppkewetzel commented on Jan 22, 2024

    @vknoppkewetzel

    This may be a case where OpenSTREETMap has the data as usage=main but it doesn't exist in OHM tiles (yet)

    image

  5. vknoppkewetzel commented on Jan 22, 2024

    @vknoppkewetzel

    The tag usage=main is the correct way to designate main train lines. However the correct rendering of the main line with more prominent features only seems to work when the tag ‘name=usage=main’ is also included.

    Example, the only difference in tagging between the two lines shown here (at top left) at OpenHistoricalMap 1 is the presence of the name tag:

    image

    Tagging:
    name=usage=main
    railway=rail
    usage=main


    image

    The second rail is not showing up as main because it is not tagged as usage=name=main, It has no name tag at all so it only shows up in class=railyway and/or type=rail

  6. removed their assignment
    on Jan 22, 2024
  7. vknoppkewetzel commented on Jan 22, 2024

    @vknoppkewetzel

    I can be reassigned when vtiles are updated to include usage - flagging this ticket is an example of updating vtiles. On Wednesday we can chat about whom best to tag to do that work on the devseed side?

  8. 1ec5 commented on Jan 22, 2024

    @1ec5
    MemberAuthor

    Ah, that makes sense. I’ve been wondering when we added usage to the tiles that the style was even considering it already.

  9. vknoppkewetzel commented on Jan 31, 2024

    @vknoppkewetzel

    Last week in OHM carto meeting we chatted and noted that in some cases, we can grab usage via type in the interim.

    I can flag in this ticket which railways allow for that. This is an interim solution, as a path forward, we would either:

    1. create a new attribute called "usage" in the data or
    2. make sure usage is captured outside of the name=... and place usage into the type category. a minor issue here is that type=rail for some data, but perhaps that doesn't matter as class=railway, so type=rail is likely redundant.

    Option 2 seems like a good path forward. type=rail honestly is redundant, as class=railway

    image

  10. vknoppkewetzel commented on Jan 31, 2024

    @vknoppkewetzel

    Using testbed as reference
    image


    main
    image
    branch
    image
    industrial
    image
    military
    image
    tourism
    image
    spur (service=spur --> this already is how data is styled)
    image
    siding (service=siding --> already how data is styled)
    image
    rail (as catch all category - ie "what is classified as railway + rail but doesn't have other category")
    tram (already classified as type=tram
    image
    light_rail (styled as part of general rail category)
    image
    subway (type=subway, already styled as such)
    image
    narrow_gauge (type=narrow_gauge, styled in rail mini layer)
    image
    miniature (type=miniature, styled in rail mini layer)
    image
    monorail (type=monorail, styled in road_rail_tram)
    image
    funicular (type=funicular, style in road_rail_tram)
    image
    rail construction (type=construction, styled in roads_rail_construction)
    image
    proposed (type=proposed, style in roads_rail_construction)
    image
    disused (type=disused --> roads_rail_old)
    image
    abandoned (type=abandoned --> roads_rail_old)
    image
    razed (type=raized --> road_rail_old)
    image
    preserved (type=preserved, in roads_rail layer)

  11. vknoppkewetzel commented on Jan 31, 2024

    @vknoppkewetzel

    Confirming it is the following that need to have their type replaced with the below:

    • main
    • branch
    • industrial
    • tourism
    • military

    and ideally we remove rail from type=rail in the data. class=railway already captures rail

  12. jeffreyameyer commented on Feb 28, 2024

    @jeffreyameyer
    Member

    @danrademacher - who's the right person to task with updating whatever files need to be modified? (config.toml?)

  13. changed the title [-]Historic style only prioritizes railways named usage=main[/-] [+]Need to add some `usage=*` values to the `type` key in the vector tiles[/+] on Feb 28, 2024
  14. jeffreyameyer commented on Feb 28, 2024

    @jeffreyameyer
    Member

    @1ec5 - I renamed this ticket - please double-check that I haven't mischaracterized the ask.

  15. 1ec5 commented on Mar 15, 2024

    @1ec5
    MemberAuthor

    That’s accurate – this is a top community request for a hopefully straightforward change to the TOML file.

  16. Rub21 commented on Mar 16, 2024

    @Rub21
    Member

    I found only 10 objects that has usage attribute, and I've added the usage attribute in Vtiles - staging. https://vtiles-staging.openhistoricalmap.org/#18.13/-32.93544/151.720113

    image Screenshot 2024-03-16 at 10 36 18 AM
  17. Rub21 commented on Mar 16, 2024

    @Rub21
    Member

    These are the objects that have the = character in their names. This can be fixed by manually adding the usage attribute to the names.

    ID Type Name
    198794313 rail service=siding
    198794315 rail service=spur
    198794320 rail railway=rail
    198794342 rail service=crossover
    198794343 rail service=crossover
    198794344 rail usage=branch
    198794345 rail usage=industrial
    198794346 rail usage=military
    198794347 rail usage=tourism
    198794350 rail usage=main
    198794351 rail service=yard
    198794352 rail service=yard
    198794353 rail service=yard
    198826862 rail Detroit, Lansing and Lake Michigan Railroad=
    199864851 rail usage=main
    199872812 rail usage=main
    199872814 rail usage=industrial
  18. Rub21 commented on Mar 19, 2024

    @Rub21
    Member
  19. added theissue type on Mar 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions