Git Product home page Git Product logo

pystac's Introduction

PySTAC

Build Status PyPI version Documentation codecov Gitter chat License

PySTAC is a library for working with SpatialTemporal Asset Catalog in Python 3.

Installation

PySTAC has a single dependency (python-dateutil). PySTAC can be installed from pip or the source repository.

> pip install pystac

if you'd like to enable the validation feature utilizing the jsonschema project, install with the optional validation requirements:

> pip install pystac[validation]

From source repository:

> git clone https://github.com/azavea/pystac.git
> cd pystac
> pip install .

Versions

To install a specific versions of STAC, install the matching version of pystac.

> pip install pystac==0.5.*

The table below shows the corresponding versions between pystac and STAC:

pystac STAC
0.5.x 1.0.x
0.4.x 0.9.x
0.3.x 0.8.x

Documentation

See the documentation page for the latest docs.

Developing

To ensure development libraries are installed, install everything in requirements-dev.txt:

> pip install -r requirements-dev.txt

Unit Tests

Unit tests are in the tests folder. To run unit tests, use unittest:

> python -m unittest discover tests

To run linters, code formatters, and test suites all together, use test:

> ./scripts/test

Code quality checks

PySTAC uses flake8 and yapf for code formatting and style checks.

To run the flake8 style checks:

> flake8 pystac
> flake8 tests

To format code:

> yapf -ipr pystac
> yapf -ipr tests

You can also run the ./scripts/test script to check flake8 and yapf.

Documentation

To build and develop the documentation locally, make sure sphinx is available (which is installed with requirements-dev.txt), and use the Makefile in the docs folder:

> cd docs
> make html
> make livehtml

Use 'make' without arguments to see a list of available commands.

Note: nbsphinx requires that a local pystac is installed; use pip install -e ..

Runing the quickstart and tutorials

There is a quickstart and tutorials written as jupyter notebooks in the docs/tutorials folder. To run the notebooks, run a jupyter notebook with the docs directory as the notebook directory:

> PYTHONPATH=`pwd`:$PYTHONPATH jupyter notebook --ip 0.0.0.0 --port 8888 --notebook-dir=docs

You can then navigate to the notebooks and execute them.

Requires Jupyter be installed.

pystac's People

Contributors

brunobcardoso avatar chelm avatar cloudniner avatar darrenwiens avatar hectcastro avatar jisantuc avatar kbgg avatar lossyrob avatar schwehr avatar sgillies avatar simonkassel avatar tschaub avatar whatnick 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.