How to capture JSON stdout and re-use it
INFO /opt/hostedtoolcache/Python/3.12.7/x64/bin/cwltool 3.1.20241112140730
INFO Resolved '../cwl/03-json-stdout/capture-json-stdout.cwl' to 'file:///home/runner/work/how-to/how-to/cwl/03-json-stdout/capture-json-stdout.cwl'
INFO [workflow ] start
INFO [workflow ] starting step step_stac
INFO [step step_stac] start
Error: No such object: docker.io/curlimages/curl:latest
INFO ['docker', 'pull', 'docker.io/curlimages/curl:latest']
latest: Pulling from curlimages/curl
43c4264eed91: Pulling fs layer
90d3ba855880: Pulling fs layer
4ca545ee6d5d: Pulling fs layer
90d3ba855880: Downloading 86.68kB/8.301MB
43c4264eed91: Downloading 36.88kB/3.624MB
4ca545ee6d5d: Downloading 42B/42B
4ca545ee6d5d: Verifying Checksum
4ca545ee6d5d: Download complete
43c4264eed91: Downloading 3.624MB/3.624MB
43c4264eed91: Verifying Checksum
43c4264eed91: Download complete
43c4264eed91: Extracting 65.54kB/3.624MB
90d3ba855880: Verifying Checksum
90d3ba855880: Download complete
43c4264eed91: Extracting 3.624MB/3.624MB
43c4264eed91: Pull complete
90d3ba855880: Extracting 98.3kB/8.301MB
90d3ba855880: Extracting 6.783MB/8.301MB
90d3ba855880: Extracting 8.301MB/8.301MB
90d3ba855880: Pull complete
4ca545ee6d5d: Extracting 42B/42B
4ca545ee6d5d: Extracting 42B/42B
4ca545ee6d5d: Pull complete
Digest: sha256:83a505ba2ba62f208ed6e410c268b7b9aa48f0f7b403c8108b9773b44199dbba
Status: Downloaded newer image for curlimages/curl:latest
docker.io/curlimages/curl:latest
INFO [job step_stac] /tmp/63e85v6t$ docker \
run \
-i \
--mount=type=bind,source=/tmp/63e85v6t,target=/hGDvQB \
--mount=type=bind,source=/tmp/61a5586_,target=/tmp \
--workdir=/hGDvQB \
--read-only=true \
--log-driver=none \
--user=1001:127 \
--rm \
--cidfile=/tmp/jcw0y_2a/20241211090520-189948.cid \
--env=TMPDIR=/tmp \
--env=HOME=/hGDvQB \
docker.io/curlimages/curl:latest \
curl \
https://earth-search.aws.element84.com/v0/collections/sentinel-s2-l2a-cogs/items/S2B_53HPA_20210723_0_L2A > /tmp/63e85v6t/message
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 10156 100 10156 0 0 32610 0 --:--:-- --:--:-- --:--:-- 32655
INFO [job step_stac] completed success
INFO [step step_stac] completed success
INFO [workflow ] starting step step_translate
INFO [step step_translate] start
INFO [job step_translate] /tmp/nkkes9f0$ docker \
run \
-i \
--mount=type=bind,source=/tmp/nkkes9f0,target=/hGDvQB \
--mount=type=bind,source=/tmp/vjrtgkaj,target=/tmp \
--workdir=/hGDvQB \
--read-only=true \
--user=1001:127 \
--rm \
--cidfile=/tmp/idzqmt68/20241211090521-224963.cid \
--env=TMPDIR=/tmp \
--env=HOME=/hGDvQB \
ghcr.io/eoap/how-to/how-to-container:1.1.0 \
rio \
convert \
--driver \
PNG \
--dtype \
uint8 \
https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B04.tif \
red.png
WARNING:rasterio._env:CPLE_NotSupported in driver PNG does not support creation option BLOCKXSIZE
WARNING:rasterio._env:CPLE_NotSupported in driver PNG does not support creation option BLOCKYSIZE
WARNING:rasterio._env:CPLE_NotSupported in driver PNG does not support creation option TILED
WARNING:rasterio._env:CPLE_NotSupported in driver PNG does not support creation option COMPRESS
WARNING:rasterio._env:CPLE_NotSupported in driver PNG does not support creation option INTERLEAVE
INFO [job step_translate] Max memory used: 781MiB
INFO [job step_translate] completed success
INFO [step step_translate] completed success
INFO [workflow ] completed success
INFO Final process status is success
{
"location": "file:///home/runner/work/how-to/how-to/docs/red.png",
"basename": "red.png",
"class": "File",
"checksum": "sha1$3b0ab5ca89bc640e276ac48c6d37a900a4493708",
"size": 103995863,
"path": "/home/runner/work/how-to/how-to/docs/red.png"
}
{
"thumbnail": {
"title": "Thumbnail",
"type": "image/png",
"roles": [
"thumbnail"
],
"href": "https://roda.sentinel-hub.com/sentinel-s2-l1c/tiles/53/H/PA/2021/7/23/0/preview.jpg"
},
"overview": {
"title": "True color image",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"overview"
],
"gsd": 10,
"eo:bands": [
{
"name": "B04",
"common_name": "red",
"center_wavelength": 0.6645,
"full_width_half_max": 0.038
},
{
"name": "B03",
"common_name": "green",
"center_wavelength": 0.56,
"full_width_half_max": 0.045
},
{
"name": "B02",
"common_name": "blue",
"center_wavelength": 0.4966,
"full_width_half_max": 0.098
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/L2A_PVI.tif",
"proj:shape": [
343,
343
],
"proj:transform": [
320,
0,
600000,
0,
-320,
6100000,
0,
0,
1
]
},
"info": {
"title": "Original JSON metadata",
"type": "application/json",
"roles": [
"metadata"
],
"href": "https://roda.sentinel-hub.com/sentinel-s2-l2a/tiles/53/H/PA/2021/7/23/0/tileInfo.json"
},
"metadata": {
"title": "Original XML metadata",
"type": "application/xml",
"roles": [
"metadata"
],
"href": "https://roda.sentinel-hub.com/sentinel-s2-l2a/tiles/53/H/PA/2021/7/23/0/metadata.xml"
},
"visual": {
"title": "True color image",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"overview"
],
"gsd": 10,
"eo:bands": [
{
"name": "B04",
"common_name": "red",
"center_wavelength": 0.6645,
"full_width_half_max": 0.038
},
{
"name": "B03",
"common_name": "green",
"center_wavelength": 0.56,
"full_width_half_max": 0.045
},
{
"name": "B02",
"common_name": "blue",
"center_wavelength": 0.4966,
"full_width_half_max": 0.098
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/TCI.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"B01": {
"title": "Band 1 (coastal)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 60,
"eo:bands": [
{
"name": "B01",
"common_name": "coastal",
"center_wavelength": 0.4439,
"full_width_half_max": 0.027
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B01.tif",
"proj:shape": [
1830,
1830
],
"proj:transform": [
60,
0,
600000,
0,
-60,
6100000,
0,
0,
1
]
},
"B02": {
"title": "Band 2 (blue)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 10,
"eo:bands": [
{
"name": "B02",
"common_name": "blue",
"center_wavelength": 0.4966,
"full_width_half_max": 0.098
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B02.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"B03": {
"title": "Band 3 (green)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 10,
"eo:bands": [
{
"name": "B03",
"common_name": "green",
"center_wavelength": 0.56,
"full_width_half_max": 0.045
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B03.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"B04": {
"title": "Band 4 (red)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 10,
"eo:bands": [
{
"name": "B04",
"common_name": "red",
"center_wavelength": 0.6645,
"full_width_half_max": 0.038
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B04.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"B05": {
"title": "Band 5",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B05",
"center_wavelength": 0.7039,
"full_width_half_max": 0.019
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B05.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"B06": {
"title": "Band 6",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B06",
"center_wavelength": 0.7402,
"full_width_half_max": 0.018
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B06.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"B07": {
"title": "Band 7",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B07",
"center_wavelength": 0.7825,
"full_width_half_max": 0.028
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B07.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"B08": {
"title": "Band 8 (nir)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 10,
"eo:bands": [
{
"name": "B08",
"common_name": "nir",
"center_wavelength": 0.8351,
"full_width_half_max": 0.145
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B08.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"B8A": {
"title": "Band 8A",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B8A",
"center_wavelength": 0.8648,
"full_width_half_max": 0.033
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B8A.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"B09": {
"title": "Band 9",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 60,
"eo:bands": [
{
"name": "B09",
"center_wavelength": 0.945,
"full_width_half_max": 0.026
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B09.tif",
"proj:shape": [
1830,
1830
],
"proj:transform": [
60,
0,
600000,
0,
-60,
6100000,
0,
0,
1
]
},
"B11": {
"title": "Band 11 (swir16)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B11",
"common_name": "swir16",
"center_wavelength": 1.6137,
"full_width_half_max": 0.143
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B11.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"B12": {
"title": "Band 12 (swir22)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"gsd": 20,
"eo:bands": [
{
"name": "B12",
"common_name": "swir22",
"center_wavelength": 2.22024,
"full_width_half_max": 0.242
}
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/B12.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
},
"AOT": {
"title": "Aerosol Optical Thickness (AOT)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/AOT.tif",
"proj:shape": [
1830,
1830
],
"proj:transform": [
60,
0,
600000,
0,
-60,
6100000,
0,
0,
1
]
},
"WVP": {
"title": "Water Vapour (WVP)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/WVP.tif",
"proj:shape": [
10980,
10980
],
"proj:transform": [
10,
0,
600000,
0,
-10,
6100000,
0,
0,
1
]
},
"SCL": {
"title": "Scene Classification Map (SCL)",
"type": "image/tiff; application=geotiff; profile=cloud-optimized",
"roles": [
"data"
],
"href": "https://sentinel-cogs.s3.us-west-2.amazonaws.com/sentinel-s2-l2a-cogs/53/H/PA/2021/7/S2B_53HPA_20210723_0_L2A/SCL.tif",
"proj:shape": [
5490,
5490
],
"proj:transform": [
20,
0,
600000,
0,
-20,
6100000,
0,
0,
1
]
}
}