Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating custom vector tiles for places with indic labels #1

Open
planemad opened this issue Jul 6, 2020 · 6 comments
Open

Creating custom vector tiles for places with indic labels #1

planemad opened this issue Jul 6, 2020 · 6 comments

Comments

@planemad
Copy link

planemad commented Jul 6, 2020

From osm-in/osm-in.github.io#14 (comment)

The nextzen vector tiles used for the indic-map have some missing translations from OSM:

Place labels at low zoom tilezen/vector-datasource#977 (comment)

At lower zoom levels only Hindi and Bengali translations are available for cities. For other languages only the country name has the translated label.

Screen Shot 2020-06-28 at 12 27 48 PMScreen Shot 2020-06-28 at 12 30 15 PM

Suburb/neighbourhood names

These are coming from WOF and not OSM, so many of the localized labels are missing and also positioned incorrectly sometimes.

Screen Shot 2020-07-05 at 9 13 29 PM

OSM India place tiles

To overcome these limitations, we would need vector tiles that have the missing indic labels so that we can render all the available translations from OSM.

Data

All place= nodes in India. This should be less than 20MB and can be extracted daily just from the overpass API.

Tile Server

Self host

For full ownership, we would need to create our own tiles server, maybe with tegola+postgis or there maybe other option as well.

Hosting service

An easier alternative is to use an existing map tile hosting provider Mapbox Studio or Maptiler. OSM India already has a Mapbox coupon, so there's no need to worry about the hosting costs.

We could use tippecanoe to convert geojson to mbtiles that can be uploaded to Mapbox Studio.


This can probably be done quite easily and am happy to take a stab at writing a script that creates the vector tiles.

cc @tallytalwar @geohacker for any concerns

@tallytalwar
Copy link
Collaborator

Have to look at all these, but if translations are missing in nextzen tiles, can you also open an issue on tileszen repository? Whose-on-first, tileszen repos are maintained by x-mapzeners and should be able to address these if it's not a huge task wrt pipeline updates. I am not too familiar with server side kind of things but I would argue for nextzen tiles to be more coherent specially given that tangram supports all indic language rendering.

@planemad
Copy link
Author

planemad commented Jul 6, 2020

nextzen tiles to be more coherent specially given that tangram supports all indic language rendering

@tallytalwar 👍 will open a ticket. My guess is this is deliberately done to keep tile sizes low at low zoom. It would not be practical to have the labels for every city in the world to be available in every language in the world, so just ~20 major world languages are included tilezen/vector-datasource#977 (comment)

@tallytalwar
Copy link
Collaborator

tallytalwar commented Jul 6, 2020 via email

@planemad
Copy link
Author

planemad commented Jul 6, 2020

Sample indic-tileset

https://studio.mapbox.com/tilesets/planemad.6mk61jbn/

https://b.tiles.mapbox.com/v4/planemad.6mk61jbn/{z}/{x}/{y}.vector.pbf?access_token=

  • Export OSM place nodes:
  • Augment translations from Wikidata for points where wikidata is available.
  • Create mbtiles with tippecanoe tippecanoe -zg -o indic-places.mbtiles --drop-densest-as-needed --extend-zooms-if-still-dropping world-places-translated.geojson india-urban-places-translated.geojson india-rural-places-translated.geojson

Final mbtiles is <5Mb. This should be good to figure out what style change are necessary to fill in for the missing translations in the nextzen tiles.

Screen Shot 2020-07-06 at 1 09 43 AM

@answerquest
Copy link

So these place names are all point data only?

@planemad
Copy link
Author

So these place names are all point data only?

Yes. Although the script could work with any input geojson with a wikidata field and augment them with translations

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants