Pattern 2
Application Package Pattern 2¶
The CWL includes:
- two input parameters of type
Directory
- one output parameter of type
Directory
This scenario typically takes as input one pre-event acquisition, one post-even acquisition, applies an algorithm and produces a result
Implementation: delineate water bodies using NDWI and Otsu automatic threshold taking as input two Landsat-8/9 acquisitions
Inputs¶
Id | Type | Label | Doc |
---|---|---|---|
aoi |
string | area of interest | area of interest as a bounding box |
epsg |
string | EPSG code | EPSG code |
bands |
Array of string | bands used for the NDWI | bands used for the NDWI |
item_1 |
Directory | Landsat-8/9 acquisition reference | Landsat-8/9 acquisition reference |
item_2 |
Directory | Landsat-8/9 acquisition reference | Landsat-8/9 acquisition reference |
Steps¶
Id | Runs | Label | Doc |
---|---|---|---|
step |
file:///#clt | None | None |
Outputs¶
Id | Type | Label | Doc |
---|---|---|---|
water_bodies |
Directory | Water bodies detected | Water bodies detected based on the NDWI and otsu threshold |
Data flow management¶
Loading CWL document from ../cwl-workflow/pattern-2.cwl... Raw CWL document successfully loaded from ../cwl-workflow/pattern-2.cwl! Now updating the model to v1.2... Raw CWL document successfully updated! Now converting to the CWL model... Raw CWL document successfully updated! Now dereferencing the FQNs... Cleaning Workflow pattern-2... Cleaning CommandLineTool clt... CWL document successfully dereferenced! Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-in.cwl... Raw CWL document successfully loaded from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-in.cwl! Now updating the model to v1.2... Raw CWL document successfully updated! Now converting to the CWL model...
Raw CWL document successfully updated! Now dereferencing the FQNs... Cleaning CommandLineTool my-asthonishing-stage-in-directory... CWL document successfully dereferenced! Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-in-file.cwl... Raw CWL document successfully loaded from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-in-file.cwl! Now updating the model to v1.2... Raw CWL document successfully updated! Now converting to the CWL model...
Raw CWL document successfully updated! Now dereferencing the FQNs... Cleaning CommandLineTool my-asthonishing-stage-in-file... CWL document successfully dereferenced! Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/cwl-workflow/pattern-2.cwl... Raw CWL document successfully loaded from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/cwl-workflow/pattern-2.cwl! Now updating the model to v1.2... Raw CWL document successfully updated! Now converting to the CWL model... Raw CWL document successfully updated! Now dereferencing the FQNs... Cleaning Workflow pattern-2... Cleaning CommandLineTool clt... CWL document successfully dereferenced! Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-out.cwl... Raw CWL document successfully loaded from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/main/templates/stage-out.cwl! Now updating the model to v1.2... Raw CWL document successfully updated! Now converting to the CWL model...
Raw CWL document successfully updated! Now dereferencing the FQNs... Cleaning CommandLineTool my-super-stage-out... CWL document successfully dereferenced! Validating stage-in 'my-asthonishing-stage-in-directory'... stage-in 'my-asthonishing-stage-in-directory' is valid Validating stage-in 'my-asthonishing-stage-in-file'... stage-in 'my-asthonishing-stage-in-file' is valid Validating stage-out 'my-super-stage-out'... stage-out 'my-super-stage-out' is valid Building the CWL Orchestrator Workflow... Analyzing pattern-2 inputs... * pattern-2/aoi: string * pattern-2/epsg: string * pattern-2/bands: string[] * pattern-2/item_1: Directory Directory type detected, creating a related 'directory_stage_in_0'... Converting Directory to URL-compatible type... Directory converted to https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI Connecting 'app/item_1' to 'directory_stage_in_0' output... * pattern-2/item_2: Directory Directory type detected, creating a related 'directory_stage_in_1'... Converting Directory to URL-compatible type... Directory converted to https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI Connecting 'app/item_2' to 'directory_stage_in_1' output... Analyzing pattern-2 outputs... * pattern-2/water_bodies: Directory Directory type detected, creating a related 'stage_out_0'... Converting Directory to URL-compatible type... Directory converted to https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI Connecting 'app/water_bodies' to 'stage_out_0' output... Orchestrator Workflow built in 0.0027 seconds
Inputs¶
Id | Type | Label | Doc |
---|---|---|---|
aoi |
string | area of interest - pattern-2/aoi | area of interest as a bounding box - This parameter is derived from pattern-2/aoi |
epsg |
string | EPSG code - pattern-2/epsg | EPSG code - This parameter is derived from pattern-2/epsg |
bands |
Array of string | bands used for the NDWI - pattern-2/bands | bands used for the NDWI - This parameter is derived from pattern-2/bands |
another_input |
string | Another Input - my-asthonishing-stage-in-directory/another_input | An additional input for demonstration purposes - This parameter is derived from my-asthonishing-stage-in-directory/another_input |
item_1 |
https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI | Landsat-8/9 acquisition reference - pattern-2/item_1 | Landsat-8/9 acquisition reference - This parameter is derived from pattern-2/item_1 |
item_2 |
https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI | Landsat-8/9 acquisition reference - pattern-2/item_2 | Landsat-8/9 acquisition reference - This parameter is derived from pattern-2/item_2 |
s3_bucket |
string | my-super-stage-out/s3_bucket | This parameter is derived from: my-super-stage-out/s3_bucket |
sub_path |
string | my-super-stage-out/sub_path | This parameter is derived from: my-super-stage-out/sub_path |
aws_access_key_id |
string | my-super-stage-out/aws_access_key_id | This parameter is derived from: my-super-stage-out/aws_access_key_id |
aws_secret_access_key |
string | my-super-stage-out/aws_secret_access_key | This parameter is derived from: my-super-stage-out/aws_secret_access_key |
region_name |
string | my-super-stage-out/region_name | This parameter is derived from: my-super-stage-out/region_name |
endpoint_url |
string | my-super-stage-out/endpoint_url | This parameter is derived from: my-super-stage-out/endpoint_url |
Steps¶
Id | Runs | Label | Doc |
---|---|---|---|
directory_stage_in_0 |
file:///#my-asthonishing-stage-in-directory | None | None |
directory_stage_in_1 |
file:///#my-asthonishing-stage-in-directory | None | None |
app |
file:///#pattern-2 | None | None |
stage_out_0 |
file:///#my-super-stage-out | None | None |
Outputs¶
Id | Type | Label | Doc |
---|---|---|---|
water_bodies |
https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI | Water bodies detected | Water bodies detected based on the NDWI and otsu threshold |