Pattern 7
2025-09-08 11:01:04.043 | DEBUG | cwl_loader:load_cwl_from_location:196 - Loading CWL document from ../cwl-workflow/pattern-7.cwl...
2025-09-08 11:01:04.044 | DEBUG | cwl_loader:_load_cwl_from_stream:199 - Reading stream from ../cwl-workflow/pattern-7.cwl...
2025-09-08 11:01:04.060 | DEBUG | cwl_loader:load_cwl_from_stream:173 - CWL data of type <class 'ruamel.yaml.comments.CommentedMap'> successfully loaded from stream
2025-09-08 11:01:04.061 | DEBUG | cwl_loader:load_cwl_from_yaml:124 - Updating the model of type 'CommentedMap' to version 'v1.2'...
2025-09-08 11:01:04.066 | DEBUG | cwl_loader:load_cwl_from_yaml:135 - Raw CWL document successfully updated to v1.2! Now converting to the CWL model...
2025-09-08 11:01:04.075 | DEBUG | cwl_loader:load_cwl_from_yaml:143 - Raw CWL document successfully updated to v1.2! Now dereferencing the FQNs...
2025-09-08 11:01:04.075 | DEBUG | cwl_loader:_clean_process:66 - Cleaning Workflow pattern-7...
2025-09-08 11:01:04.076 | DEBUG | cwl_loader:_clean_process:66 - Cleaning CommandLineTool clt...
2025-09-08 11:01:04.076 | DEBUG | cwl_loader:load_cwl_from_yaml:151 - CWL document successfully dereferenced!
2025-09-08 11:01:04.077 | DEBUG | cwl_loader:_load_cwl_from_stream:207 - Stream from ../cwl-workflow/pattern-7.cwl successfully load!
Application Package Pattern 7¶
The CWL includes:
- one optional input parameter of type
Directory?
- one output parameter of type
Directory
This scenario may take as input an acquisition, an optional input, applies an algorithm and generates an output
Implementation: detects water bodies using the Normalized Difference Water Index (NDWI) and Otsu thresholding.
Inputs¶
Id | Type | Label | Doc |
---|---|---|---|
aoi |
string |
area of interest | area of interest as a bounding box |
epsg |
string |
EPSG code | EPSG code |
bands |
string[] |
bands used for the NDWI | bands used for the NDWI |
item_1 |
Directory |
Mandatory Landsat-8/9 acquisition reference | Landsat-8/9 acquisition reference |
item_2 |
[ null, Directory ] |
Optional Landsat-8/9 acquisition reference | Optional Landsat-8/9 acquisition reference |
Steps¶
Id | Runs | Label | Doc |
---|---|---|---|
step |
#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¶
2025-09-08 11:01:04.797 | DEBUG | cwl_loader:load_cwl_from_location:196 - Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in.cwl...
2025-09-08 11:01:04.836 | DEBUG | cwl_loader:_load_cwl_from_stream:199 - Reading stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in.cwl...
2025-09-08 11:01:04.843 | DEBUG | cwl_loader:load_cwl_from_stream:173 - CWL data of type <class 'ruamel.yaml.comments.CommentedMap'> successfully loaded from stream
2025-09-08 11:01:04.844 | DEBUG | cwl_loader:load_cwl_from_yaml:124 - Updating the model of type 'CommentedMap' to version 'v1.2'...
2025-09-08 11:01:04.845 | DEBUG | cwl_loader:load_cwl_from_yaml:135 - Raw CWL document successfully updated to v1.2! Now converting to the CWL model...
2025-09-08 11:01:04.999 | DEBUG | cwl_loader:load_cwl_from_yaml:143 - Raw CWL document successfully updated to v1.2! Now dereferencing the FQNs...
2025-09-08 11:01:05.000 | DEBUG | cwl_loader:_clean_process:66 - Cleaning CommandLineTool my-asthonishing-stage-in-directory...
2025-09-08 11:01:05.000 | DEBUG | cwl_loader:load_cwl_from_yaml:151 - CWL document successfully dereferenced!
2025-09-08 11:01:05.001 | DEBUG | cwl_loader:_load_cwl_from_stream:207 - Stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in.cwl successfully load!
2025-09-08 11:01:05.001 | DEBUG | cwl_loader:load_cwl_from_location:196 - Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in-file.cwl...
2025-09-08 11:01:05.034 | DEBUG | cwl_loader:_load_cwl_from_stream:199 - Reading stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in-file.cwl...
2025-09-08 11:01:05.040 | DEBUG | cwl_loader:load_cwl_from_stream:173 - CWL data of type <class 'ruamel.yaml.comments.CommentedMap'> successfully loaded from stream
2025-09-08 11:01:05.041 | DEBUG | cwl_loader:load_cwl_from_yaml:124 - Updating the model of type 'CommentedMap' to version 'v1.2'...
2025-09-08 11:01:05.041 | DEBUG | cwl_loader:load_cwl_from_yaml:135 - Raw CWL document successfully updated to v1.2! Now converting to the CWL model...
2025-09-08 11:01:05.186 | DEBUG | cwl_loader:load_cwl_from_yaml:143 - Raw CWL document successfully updated to v1.2! Now dereferencing the FQNs...
2025-09-08 11:01:05.186 | DEBUG | cwl_loader:_clean_process:66 - Cleaning CommandLineTool my-asthonishing-stage-in-file...
2025-09-08 11:01:05.188 | DEBUG | cwl_loader:load_cwl_from_yaml:151 - CWL document successfully dereferenced!
2025-09-08 11:01:05.188 | DEBUG | cwl_loader:_load_cwl_from_stream:207 - Stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-in-file.cwl successfully load!
2025-09-08 11:01:05.189 | DEBUG | cwl_loader:load_cwl_from_location:196 - Loading CWL document from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-out.cwl...
2025-09-08 11:01:05.332 | DEBUG | cwl_loader:_load_cwl_from_stream:199 - Reading stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-out.cwl...
2025-09-08 11:01:05.341 | DEBUG | cwl_loader:load_cwl_from_stream:173 - CWL data of type <class 'ruamel.yaml.comments.CommentedMap'> successfully loaded from stream
2025-09-08 11:01:05.342 | DEBUG | cwl_loader:load_cwl_from_yaml:124 - Updating the model of type 'CommentedMap' to version 'v1.2'...
2025-09-08 11:01:05.343 | DEBUG | cwl_loader:load_cwl_from_yaml:135 - Raw CWL document successfully updated to v1.2! Now converting to the CWL model...
2025-09-08 11:01:05.517 | DEBUG | cwl_loader:load_cwl_from_yaml:143 - Raw CWL document successfully updated to v1.2! Now dereferencing the FQNs...
2025-09-08 11:01:05.518 | DEBUG | cwl_loader:_clean_process:66 - Cleaning CommandLineTool my-super-stage-out...
2025-09-08 11:01:05.518 | DEBUG | cwl_loader:load_cwl_from_yaml:151 - CWL document successfully dereferenced!
2025-09-08 11:01:05.519 | DEBUG | cwl_loader:_load_cwl_from_stream:207 - Stream from https://raw.githubusercontent.com/eoap/application-package-patterns/refs/heads/develop/templates/stage-out.cwl successfully load!
2025-09-08 11:01:05.519 | INFO | eoap_cwlwrap.types:_validate_stage_in:273 - Validating stage-in 'my-asthonishing-stage-in-directory'...
2025-09-08 11:01:05.520 | INFO | eoap_cwlwrap.types:_validate_stage_in:295 - stage-in 'my-asthonishing-stage-in-directory' is valid
2025-09-08 11:01:05.520 | INFO | eoap_cwlwrap.types:_validate_stage_in:273 - Validating stage-in 'my-asthonishing-stage-in-file'...
2025-09-08 11:01:05.521 | INFO | eoap_cwlwrap.types:_validate_stage_in:295 - stage-in 'my-asthonishing-stage-in-file' is valid
2025-09-08 11:01:05.521 | INFO | eoap_cwlwrap.types:validate_stage_out:331 - Validating stage-out 'my-super-stage-out'...
2025-09-08 11:01:05.521 | INFO | eoap_cwlwrap.types:validate_stage_out:353 - stage-out 'my-super-stage-out' is valid
2025-09-08 11:01:05.522 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:90 - Building the CWL Orchestrator Workflow...
2025-09-08 11:01:05.523 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:119 - Analyzing pattern-7 inputs...
2025-09-08 11:01:05.525 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:135 - * pattern-7/aoi: string
2025-09-08 11:01:05.525 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:135 - * pattern-7/epsg: string
2025-09-08 11:01:05.526 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:135 - * pattern-7/bands: string[]
2025-09-08 11:01:05.527 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:135 - * pattern-7/item_1: Directory
2025-09-08 11:01:05.527 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:148 - Directory type detected, creating a related 'directory_stage_in_0'...
2025-09-08 11:01:05.527 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:150 - Converting Directory to URL-compatible type...
2025-09-08 11:01:05.528 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:154 - Directory converted to https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI
2025-09-08 11:01:05.529 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:195 - Connecting 'app/item_1' to 'directory_stage_in_0' output...
2025-09-08 11:01:05.529 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:135 - * pattern-7/item_2: [ null, Directory ]
2025-09-08 11:01:05.530 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:148 - Directory type detected, creating a related 'directory_stage_in_1'...
2025-09-08 11:01:05.530 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:150 - Converting [ null, Directory ] to URL-compatible type...
2025-09-08 11:01:05.531 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:154 - [ null, Directory ] converted to [ null, https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI ]
2025-09-08 11:01:05.532 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:186 - Nullable detected, 'when' required for reference:item_2
2025-09-08 11:01:05.532 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:195 - Connecting 'app/item_2' to 'directory_stage_in_1' output...
2025-09-08 11:01:05.533 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:246 - Analyzing pattern-7 outputs...
2025-09-08 11:01:05.533 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:252 - * pattern-7/water_bodies: Directory
2025-09-08 11:01:05.534 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:257 - Directory type detected, creating a related 'stage_out_0'...
2025-09-08 11:01:05.534 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:259 - Converting Directory to URL-compatible type...
2025-09-08 11:01:05.535 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:263 - Directory converted to https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI
2025-09-08 11:01:05.536 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:304 - Connecting 'app/water_bodies' to 'stage_out_0' output...
2025-09-08 11:01:05.537 | INFO | eoap_cwlwrap:_build_orchestrator_workflow:379 - Orchestrator Workflow built in 0.0146 seconds
Workflow components diagram¶
Inputs¶
Id | Type | Label | Doc |
---|---|---|---|
aoi |
string |
area of interest - pattern-7/aoi | area of interest as a bounding box - This parameter is derived from pattern-7/aoi |
epsg |
string |
EPSG code - pattern-7/epsg | EPSG code - This parameter is derived from pattern-7/epsg |
bands |
string[] |
bands used for the NDWI - pattern-7/bands | bands used for the NDWI - This parameter is derived from pattern-7/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 |
Mandatory Landsat-8/9 acquisition reference - pattern-7/item_1 | Landsat-8/9 acquisition reference - This parameter is derived from pattern-7/item_1 |
item_2 |
[ null, https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI ] |
Optional Landsat-8/9 acquisition reference - pattern-7/item_2 | Optional Landsat-8/9 acquisition reference - This parameter is derived from pattern-7/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 |
#my-asthonishing-stage-in-directory |
None | None |
directory_stage_in_1 |
#my-asthonishing-stage-in-directory |
None | None |
app |
#pattern-7 |
None | None |
stage_out_0 |
#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 |
Execution¶
Inputs¶
{
"aoi": "-118.985,38.432,-118.183,38.938",
"epsg": "EPSG:4326",
"bands": [
"green",
"nir08"
],
"item_1": {
"class": "https://raw.githubusercontent.com/eoap/schemas/main/url.yaml#URL",
"value": "https://planetarycomputer.microsoft.com/api/stac/v1/collections/landsat-c2-l2/items/LC08_L2SP_042033_20231007_02_T1"
},
"item_2": {
"class": "https://raw.githubusercontent.com/eoap/schemas/main/url.yaml#URL",
"value": "https://planetarycomputer.microsoft.com/api/stac/v1/collections/landsat-c2-l2/items/LC09_L2SP_042033_20231015_02_T1"
}
}
Outputs¶
{
"water_bodies": {
"value": "s3://my-bucket/my/sub/path-s0xh67/catalog.json",
"type": "https://raw.githubusercontent.com/eoap/schemas/main/string_format.yaml#URI"
}
}