I hereby claim:
- I am yohanboniface on github.
- I am ybon (https://keybase.io/ybon) on keybase.
- I have a public key ASBug1SfdjvvVkzo5xTk5oXG4tYSCrg4enKNeccZZU-Gngo
To claim this, I am signing this object:
| import re | |
| import time | |
| from lxml import etree | |
| from pymongo import MongoClient | |
| from minicli import cli, run | |
| client = MongoClient() | |
| db = client.mydb | |
| collection = db.disorders |
I hereby claim:
To claim this, I am signing this object:
| # put here the name of keys for ways that are assumed to be polygons if they are closed | |
| # see http://wiki.openstreetmap.org/wiki/Map_Features | |
| closed_ways_are_polygons=aeroway,amenity,boundary,building,craft,geological,historic,landuse,leisure,military,natural,office,place,shop,sport,tourism | |
| # comment to avoid laundering of keys ( ':' turned into '_' ) | |
| attribute_name_laundering=yes | |
| # uncomment to report all nodes, including the ones without any (significant) tag | |
| report_all_nodes=yes |
| # put here the name of keys for ways that are assumed to be polygons if they are closed | |
| # see http://wiki.openstreetmap.org/wiki/Map_Features | |
| closed_ways_are_polygons=aeroway,amenity,boundary,building,craft,geological,historic,landuse,leisure,military,natural,office,place,shop,sport,tourism | |
| # comment to avoid laundering of keys ( ':' turned into '_' ) | |
| attribute_name_laundering=yes | |
| # uncomment to report all nodes, including the ones without any (significant) tag | |
| #report_all_nodes=yes |
| from timeit import timeit | |
| class A: | |
| def __init__(self): | |
| self.kwargs = {} | |
| class B(dict): |
You need imposm3, postgresql, postgis, python 3.5, siege.
wget http://download.geofabrik.de/europe/france/ile-de-france-latest.osm.pbf
Import:
env PGHOST=/var/run/postgresql/ imposm3 import -mapping ~/Code/maps/pagesjaunes/mapping.yml -read ~/Data/geo/pbf/ile-de-france-latest.osm.pbf -write -connection="postgis:///pagesjaunes" -appendcache -deployproduction
| LOG_QUERIES = False | |
| LOG_NOT_FOUND = False | |
| EXTRA_FIELDS = [ | |
| {'key': 'citycode'}, | |
| ] | |
| FILTERS = ['type', 'postcode', 'citycode', 'city'] | |
| BLOCKED_PLUGINS = ['addok.pairs', 'addok.fuzzy', 'addok.autocomplete'] | |
| QUERY_PROCESSORS = [ | |
| 'addok_france.extract_address', | |
| 'addok_france.clean_query', |
| /* A Draggable that does not update the element position | |
| and takes care of only bubbling targetted path in Canvas mode. */ | |
| L.PathDraggable = L.Draggable.extend({ | |
| initialize: function (path) { | |
| this._path = path; | |
| this._canvas = (path._map.getRenderer(path) instanceof L.Canvas); | |
| var element = this._canvas ? this._path._map.getRenderer(this._path)._container : this._path._path; | |
| L.Draggable.prototype.initialize.call(this, element, element, true) | |
| L.DomUtil.addClass(element, 'leaflet-path-draggable'); |