Coder Social home page Coder Social logo

refuel's Introduction

refuel

Create mbtiles of vector tiles from GeoJSON tiles online, using mokuroku.csv.gz

Background

This is a preliminary experiment.

Install

$ git clone [email protected]:hfu/refuel.git
$ cd refuel
$ npm install

Usage

$ npm run refuel 
$ tile-join -o experimental.mbtiles *.mbtiles

You need to have tippecanoe installed to run tile-join.

package.json and batch.js explains the detail of the processing. In the case of large scale tileset, you may need to run the commands one by one.

index.js

index.js is the script to download GeoJSON vector tiles, convert them to vector tiles, and the store the vector tile to a line of headless serialtiles.

The basic usage is:

$ node index.js fgd
# this will download experimental_fgd tiles and convert them.

This will have a long-lasting connection to mokuroku.csv.gz. Therefore, in the case of large tileset, you may want to download mokuroku.csv.gz beforehand to avoid timeout to the connection to mokuroku.csv.gz.

If you have fgd.mokuroku which is a copy of https://maps.gsi.go.jp/xyz/experimental_fgd/mokuroku.csv.gz, index.js can take the mokuroku as a second parameter. So, you can do as:

$ node index.js fgd fgd.mokuroku

hst2mbtiles.js

hst2mbtiles.js is a script to create mbtiles from hst file. This is a product of a separate project called hst2mbtiles.

index.js and hst2mbtiles can be piped, or the stored and the redirected.

See also

Technical elements

  • binarian is the basic code to convert a GeoJSON tile to vector tile.
  • stratify-spec is the specification to write a configuration for assigning a vector tile layer to a GeoJSON feature. This is necessary and data-dependent configuration when converting GeoJSON to vector tile.
  • mokuroku-stream is the basic code to get tile numbers from a mokuroku.csv.gz.
  • hst2mbtiles is a tool to convert headless serialtiles to mbtiles.
  • kirigami is a tool to cut mokuroku into modules.

refuel's People

Contributors

hfu avatar

Stargazers

Takayuki Miyauchi avatar

Watchers

 avatar James Cloos 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.