Changeset 5c71d35 in osmose-backend


Ignore:
Timestamp:
Mar 5, 2013 11:08:44 PM (7 years ago)
Author:
Frédéric Rodrigo <frodrigo@…>
Branches:
master
Children:
f8ca5b56
Parents:
2acbe50
git-author:
Frédéric Rodrigo <frodrigo@…> (02/03/2013 11:45:28)
git-committer:
Frédéric Rodrigo <frodrigo@…> (05/03/2013 23:08:44)
Message:

Complete Lausane hydrant support

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • analysers/analyser_merge_hydrant_point_ch.py

    ra206f70 r5c71d35  
    3535        pressure VARCHAR(254), 
    3636        ref VARCHAR(254), 
    37         source VARCHAR(254), 
    38  
     37        source VARCHAR(254) 
    3938    """ 
    4039 
    4140    def __init__(self, config, logger = None): 
    42         self.missing_official = {"item":"7120", "class": 1, "level": 3, "tag": ["merge", "hydrant"], "desc":{"fr":u"Borne hydrante non intégrée"} } 
     41        self.missing_official = {"item":"8090", "class": 1, "level": 3, "tag": ["merge", "hydrant"], "desc":{"fr":u"Borne hydrante non intégrée"} } 
     42        self.possible_merge   = {"item":"8091", "class": 3, "level": 3, "tag": ["merge", "hydrant"], "desc":{"fr":u"Borne hydrante, proposition d'intégration"} } 
    4343        Analyser_Merge.__init__(self, config, logger) 
    4444        self.officialURL = "http://www1.lausanne.ch/ville-officielle/administration/travaux/eauservice.html" 
    4545        self.officialName = "Bornes hydrantes" 
    46         self.csv_file = "Hydrants_Lausanne.csv" 
     46        self.csv_file = "merge_data/Hydrants_Lausanne.csv" 
    4747        # CSV header : 
    4848        # @id;@lon;@lat;emergency;fire_hydrant:type;fire_hydrant:pressure;ref:eauservice;source 
    49         self.csv_format = "WITH DELIMITER AS ';' NULL AS 'null' CSV HEADER" 
     49        self.csv_format = "WITH DELIMITER AS ';' NULL AS '' CSV HEADER" 
    5050        self.csv_encoding = "utf-8" 
    51         self.osmTags = { 
    52             "emergency": ["fire_hydrant"], 
    53             "amenity": ["fire_hydrant"], 
    54         } 
     51        self.osmTags = [{ 
     52            "emergency": "fire_hydrant", 
     53        },{ 
     54            "amenity": "fire_hydrant", 
     55        }] 
    5556        self.osmTypes = ["nodes"] 
    5657        self.sourceTable = "hydrant_point_ch" 
    57         self.sourceX = "lon" 
    58         self.sourceY = "lat" 
     58        self.sourceX = "lat" 
     59        self.sourceY = "lon" 
    5960        self.sourceSRID = "4326" 
    6061        self.defaultTag = { 
    61             "source": "eauservice" 
     62            "source": "Ville de Lausanne - 2013 - Eauservice" 
    6263        } 
    6364        self.defaultTagMapping = { 
     
    6667            "fire_hydrant:pressure": "pressure", 
    6768            "ref:eauservice": "ref", 
    68             "source": "source", 
    6969        } 
    7070        self.conflationDistance = 150 
    71  
Note: See TracChangeset for help on using the changeset viewer.