stac-extensions / timeseries

Time Series STAC Extension Specification
Apache License 2.0
1 stars 1 forks source link

Time Series Extension Specification

This document explains the Time Series Extension to the SpatioTemporal Asset Catalog (STAC) specification. STAC item representing a temporal series dataset should use this extension to provide additional information about the time series. Typical use cases include:

Item Properties and Collection Fields

Field Name Type Description
ts:period string string representing a recurring time interval with repeating rules
ts:dates [string] List of the dates represented in the time series datasets. It is formatted as date-time according to RFC 3339, section 5.6.
ts:parameters [string] List of parameters or variables in the time series

One of ts:period or ts:dates is REQUIRED.

Additional Field Information

There are 2 main date representations in the time series extension:

In both cases, it is also recommended that period covered by the time series is defined by the first and last date of the time series using the Date and Time Range fields

ts:period

This is the duration of the time series. It is formatted as repeating intervals. They are formed by adding R[n]/ to the beginning of an interval expression, where R is used as the letter itself and [n] is replaced by the number of repetitions. Leaving out the value for [n] or specifying a value of -1, means an unbounded number of repetitions.

Some examples:

Relation types

This extension extends the Link Object used in all STAC entities (Catalogs, Collections, Items). It requires specific relation types to be set for the rel field in the Link Object.

Coverage

Links to a Coverage JSON document.

Field Name Type Description
rel string REQUIRED. Must be set to coverage.
href string REQUIRED. Link to the Coverage JSON document.
type string REQUIRED. Type of the coverage (e.g application/prs.coverage+json).
ts:api string If applicable, the code of the API producing the document (See below for more details)

Coverage JSON APIs

API code Description
wcs WCS2.0 getCoverage request model
ogcapi-coverages OGC API Coverages
egms European Ground Motion Service API

Contributing

All contributions are subject to the STAC Specification Code of Conduct. For contributions, please follow the STAC specification contributing guide Instructions for running tests are copied here for convenience.

Running tests

The same checks that run as checks on PR's are part of the repository and can be run locally to verify that changes are valid. To run tests locally, you'll need npm, which is a standard part of any node.js installation.

First you'll need to install everything with npm once. Just navigate to the root of this repository and on your command line run:

npm install

Then to check markdown formatting and test the examples against the JSON schema, you can run:

npm test

This will spit out the same texts that you see online, and you can then go and fix your markdown or examples.

If the tests reveal formatting problems with the examples, you can fix them with:

npm run format-examples