generated from stactools-packages/template
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: define separate collections for each product, define GRIB layer…
…s with byte ranges in 'grib:layers' asset metadata (#6) * define collection + item + asset structure * add grib:layers asset property for describing layers within GRIB2 files
- Loading branch information
Showing
51 changed files
with
282,397 additions
and
981 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
pres | ||
parm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -138,3 +138,8 @@ dmypy.json | |
|
||
# Cython debug symbols | ||
cython_debug/ | ||
|
||
scratch | ||
.Trash-0 | ||
.virtual_documents | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,124 @@ | ||
# stactools-template | ||
|
||
This is a template repo used for creating new packages for `stactools`. | ||
|
||
## How to use | ||
|
||
1. Clone this template repository as your package name, e.g. `landsat`. | ||
This name should be short, memorable, and a valid Python package name (i.e. | ||
it shouldn't start with a number, etc). It can, however, include a hyphen, in | ||
which case the name for Python imports will be the underscored version, e.g. | ||
`landsat-8` goes to `stactools.landsat_8`. Your name will be used on PyPI to | ||
publish the package in the stactools namespace, e.g. `stactools-landsat`. | ||
2. Change into the top-level directory of your package and run `scripts/rename`. | ||
This will update _most_ of the files in the repository with your new package name. | ||
3. Update `pyproject.toml` with your package description and such. | ||
4. Install with the development requirements (`pip install -e '.[dev]'`). | ||
5. Update the LICENSE with your company's information (or whomever holds the copyright). | ||
6. Edit or replace the existing functions to create stac Items and Collections | ||
for your dataset. | ||
7. Add example Items (and Collections and Catalogs, if included) to an | ||
`examples/` directory. | ||
8. Delete this file, and rename `README-template.md` to `README.md`. Update your | ||
new README to provide information about how to use your package. | ||
# stactools-noaa-hrrr | ||
|
||
[![PyPI](https://img.shields.io/pypi/v/stactools-noaa-hrrr?style=for-the-badge)](https://pypi.org/project/stactools-noaa-hrrr/) | ||
![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/stactools-packages/noaa-hrrr/continuous-integration.yml?style=for-the-badge) | ||
|
||
- Name: noaa-hrrr | ||
- Package: `stactools.noaa_hrrr` | ||
- [stactools-noaa-hrrr on PyPI](https://pypi.org/project/stactools-noaa-hrrr/) | ||
- Owner: @hrodmn | ||
- [Dataset homepage](https://rapidrefresh.noaa.gov/hrrr/) | ||
- STAC extensions used: | ||
- [forecast](https://github.com/stac-extensions/forecast) | ||
- [item-assets](https://github.com/stac-extensions/item-assets) | ||
- [datacube](https://github.com/stac-extensions/datacube) (coming soon) | ||
- Extra fields: | ||
- `noaa-hrrr:forecast_cycle_type`: either standard (18-hour) or extended (48-hour) | ||
- `noaa-hrrr:region`: either `conus` or `alaska` | ||
- [Browse the example in human-readable form](https://radiantearth.github.io/stac-browser/#/external/raw.githubusercontent.com/stactools-packages/noaa-hrrr/main/examples/collection.json) | ||
- [Browse a notebook demonstrating the example item and collection](https://github.com/stactools-packages/noaa-hrrr/tree/main/docs/example.ipynb) | ||
|
||
A short description of the package and its usage. | ||
|
||
## STAC examples | ||
|
||
- [Collection](examples/collection.json) | ||
- [Item](examples/item/item.json) | ||
|
||
## Installation | ||
|
||
Install `stactools-noaa-hrrr` with pip: | ||
|
||
```shell | ||
pip install stactools-noaa-hrrr | ||
``` | ||
|
||
## Command-line usage | ||
|
||
To create a collection object: | ||
|
||
```shell | ||
stac noaahrrr create-collection {region} {product} {cloud_provider} {destination_file} | ||
``` | ||
|
||
e.g. | ||
|
||
```shell | ||
stac noaahrrr create-collection conus sfc azure example-collection.json | ||
``` | ||
|
||
To create an item: | ||
|
||
```shell | ||
stac noaahrrr create-item \ | ||
{region} \ | ||
{product} \ | ||
{cloud_provider} \ | ||
{reference_datetime} \ | ||
{forecast_hour} \ | ||
{destination_file} | ||
``` | ||
|
||
e.g. | ||
|
||
```shell | ||
stac noaahrrr create-item conus sfc azure 2024-05-01T12 10 example-item.json | ||
``` | ||
|
||
To create all items for a date range: | ||
|
||
```shell | ||
stac noaahrrr create-item-collection \ | ||
{region} \ | ||
{product} \ | ||
{cloud_provider} \ | ||
{start_date} \ | ||
{end_date} \ | ||
{destination_folder} | ||
``` | ||
|
||
e.g. | ||
|
||
```shell | ||
stac noaahrrr create-item-collection conus sfc azure 2024-05-01 2024-05-31 /tmp/items | ||
``` | ||
|
||
### Docker | ||
|
||
You can launch a jupyterhub server in a docker container with all of the | ||
dependencies installed using these commands: | ||
|
||
```shell | ||
docker/build | ||
docker/jupyter | ||
``` | ||
|
||
Use `stac noaahrrr --help` to see all subcommands and options. | ||
|
||
## Contributing | ||
|
||
We use [pre-commit](https://pre-commit.com/) to check any changes. | ||
To set up your development environment: | ||
|
||
```shell | ||
pip install -e '.[dev]' | ||
pre-commit install | ||
``` | ||
|
||
To check all files: | ||
|
||
```shell | ||
pre-commit run --all-files | ||
``` | ||
|
||
To run the tests: | ||
|
||
```shell | ||
pytest -vv | ||
``` | ||
|
||
If you've updated the STAC metadata output, update the examples: | ||
|
||
```shell | ||
scripts/update-examples | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.