1.10.1 • Published 2 years ago

terrain50-cli v1.10.1

Weekly downloads
18
License
MPL-2.0
Repository
github
Last release
2 years ago

terrain50-cli

CLI for parsing Ordnance Survey Digital Elevation Model files

This is the CLI for the sister terrain50 library on npm for parsing Ordnance Survey DEM files in the ASCII Esri Grid format I also implemented.

Install

Install via npm:

npm install terrain50-cli --global

Usage

The command-line interface works on a subcommand-based system using applause-cli (another package of mine).

Display the usage information like this:

terrain50 --help

If you installed it locally, you'll need to do this:

path/to/node_modules/.bin/terrain50 --help

Environment Variables

Additionally, a number of environment variables are supported.

VariablePurpose
NO_COLORDisables ANSI escape codes in output (i.e. coloured output). Not recommended unless you have a reason.
QUIETSuppress all output except for warnings and errors (not fully supported everywhere yet)

Notes

image subcommand: --boundaries argument

This argument's purpose is the divide the incoming data into categories so that an AI can be potentially trained on the data (e.g. water depth data, as I'm using). It takes a comma separated list of values like this:

0.1,0.5,1,5

...and turns it into a number of bins like so:

  • -Infinity ≤ value < 0.1
  • 0.1 ≤ value < 0.5
  • 0.5 ≤ value < 1
  • 1 ≤ value < 5
  • 5 ≤ value < Infinity

Each bin is assigned a colour. Then, for each value in the input, it draws the colour that's assigned to the bin that the value fits into.

Read-world use

  • I'm using it for for my PhD in Computer Science!
  • (Are you using this project? Get in touch by opening an issue)

Contributing

Contributions are welcome as PRs! Don't forget to say that you donate your contribution under the Mozilla Public License 2.0 in your PR comment.

TODO: Use gunzip-maybe to transparently support reading from gzipped .gz input files

Licence

This project is licensed under the Mozilla Public License 2.0. See the LICENSE file in this repository for the full text.

1.10.1

2 years ago

1.10.0

2 years ago

1.9.0

3 years ago

1.8.0

4 years ago

1.7.0

4 years ago

1.6.6

4 years ago

1.6.5

4 years ago

1.6.4

4 years ago

1.6.3

4 years ago

1.6.2

4 years ago

1.6.1

4 years ago

1.6.0

4 years ago

1.5.0

4 years ago

1.4.1

4 years ago

1.4.0

4 years ago

1.3.0

4 years ago

1.2.0

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago