Giter VIP home page Giter VIP logo

unity-example-application-mike-gangl's Introduction


logo

Unity Example Application

Example application illustrating structure for Unity App Generator application repositories

unity-app-generator | app-pack-generator

Features

  • Demonstrates Unity application structure
  • Demonstrates Unity Jupyter notebook parameterization
  • Demonstrates use of Unity-py for interacting with STAC files

Requirements

  • Python 3.9
  • Jupyter
  • Papermill

Setup Instructions

Install required Python packages:

pip install -r requirements.txt

Discussion

The process.ipynb notebook file is designed to work either as an independent notebook or as part of an OGC application package. It is meant for illustrative purposes and doesn't do any "real" work. What it does is show the parameterization of application arguments using Papermill and the use of Unity stage-in and stage-out mechanisms. The actions taken in the notebok are simply to extract some metadata from a set of netCDF files and place them into a textual table that is written out as well as displayed in the notebook.

Parameters

Unity OGC applications rely upon using Papermill parameritzation of arguments. One of the cells is tagged with the parameters tag, indicating to Papermill which cell to inspect for insertion of values from the command line. See the app-pack-generator for more information on the formatting of parameters and the use of type hints.

stage-in

This notebook is connected to a Unity stage-in process through the input_stac_collection_file variable. This variable contains the location of a STAC feature collection file. That feature collection points to the input files used by the notebook. In our example notebook we use Unity-py to parse the file and obtain the full paths to the input files.

stage-out

In the example notebook output_stac_catalog_dir is the variable where the directory where a STAC catalog listing the output files should be placed. In the example we use Unity-py to create the output STAC catalog. The example gives the minimal amount of metadata necessary for writing a valid catalog file and corresponding item collection files.

Testing

The test/ directory contains some useful scripts for testing the example notebook with unity-app-generator. It requires that package to be set up in your environment.

The test/ogc_app/build_app.sh script will use unity-app-generator to build a Docker image and CWL files from the repository.

The test/ogc_app/test_cwl.sh script can be used to test execution of the resulting CWL files. It requres that you first copy the cwl_job_input.yml.template file to be named cwl_job_input.yml in the same directory where it is located. Fill out the edl_username and edl_password values with base 64 encoded versions of your Earthdata Login credentials.

Changelog

See our CHANGELOG.md for a history of our changes.

See our releases page for our key versioned releases.

License

See our: LICENSE

unity-example-application-mike-gangl's People

Contributors

edwinsarkissian avatar mcduffie avatar mike-gangl 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.