Giter Site home page Giter Site logo

sassalley / generate-vbb-graph Goto Github PK

View Code? Open in Web Editor NEW

This project forked from derhuerst/generate-vbb-graph

0.0 2.0 0.0 54 KB

Generate a JSON graph from Berlin & Brandenburg public transport.

Home Page: https://github.com/derhuerst/generate-vbb-graph

License: ISC License

JavaScript 100.00%

generate-vbb-graph's Introduction

generate-vbb-graph

Generate a JSON graph from Berlin & Brandenburg public transport Writes a JGF file. See vbb-graph for published prebuilt data.

npm version build status ISC-licensed chat on gitter support me on Patreon

Installing

npm install -g generate-vbb-graph

Usage

Usage:
    generate-vbb-graph [-p subway,tram]
Options:
    --products             -p  A list of products. These are available:
                               suburban, subway, regional, tram, ferry, bus
    --projection           -P  Wether and how to project the station coordinates.
                               See juliuste/projections for details.
    --simple-lines         -s  Use a heuristic to keep only the most "canonical"
                               variant of each line. Default: false
    --simple-deduplication -d  Deduplicate edges without taking the travel
                               time into account. Default: false
    --lines-blacklist      -b  Apply a blacklist of weird lines. Default: false
Examples:
    generate-vbb-graph -p subway,tram -P mercator

This tool generates data in the JSON Graph Format. Note that instead of storing all nodes and edges in one JSON file, it will create nodes.ndjson and edges.ndjson. These are ndjson-encoded lists of all nodes and edges, respectively.

A node from nodes.ndjson looks like this:

{
	"id": "900000029101",
	"label": "S Spandau",
	"metadata": {
		"x": 536.66,
		"y": 326.25
	}
}

An edge from edges.ndjson looks like this:

{
	"source": "900000100001",
	"target": "900000003201",
	"relation": "regional",
	"metadata": {
		"line": "RB22",
		"time": 180
	}
}

Contributing

If you have a question, found a bug or want to propose a feature, have a look at the issues page.

generate-vbb-graph's People

Contributors

derhuerst avatar greenkeeper[bot] avatar

Watchers

James Cloos avatar Joseph Bailey avatar

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.