Skip to contents

Construct the base VRT object for composing VRT pipelines.

Usage

vrt_collect(x, band_descriptions, datetimes)

# S3 method for class 'character'
vrt_collect(x, band_descriptions = NULL, datetimes = rep("", length(x)))

# S3 method for class 'doc_items'
vrt_collect(x, ...)

# S3 method for class 'vrt_collection'
print(x, xml = FALSE, pixfun = FALSE, maskfun = FALSE, blocks = FALSE, ...)

Arguments

x

An object to be used to create a vrt_x object see details.

band_descriptions

A character vector of band descriptions.

datetimes

A character vector of datetimes.

...

Additional arguments not used

xml

logical indicating whether to print the XML of the VRT collection.

pixfun

logical indicating whether to print the pixel function.

maskfun

logical indicating whether to print the mask function.

blocks

A logical indicating whether to print the blocks instead of the collection summary.

Value

A vrt_collection object.

Details

For now the main way to create a vrt_collection object, which forms the basis of the vrrt-based pipelines in vrtility is using a doc_items object from the rstac package. For more info on how to create a doc_items object see sentinel2_stac_query(). To build a vrt_stack object a vrt_collection is required first. The vrt_collection object is essentially a list of VRT files. At this stage no alignment is carried out - and the rasters are virtualised as-is. In this state, we can apply masks fro example and when summarisation is required we can use vrt_stack - however, in order to create a stack the collection must xontain images from a single spatial reference system (SRS). If there are mutliple SRS values, use vrt_warp() to unify the projection of the collection.