CARIS Batch Utility : BASE Editor Processes : Extract Coverage
 

Extract Coverage

Description

The ExtractCoverage process extracts a portion of a coverage.

Inputs

A point cloud or raster dataset.

Outputs

A coverage in CSAR format.

Command Line Syntax

carisbatch --run ExtractCoverage --geometry <value> --include-band <value> [options] <input> <output>

Options

The following table describes the parameters available for this process.

Parameter

 

Long

Short

Description

Can Repeat

Notes

 

--include-band

b

A string specifying the name of a band to include in the output.

The ALL keyword is used to include all bands in the output.

TRUE

At least one value must be specified explicitly.

--extract-type

g

A string specifying the type of extraction to be performed. One of:

INCLUSIVE: Inclusive - Copy all data inside the geometry.

EXCLUSIVE: Exclusive - Copy all data outside the geometry.

The default value is INCLUSIVE.

FALSE

--band-filter

f

A string specifying a filter to apply to input band values.

Supported operators: >, <, =, !=. For example, "Depth > 1".

FALSE

Values for elevation bands are assumed to be using the positive UP convention.

--geometry

G

The geometry with its coordinate reference system.

<WKT> - A string specifying the shape of the geometry.

<CRS> - A string specifying the horizontal coordinate reference system key of the geometry.

The geometry can be composed of one or more polygons that contain one or more holes. The geometry must be specified as a WKT string.

FALSE

--polygon-type

Y

A string specifying the type of bounding polygon to generate. One of:

CONVEX: Convex - The convex hull of the data is used for the polygon.

BUFFERED: Buffered - A simplified buffered boundary is used for the polygon.

The default value is BUFFERED.

FALSE

--comments

General comments to be added to the coverage metadata.

The default value is an empty string.

FALSE

Example

To use this command refer to the following example.

Example

Objective

You want to extract a portion of a raster coverage.

Description

Command Line Syntax

The depth band will be included in the extracted raster surface.

--include-band Depth

A filter will be applied to the output so that only points with a depth of greater than 10 metres will be included.

--band-filter "Depth>10"

The geometry of the extracted polygon is defined by the WKT string: POLYGON ((417005.5403481841800000 5579144.0498767812000000, 416942.8549106763700000 5579003.2347864071000000, 416908.2885466055600000 5579112.7677087365000000, 417005.5403481841800000 5579144.0498767812000000)).

The coordinate reference system is UTM-30N.

--geometry POLYGON ((417005.5403481841800000 5579144.0498767812000000, 416942.8549106763700000 5579003.2347864071000000, 416908.2885466055600000 5579112.7677087365000000, 417005.5403481841800000 5579144.0498767812000000))" UTM-30N

The source surface, Surface1.csar is located at D:\BatchSample.

D:\BatchSample\Surface1.csar

The output surface will be named ExtractSurface.csar and will be saved to the same location as the source file.

D:\BatchSample\ExtractSurface.csar

Command Line

carisbatch --run ExtractCoverage --include-band Depth --band-filter "Depth>10" --geometry "POLYGON ((417005.5403481841800000 5579144.0498767812000000, 416942.8549106763700000 5579003.2347864071000000, 416908.2885466055600000 5579112.7677087365000000, 417005.5403481841800000 5579144.0498767812000000))" UTM-30N D:\BatchSample\Surface1.csar D:\BatchSample\ExtractSurface.csar

Outcome

A new raster surface is created from the data extracted from the original raster surface.

Extra Notes

To generate a string for the geometry, you can select a polygon in the application and export it to ASCII through File > Export > Selection > CARIS Well Known Text