Giter VIP home page Giter VIP logo

streetcomplete-taginfo-categorize's Introduction

Prerequisites

  • make, perl, JSON perl module, json_reformat (on Debian-based system: apt-get install make perl libjson-perl yajl-tools)
  • https://github.com/openstreetmap/id-tagging-schema repository in ../id-tagging-schema
  • https://github.com/streetcomplete/StreetComplete/ repository in ../StreetComplete

Usage instructions

Those scripts generate KEYS_THAT_SHOULD_BE_REMOVED_WHEN_PLACE_IS_REPLACED for the StreetComplete project.

make update should be run periodically, to find new keys with usage > 0.01% and add them to ## TODO ## section at the bottom of keys.txt file.

User should then investigate and move them from there to correct section like ### KEYS TO REMOVE ### or ### KEYS TO KEEP ### sections of keys.txt.

Running make again will then generate sc_to_remove.txt with kotlin code to copy/paste to https://github.com/streetcomplete/StreetComplete/blob/master/app/src/main/java/de/westnordost/streetcomplete/osm/Place.kt#L244 It is generated only from data in ### KEYS TO REMOVE ### section.

If in doubt, make distclean will force next make update to refetch everything

Notes on keys.txt format:

  • each line can contain a regex (or normal text) representing key (in-line comments are possible too, as everything after // or # is ignored
  • blank lines in ### KEYS TO REMOVE ### section will become newlines in sc_to_remove.txt
  • lines beginning with // in ### KEYS TO REMOVE ### section will be copied to sc_to_remove.txt
  • lines beginning with # are ignored completely

when IS_PLACE_EXPRESSION in Place.kt changes

If IS_PLACE_EXPRESSION in Place.kt changes (make update will warn you of that), then FETCH_KEYS.make / FETCH_TAGS.make should be updated too, and scripts re-run (i.e. make update + make) in order to generate new KEYS_THAT_SHOULD_BE_REMOVED_WHEN_PLACE_IS_REPLACED to put in Place.kt.

For example, if IS_PLACE_EXPRESSION was extended with:

+        or healthcare
+        or """ + mapOf(
+        "leisure" to listOf(
+            "adult_gaming_centre",
+            "amusement_arcade",

one would add healthcare to FETCH_KEYS.make, and leisure=adult_gaming_centre leisure=amusement_arcade to FETCH_TAGS.make

When one has completed updating FETCH_KEYS.make and FETCH_TAGS.make, they need to edit Makefile and update STREETCOMPLETE_LAST_GIT at the top of it with git commit id that changed Place.kt, i.e. the one returned by:

cd $STREETCOMPLETE_PATH && git log -n 1 --format='%h' -- app/src/main/java/de/westnordost/streetcomplete/osm/Place.kt

streetcomplete-taginfo-categorize's People

Contributors

floedelmann avatar matkoniecz avatar mnalis avatar rugk avatar smoothefiets avatar westnordost avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

streetcomplete-taginfo-categorize's Issues

repo description and readme

repo description

update list of tags combined with shop=, craft= etc. to populate and categorise tags related to inverse of KEYS_THAT_SHOULD_NOT_BE_REMOVED_WHEN_SHOP_IS_REPLACED in StreetComplete

can be

update list of tags combined with shop=, craft= etc. to populate and categorise tags related to KEYS_THAT_SHOULD_BE_REMOVED_WHEN_PLACE_IS_REPLACED listing in StreetComplete

I cannot open PR as it is defined not in repo but in github specific proprietary interface and I have no administration rights to change repository settings

Consider editing repository setings to remove "Packages" section

"Packages No packages published" is displayed right now, fortunately this pointless section can be removed.

Edit repo page config to remove it (cog next to the description).

I am not making a PR as it is defined in proprietary github settings, not in a git repository - and I have no rights to modify repo settings.

Peek 2020-10-25 09-10

Note that some are tricky

For example inscription

If someone made a common bad choice and mapped shop and building as one object then this tag can refer to something on building, unrelated to the shop.

In principle, support for such car could be implemented (for example asking user is given inscription still present) but it works be nasty to implement.

And for GNIS id it is even worse as there is no direct human readable form (and putting GNIS database into SC would be silly)

fhrs

When a POI with fhrs:id closes it should be removed, it's definitely about the shop/restaurant and not the building or address.

All other fhrs:* ( fhrs:local_authority_id fhrs:authority fhrs:rating fhrs:rating_date fhrs:hygiene fhrs:structural fhrs:confidence_management ) are basically deprecated and duplicate unnecessary data. They should also be removed when a POI closes, most of the time they should be removed even when while it's open.

isShopExpressionFragment updated

I updated isShopExpressionFragment, it now includes anything that could be in a (non-purpose-built) building, i.e. also any office, craft etc.

Right very now, it is still on the shops-overlay branch but I will merge it to master today.

Not sure what I need to do here, I'd rather leave this up to you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.