diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PERUSAT/ORT/MetadataExtractorsTests_ORT_PER1_20170307150657_000.json b/src/Stars.Data.Tests/Resources/AIRBUS/PERUSAT/ORT/MetadataExtractorsTests_ORT_PER1_20170307150657_000.json index 25bf112b..041791a4 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PERUSAT/ORT/MetadataExtractorsTests_ORT_PER1_20170307150657_000.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PERUSAT/ORT/MetadataExtractorsTests_ORT_PER1_20170307150657_000.json @@ -5,6 +5,7 @@ "https://stac-extensions.github.io/processing/v1.0.0/schema.json", "https://stac-extensions.github.io/projection/v1.0.0/schema.json", "https://stac-extensions.github.io/raster/v1.0.0/schema.json", + "https://stac-extensions.github.io/sat/v1.0.0/schema.json", "https://stac-extensions.github.io/view/v1.0.0/schema.json" ], "type": "Feature", @@ -39,38 +40,43 @@ "properties": { "datetime": "2017-03-07T15:06:57Z", "created": "2017-03-07T15:36:03.54075Z", - "platform": "per-1", - "constellation": "pleiades", - "mission": "per-1", + "platform": "perusat-1", + "constellation": "perusat", + "mission": "perusat-1", "instruments": [ "naomi-1" ], "sensor_type": "optical", - "gsd": 4.5, - "title": "PER-1 NAOMI-1 RASTER_ORTHO 2017-03-07 15:06:57", + "spectral_mode": [ + "P", + "MS" + ], + "gsd": 1.0, + "title": "PERUSAT-1 ORTHO P MS 2017-03-07 15:06:57", + "sat:platform_international_designator": "2016-058A", "proj:epsg": 32718, "proj:shape": [ - 10498, - 11192 + 41992, + 44768 ], "view:azimuth": 105.5, "view:sun_azimuth": 81.0, "view:sun_elevation": 56.9, "view:incidence_angle": 38.7, - "processing:level": "ORTHO/BASIC", + "processing:level": "ORTHO", "processing:software": { "M12Processor": "1.2.2" }, "providers": [ { - "name": "Airbus", - "description": "The identical Pléiades 1A and Pléiades 1B satellites deliver 50cm imagery products with a 20km swath. The product's location accuracy and excellent image quality make it an ideal source for data for any civil or military project.", + "name": "CONIDA, CNOIS, Airbus", + "description": "PerúSAT-1 is a very-high-resolution Earth observation satellite system built for the government and Space Agency of Peru. Launched in 2016, this satellite is the first of its kind operated by Peru.", "roles": [ "producer", "processor", "licensor" ], - "url": "https://www.intelligence-airbusds.com/imagery/constellation/pleiades/" + "url": "https://www.airbus.com/en/space/earth-observation/earth-observation-portfolio/perusat" } ] }, @@ -81,13 +87,89 @@ -12.34188494 ], "assets": { - "MS-RC": { + "PAN": { + "type": "image/tiff", + "roles": [ + "data", + "dn" + ], + "title": "ORTHO P", + "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", + "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", + "file:size": 0, + "eo:bands": [ + { + "name": "PAN", + "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", + "common_name": "pan", + "center_wavelength": 0.6, + "full_width_half_max": 0.15, + "solar_illumination": 1706.514896 + } + ], + "raster:bands": [ + { + "data_type": "uint16", + "bits_per_sample": 12, + "statistics": { + "minimum": 0.0, + "maximum": 4096.0 + }, + "scale": 0.09607363399968433, + "offset": 0.0 + } + ], + "product_type": "P", + "proj:shape": [ + 41992, + 44768 + ] + }, + "PAN-wf": { + "type": "image/tiff", + "roles": [ + "data", + "world-file" + ], + "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", + "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", + "file:size": 0 + }, + "metadata-P": { + "type": "application/xml", + "roles": [ + "metadata" + ], + "title": "Metadata file", + "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/DIM_PER1_20170307150657_ORT_P_000041.XML", + "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/DIM_PER1_20170307150657_ORT_P_000041.XML", + "file:size": 147381 + }, + "overview-P": { + "type": "image/jpeg", + "roles": [ + "overview" + ], + "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/PREVIEW_PER1_20170307150657_ORT_P_000041.JPG", + "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/PREVIEW_PER1_20170307150657_ORT_P_000041.JPG", + "file:size": 25698 + }, + "thumbnail-P": { + "type": "image/jpeg", + "roles": [ + "thumbnail" + ], + "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/ICON_PER1_20170307150657_ORT_P_000041.JPG", + "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/ICON_PER1_20170307150657_ORT_P_000041.JPG", + "file:size": 1321 + }, + "MS": { "type": "image/tiff", "roles": [ "data", "dn" ], - "title": "Band Composite Basic MS Ortho R C", + "title": "ORTHO MS", "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_MS_000041/IMG_PER1_20170307150657_ORT_MS_000041.TIF", "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_MS_000041/IMG_PER1_20170307150657_ORT_MS_000041.TIF", "file:size": 0, @@ -96,24 +178,32 @@ "name": "B2", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.665, + "full_width_half_max": 0.035, "solar_illumination": 1540.494123 }, { "name": "B1", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.56, + "full_width_half_max": 0.03, "solar_illumination": 1826.087443 }, { "name": "B0", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.485, + "full_width_half_max": 0.035, "solar_illumination": 1982.671954 }, { "name": "B3", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8185, + "full_width_half_max": 0.066, "solar_illumination": 1094.747446 } ], @@ -165,7 +255,7 @@ 11192 ] }, - "MS-RC-wf": { + "MS-wf": { "type": "image/tiff", "roles": [ "data", @@ -202,80 +292,6 @@ "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_MS_000041/ICON_PER1_20170307150657_ORT_MS_000041.JPG", "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_MS_000041/ICON_PER1_20170307150657_ORT_MS_000041.JPG", "file:size": 1781 - }, - "P-RC": { - "type": "image/tiff", - "roles": [ - "data", - "dn" - ], - "title": "Band Composite Basic P Ortho R C", - "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", - "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", - "file:size": 0, - "eo:bands": [ - { - "name": "PAN", - "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", - "common_name": "pan", - "solar_illumination": 1706.514896 - } - ], - "raster:bands": [ - { - "data_type": "uint16", - "bits_per_sample": 12, - "statistics": { - "minimum": 0.0, - "maximum": 4096.0 - }, - "scale": 0.09607363399968433, - "offset": 0.0 - } - ], - "product_type": "P", - "proj:shape": [ - 41992, - 44768 - ] - }, - "P-RC-wf": { - "type": "image/tiff", - "roles": [ - "data", - "world-file" - ], - "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", - "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/IMG_PER1_20170307150657_ORT_P_000041.TIF", - "file:size": 0 - }, - "metadata-P": { - "type": "application/xml", - "roles": [ - "metadata" - ], - "title": "Metadata file", - "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/DIM_PER1_20170307150657_ORT_P_000041.XML", - "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/DIM_PER1_20170307150657_ORT_P_000041.XML", - "file:size": 147381 - }, - "overview-P": { - "type": "image/jpeg", - "roles": [ - "overview" - ], - "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/PREVIEW_PER1_20170307150657_ORT_P_000041.JPG", - "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/PREVIEW_PER1_20170307150657_ORT_P_000041.JPG", - "file:size": 25698 - }, - "thumbnail-P": { - "type": "image/jpeg", - "roles": [ - "thumbnail" - ], - "href": "data/DS_PER1_201703071506576_PS1_W077S12_002239/VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/ICON_PER1_20170307150657_ORT_P_000041.JPG", - "filename": "VOL_PER1_ORT_001_000041/IMG_PER1_ORT_P_000041/ICON_PER1_20170307150657_ORT_P_000041.JPG", - "file:size": 1321 } }, "links": [] diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202007200503501_FR1_PX_E089N26_0903_00772.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202007200503501_FR1_PX_E089N26_0903_00772.json index 1b21c62f..f4379b61 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202007200503501_FR1_PX_E089N26_0903_00772.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202007200503501_FR1_PX_E089N26_0903_00772.json @@ -98,24 +98,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6559999999999999, + "full_width_half_max": 0.066, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5585, + "full_width_half_max": 0.058, "solar_illumination": 1830.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.495, + "full_width_half_max": 0.065, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8425, + "full_width_half_max": 0.102, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108151540532_FR1_PX_W074N18_1111_00749.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108151540532_FR1_PX_W074N18_1111_00749.json index 6db64367..42df35d9 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108151540532_FR1_PX_W074N18_1111_00749.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108151540532_FR1_PX_W074N18_1111_00749.json @@ -98,24 +98,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6499999999999999, + "full_width_half_max": 0.06, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.56, + "full_width_half_max": 0.06, "solar_illumination": 1831.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.49, + "full_width_half_max": 0.06, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.84, + "full_width_half_max": 0.1, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108201552560_FR1_PX_W075N18_1209_01230.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108201552560_FR1_PX_W075N18_1209_01230.json index 4977b88a..1065572c 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108201552560_FR1_PX_W075N18_1209_01230.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108201552560_FR1_PX_W075N18_1209_01230.json @@ -98,6 +98,8 @@ "name": "P", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "pan", + "center_wavelength": 0.6499999999999999, + "full_width_half_max": 0.18, "solar_illumination": 1549.0 } ], @@ -172,24 +174,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6499999999999999, + "full_width_half_max": 0.06, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.56, + "full_width_half_max": 0.06, "solar_illumination": 1831.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.49, + "full_width_half_max": 0.06, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.84, + "full_width_half_max": 0.1, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108271548534_FR1_PX_W074N18_0509_00697.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108271548534_FR1_PX_W074N18_0509_00697.json index 1408960c..6f03b7a8 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108271548534_FR1_PX_W074N18_0509_00697.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1A_202108271548534_FR1_PX_W074N18_0509_00697.json @@ -98,6 +98,8 @@ "name": "P", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "pan", + "center_wavelength": 0.6499999999999999, + "full_width_half_max": 0.18, "solar_illumination": 1549.0 } ], @@ -172,24 +174,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6499999999999999, + "full_width_half_max": 0.06, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.56, + "full_width_half_max": 0.06, "solar_illumination": 1831.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.49, + "full_width_half_max": 0.06, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.84, + "full_width_half_max": 0.1, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201512251536493_FR1_PX_W074N18_0206_02942.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201512251536493_FR1_PX_W074N18_0206_02942.json index 7d9a0905..3d6e45ef 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201512251536493_FR1_PX_W074N18_0206_02942.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201512251536493_FR1_PX_W074N18_0206_02942.json @@ -98,24 +98,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6559999999999999, + "full_width_half_max": 0.066, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5585, + "full_width_half_max": 0.058, "solar_illumination": 1830.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.495, + "full_width_half_max": 0.065, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8425, + "full_width_half_max": 0.102, "solar_illumination": 1060.0 } ], @@ -192,24 +200,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6559999999999999, + "full_width_half_max": 0.066, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5585, + "full_width_half_max": 0.058, "solar_illumination": 1830.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.495, + "full_width_half_max": 0.065, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8425, + "full_width_half_max": 0.102, "solar_illumination": 1060.0 } ], @@ -286,24 +302,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6559999999999999, + "full_width_half_max": 0.066, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5585, + "full_width_half_max": 0.058, "solar_illumination": 1830.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.495, + "full_width_half_max": 0.065, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8425, + "full_width_half_max": 0.102, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201911060804562_FR1_PX_E041N03_0323_00808.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201911060804562_FR1_PX_E041N03_0323_00808.json index 1e5458c4..1ce80310 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201911060804562_FR1_PX_E041N03_0323_00808.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_201911060804562_FR1_PX_E041N03_0323_00808.json @@ -98,6 +98,8 @@ "name": "P", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "pan", + "center_wavelength": 0.6525, + "full_width_half_max": 0.192, "solar_illumination": 1548.0 } ], @@ -172,24 +174,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6559999999999999, + "full_width_half_max": 0.066, "solar_illumination": 1594.0 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5585, + "full_width_half_max": 0.058, "solar_illumination": 1830.0 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.495, + "full_width_half_max": 0.065, "solar_illumination": 1915.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.8425, + "full_width_half_max": 0.102, "solar_illumination": 1060.0 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_202201301007553_FR1_PX_E006N00_0710_00860.json b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_202201301007553_FR1_PX_E006N00_0710_00860.json index 07ed6af4..dbcdf566 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_202201301007553_FR1_PX_E006N00_0710_00860.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/PLEIADES/ORT/MetadataExtractorsTests_DS_PHR1B_202201301007553_FR1_PX_E006N00_0710_00860.json @@ -98,6 +98,8 @@ "name": "P", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "pan", + "center_wavelength": 0.65, + "full_width_half_max": 0.19, "solar_illumination": 1540.9 } ], @@ -172,24 +174,32 @@ "name": "B2", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 0.6599999999999999, + "full_width_half_max": 0.07, "solar_illumination": 1547.8 }, { "name": "B1", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 0.5549999999999999, + "full_width_half_max": 0.065, "solar_illumination": 1835.6 }, { "name": "B0", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 0.49, + "full_width_half_max": 0.06, "solar_illumination": 1912.0 }, { "name": "B3", "description": "Raw radiometric count (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 0.845, + "full_width_half_max": 0.105, "solar_illumination": 1041.4 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT6_20201214_141524100_000.json b/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT6_20201214_141524100_000.json index d712c27a..7e3a5d06 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT6_20201214_141524100_000.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT6_20201214_141524100_000.json @@ -98,24 +98,32 @@ "name": "B2", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 659.5, + "full_width_half_max": 38.5, "solar_illumination": 1540.494123 }, { "name": "B1", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 557.5, + "full_width_half_max": 33.5, "solar_illumination": 1826.087443 }, { "name": "B0", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 486.5, + "full_width_half_max": 35.5, "solar_illumination": 1982.671954 }, { "name": "B3", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 818.5, + "full_width_half_max": 66.5, "solar_illumination": 1094.747446 } ], diff --git a/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT7_20201117_024518700_000.json b/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT7_20201117_024518700_000.json index 2ee4a43d..fccb8449 100644 --- a/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT7_20201117_024518700_000.json +++ b/src/Stars.Data.Tests/Resources/AIRBUS/SPOT/MetadataExtractorsTests_ORT_SPOT7_20201117_024518700_000.json @@ -98,24 +98,32 @@ "name": "B2", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "red", + "center_wavelength": 665.0, + "full_width_half_max": 32.0, "solar_illumination": 1520.298133 }, { "name": "B1", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "green", + "center_wavelength": 565.0, + "full_width_half_max": 31.0, "solar_illumination": 1810.106202 }, { "name": "B0", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "blue", + "center_wavelength": 491.0, + "full_width_half_max": 34.0, "solar_illumination": 1964.630881 }, { "name": "B3", "description": "Raw radiometric counts (DN) to TOA Radiance (L). Formulae L=DN/GAIN+BIAS", "common_name": "nir", + "center_wavelength": 822.0, + "full_width_half_max": 52.0, "solar_illumination": 1084.46188 } ], diff --git a/src/Stars.Data/Model/Metadata/Airbus/AirbusMetadataExtractor.cs b/src/Stars.Data/Model/Metadata/Airbus/AirbusMetadataExtractor.cs index ce2e2451..21869a7c 100644 --- a/src/Stars.Data/Model/Metadata/Airbus/AirbusMetadataExtractor.cs +++ b/src/Stars.Data/Model/Metadata/Airbus/AirbusMetadataExtractor.cs @@ -60,8 +60,10 @@ internal AirbusProfiler GetProfiler(Dimap_Document dimap) return new VolumeDimapProfiler(dimap, this); case "PHR_ORTHO": case "PHR_SENSOR": - case "PER1_ORTHO": return new PleiadesDimapProfiler(dimap); + case "PER1_ORTHO": + case "PER1_SENSOR": + return new PerusatDimapProfiler(dimap); case "PNEO_ORTHO": return new PleiadesNEODimapProfiler(dimap); case "S6_ORTHO": @@ -76,7 +78,7 @@ protected override async Task ExtractMetadata(IItem item, string suffi var metadataAssets = GetMetadataAssets(item); List stacItemNodes = new List(); List dimapProfilers = new List(); - + foreach (var metadataAsset in metadataAssets) { Dimap_Document metadata = await ReadMetadata(metadataAsset.Value); @@ -99,21 +101,39 @@ protected override async Task ExtractMetadata(IItem item, string suffi } // Merge MS (multispectral) assets into P (pan-chromatic) STAC item - StacItemNode baseNode = stacItemNodes.FirstOrDefault(n => n.StacItem.Assets.ContainsKey("P-metadata")); + StacItemNode baseNode = stacItemNodes.FirstOrDefault(n => n.StacItem.Assets.ContainsKey("P-metadata") || n.StacItem.Assets.ContainsKey("metadata-P")); if (baseNode == null) baseNode = stacItemNodes[0]; //StacItem mergedStacItem = baseNode.StacItem; + List spectralMode = new List(); + if (baseNode.StacItem.Properties.ContainsKey("spectral_mode")) spectralMode.AddRange(baseNode.StacItem.Properties["spectral_mode"] as string[]); + foreach (StacItemNode n in stacItemNodes.FindAll(n => n != baseNode)) { baseNode.StacItem.Assets.AddRange(n.StacItem.Assets); + if (n.StacItem.Properties.ContainsKey("spectral_mode")) { + string[] itemSpectralMode = n.StacItem.GetProperty("spectral_mode"); + foreach (string sm in itemSpectralMode) + { + if (!spectralMode.Contains(sm)) spectralMode.Add(sm); + } + } } - + if (spectralMode.Count != 0) baseNode.StacItem.Properties["spectral_mode"] = spectralMode.ToArray(); + // Custom title for PNEO with multiple spectral processings // the second element of the title must contain all spectral processings // eg. PNEO4 MS-FS PAN ORTHO 2021-11-15 13:58:30 - if( dimapProfilers.Count > 1 && dimapProfilers[0].GetPlatform().Contains("PNEO")) { - string title = GetPNEOTitle(dimapProfilers, baseNode); - baseNode.StacItem.Title = title; + if (dimapProfilers.Count > 1) + { + if (dimapProfilers[0].GetPlatform().Contains("PNEO")) + { + baseNode.StacItem.Title = GetPNEOTitle(dimapProfilers, baseNode); + } + else if (dimapProfilers[0] is PerusatDimapProfiler) + { + baseNode.StacItem.Title = dimapProfilers[0].GetTitle(baseNode.StacItem.Properties); + } } return baseNode; @@ -152,14 +172,14 @@ private string GetPNEOTitle(List profilers, StacItemNode baseNod // from each item, get the spectral processing and put it in a list var spectralProcesses = profilers.Select(profiler => profiler.Dimap.Processing_Information.Product_Settings.SPECTRAL_PROCESSING.ToUpper()) .ToList(); - + // check if PAN is present and move it to the first position spectralProcesses.Remove("PAN"); spectralProcesses.Insert(0, "PAN"); // join the list into a string string spectralProcessesString = string.Join(" ", spectralProcesses); - + CultureInfo culture = new CultureInfo("fr-FR"); return string.Format("{0} {1} {2} {3}", profilers[0].GetPlatform().ToUpper(), @@ -167,11 +187,8 @@ private string GetPNEOTitle(List profilers, StacItemNode baseNod profilers[0].GetProcessingLevel(), baseNode.StacItem.Properties.GetProperty("datetime").ToUniversalTime().ToString("yyyy-MM-dd HH:mm:ss", culture)); } - - internal StacItemNode ExtractMetadata(IItem item, - AirbusProfiler dimapProfiler, - IAsset metadataAsset, - string suffix) + + internal StacItemNode ExtractMetadata(IItem item, AirbusProfiler dimapProfiler, IAsset metadataAsset, string suffix) { StacItem stacItem = CreateStacItem(dimapProfiler); @@ -189,7 +206,7 @@ private void AddEoBandPropertyInItem(StacItem stacItem) } internal virtual StacItem CreateStacItem(AirbusProfiler dimapProfiler) { - + StacItem stacItem = new StacItem(dimapProfiler.GetId(), GetGeometry(dimapProfiler), GetCommonMetadata(dimapProfiler)); @@ -277,6 +294,9 @@ private void FillInstrument(AirbusProfiler dimapProfiler, Dictionary GetEoBandObjects(StacAsset stacAsset, List eoBandObjects = new List(); for (int i = 0; i < spectralBandInfos.Band_Radiance.Count(); i++) { - var bandInfo = spectralBandInfos.Band_Radiance[i]; - var bandSolarIrradiance = spectralBandInfos.Band_Solar_Irradiance[i]; - eoBandObjects.Add(GetEoBandRadianceObject(bandInfo, bandSolarIrradiance)); + eoBandObjects.Add(GetEoBandRadianceObject(spectralBandInfos, i)); } return eoBandObjects.OrderBy(eob => BandOrders[eob.CommonName]).ToList(); } @@ -302,12 +305,21 @@ protected List GetRasterBandObjects(Schemas.Band_Measurement_List sp protected abstract IDictionary BandOrders { get; } - protected virtual EoBandObject GetEoBandRadianceObject(Schemas.Band_Radiance bandInfo, Schemas.Band_Solar_Irradiance bandSolarIrradiance) + protected virtual EoBandObject GetEoBandRadianceObject(Schemas.Band_Measurement_List spectralBandInfos, int index) { + var bandInfo = spectralBandInfos.Band_Radiance[index]; + var bandSolarIrradiance = spectralBandInfos.Band_Solar_Irradiance[index]; + var bandSpectralRange = spectralBandInfos.Band_Spectral_Range[index]; + EoBandObject eoBandObject = new EoBandObject(bandInfo.BAND_ID, GetEoCommonName(bandInfo)); eoBandObject.Description = bandInfo.MEASURE_DESC; eoBandObject.SolarIllumination = double.Parse(bandSolarIrradiance.VALUE); + if (Double.TryParse(bandSpectralRange.MIN, out double min) && Double.TryParse(bandSpectralRange.MAX, out double max)) + { + eoBandObject.CenterWavelength = (min + max) / 2; + eoBandObject.FullWidthHalfMax = Math.Round((max - min) / 2, 3); + } return eoBandObject; } @@ -402,7 +414,7 @@ internal virtual string GetAssetKey(IAsset bandAsset, Data_File dataFile) } } - key += type + "-R" + dataFile.Tile_R + "C" + dataFile.Tile_C; + if (!String.IsNullOrEmpty(dataFile.Tile_R) && !String.IsNullOrEmpty(dataFile.Tile_C)) key += type + "-R" + dataFile.Tile_R + "C" + dataFile.Tile_C; return key; } diff --git a/src/Stars.Data/Model/Metadata/Airbus/PleiadesNEODimapProfiler.cs b/src/Stars.Data/Model/Metadata/Airbus/PleiadesNEODimapProfiler.cs index b2a8c977..f5741ced 100644 --- a/src/Stars.Data/Model/Metadata/Airbus/PleiadesNEODimapProfiler.cs +++ b/src/Stars.Data/Model/Metadata/Airbus/PleiadesNEODimapProfiler.cs @@ -209,7 +209,7 @@ protected override List GetEoBandObjects(StacAsset stacAsset, // full_width_half_max double fullWidthHalfMax = (fwhm.FWHM_MAX - fwhm.FWHM_MIN)/1000; - EoBandObject eoBandObject = GetEoBandRadianceObject(bandInfo, bandSolarIrradiance); + EoBandObject eoBandObject = GetEoBandRadianceObject(spectralBandInfos, i); eoBandObject.Properties.Add("full_width_half_max", fullWidthHalfMax); eoBandObject.CenterWavelength = centerWavelength;