Skip to content

vicchi/py-mapzen-whosonfirst-placetypes

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

py-mapzen-whosonfirst-placetypes

Install

sudo pip install -r requirements.txt .

Important

The specification for placetypes is derived from the whosonfirst-placetypes package. For example:

$> /usr/local/mapzen/whosonfirst-placetypes/bin/compile.py | python -mjson.tool 
{
    "102312307": {
        "name": "country",
        "names": {},
        "parent": [
            102312335,
            102312309
        ],
        "role": "common"
    },
    "102312309": {
        "name": "continent",
        "names": {},
        "parent": [
            102312341
        ],
        "role": "common"
    },
    "102312311": {
        "name": "region",
        "names": {},
        "parent": [
            102312307
        ],
        "role": "common"
    }
    ...
}

The specification itself is hardcoded in mapzen/whosonfirst/placetypes/_init_.py. Whether or the specification can or should be loaded from a config file or equivalent has been left for another day.

See also

About

Python library for working with Who's On First placetypes

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 98.9%
  • Makefile 1.1%