GithubHelp home page GithubHelp logo

poi_extractor_osm_to_gpi's Introduction

Super Easy Transformation of OSM Mapfiles to Garmin GPI

Prerequisites

you will have to install the follwing external tools:

"Installing"

  • make filter-nodes executable
  • move/copy it to a directory of your choice that is on your PATH or add your desired directory to your PATH
  • now you can run it from anywhere using filter-nodes
  • NOTE: the directory you're running the script from is going to be your working_directory

Steps to use:

1. Download desired area as *.pbf mapfile from https://extract.bbbike.org/

2. Customize POIs.yaml:

  • The file has to be in your working_path
  • Define POI categories
  • Define a radius (in meter) around each POI in which other POIs of the same category are deleted. Set this to a really really large number to keep all POIs
  • Define keys and valuess of Map Features that you want extract from the map

3. Download POI-Icons as *.bmp (for example from this website)

  • The icons have to be named the same as the categories and be placed into {working_path}/Icons

4. Run the script with filter-nodes in your working_path

  • You don't need to specify the *.pbf file if there is only one in the directory. The script will automatically choose the first *.pbf file in the directory, if there are more than one present and no -pbf argument was given.

Done!

poi_extractor_osm_to_gpi's People

Contributors

reneas avatar hendricokakiko avatar

Stargazers

Lukas avatar

Watchers

 avatar

Forkers

hendricokakiko

poi_extractor_osm_to_gpi's Issues

tag title + tag value

k = tag.get('k')
v = tag.get('v')
tag_text = f"{k} = {v}" einbauen. ausserdem einfach alle tags nehmen

for node in root.findall('node'):
    tags = []
    for tag in node.findall('tag'):
        k = tag.get('k')
        v = tag.get('v')
        tag_text = f"{k} = {v}"
        tag_text = '&#xA'.join(tag_text[i:i+35] for i in range(0, len(tag_text), 35))
        tags.append(tag_text)
    tag_string = '&#xA'.join(tags);
    node.clear()
    node.set('node_id', tag_string)

bei deinem code wird nach 35 zeichen ein zeilenumbruch eingebaut, mit meinem schnipsel alle 35 zeichen eines tags.

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.