Explore collection metadata using earthdaily

Import librairies

from rich.table import Table
from rich.console import Console
from earthdaily import EarthDataStore

console = Console()

Init earthdatastore with environment variables or default credentials

eds = EarthDataStore()

Explore available collections

table = Table("Available collections")
for t in eds.explore():
    table.add_row(t)
console.print(table)
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Available collections                             ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ ai-ready-mosaics                                  │
│ ai-ready-mosaics-preview                          │
│ ai-ready-mosaics-sample                           │
│ alsat-1b-l2a-cog-edagro                           │
│ alsat-1b-l2a-cog-edagro-ag-cloud-mask             │
│ building-changes-map                              │
│ cbers-4-l2a-cog-edagro                            │
│ cbers-4-l2a-cog-edagro-ag-cloud-mask              │
│ cbers4-mux                                        │
│ cbers4-mux-clip                                   │
│ cbers4-mux-l1c                                    │
│ cropland-data-layer-us                            │
│ deimos-1-l2a-cog-edagro                           │
│ deimos-1-l2a-cog-edagro-ag-cloud-mask             │
│ deimos-l2a-cog-edagro                             │
│ deimos-l2a-cog-edagro-ag-cloud-mask               │
│ deimos1-catalog                                   │
│ deimos1-l1c                                       │
│ dmc-l2a-cog-edagro                                │
│ dmc-l2a-cog-edagro-ag-cloud-mask                  │
│ dove-psb-sd-boa                                   │
│ earthdaily-simulated-cloudless-l2a-cog-edagro     │
│ earthdaily-simulated-l2a-cog-edagro               │
│ earthdaily-simulated-l2a-cog-edagro-ag-cloud-mask │
│ ecmwf-mars                                        │
│ ecmwf-open-data                                   │
│ ecostress-eco-l2t-lste-002                        │
│ eda-albedo-map                                    │
│ eda-analysis-ready-mosaic                         │
│ eda-brightness-invariant                          │
│ eda-calibration-sites                             │
│ eda-cross-calibration                             │
│ eda-dem                                           │
│ eda-geoid                                         │
│ eda-landcover                                     │
│ eda-reference-image                               │
│ eda-water-mask                                    │
│ edagro-analytics-crop-mask-in-season              │
│ edagro-analytics-crops-layer                      │
│ edagro-analytics-field-borders-layer              │
│ edagro-analytics-field-boundaries                 │
│ edagro-landsat-cross-cal-coefficient              │
│ edc-daily-acquisition-requests                    │
│ edc-data-acquisition-plan                         │
│ esa-worldcover-landcover-2020-v100                │
│ esa-worldcover-landcover-2021-v200                │
│ esa-worldcover-s1-vvvhratio-2020-v100             │
│ esa-worldcover-s1-vvvhratio-2021-v200             │
│ esa-worldcover-s2-nvdi-2020-v100                  │
│ esa-worldcover-s2-nvdi-2021-v200                  │
│ esa-worldcover-s2-rgbnir-2020-v100                │
│ esa-worldcover-s2-rgbnir-2021-v200                │
│ esa-worldcover-s2-swir-2020-v100                  │
│ esa-worldcover-s2-swir-2021-v200                  │
│ gaofen-1-l2a-cog-edagro                           │
│ gaofen-1-l2a-cog-edagro-ag-cloud-mask             │
│ gaofen-6-l2a-cog-edagro                           │
│ gaofen-6-l2a-cog-edagro-ag-cloud-mask             │
│ goes                                              │
│ himawari-l1b                                      │
│ himawari-l2-cloud                                 │
│ huanjing-2-l2a-cog-edagro                         │
│ huanjing-2-l2a-cog-edagro-ag-cloud-mask           │
│ jilin-1-cog-edagro                                │
│ jilin-1-cog-edagro-ag-cloud-mask                  │
│ kazstsat-l2a-cog-edagro                           │
│ kazstsat-l2a-cog-edagro-ag-cloud-mask             │
│ landsat-c2l1                                      │
│ landsat-c2l1-data-coverage                        │
│ landsat-c2l2-sr                                   │
│ landsat-c2l2-st                                   │
│ landsat-l2-cog-ag-cloud-mask                      │
│ lulc-classification-map                           │
│ modis-43A4-061                                    │
│ modis-aqua-calibrated-radiance                    │
│ modis-calibrated-radiance                         │
│ modis-mod04-l2-061                                │
│ modis-mod07-l2-061                                │
│ modis-mod11-l2-061                                │
│ modis-mod11a2-061                                 │
│ modis-mod21-l2-061                                │
│ modis-mod21a2-061                                 │
│ modis-mod35-l2-061                                │
│ modis-myd11-l2-061                                │
│ modis-myd11a2-061                                 │
│ modis-myd21-l2-061                                │
│ modis-myd21a2-061                                 │
│ modis-myd35-l2-061                                │
│ mrc-catalog                                       │
│ mrc-l1c                                           │
│ msg-seviri                                        │
│ msg-seviri-cloud-mask                             │
│ nst-observer-catalog                              │
│ nst-observer-l1c                                  │
│ nst-observer-l2a                                  │
│ palsar-catalog                                    │
│ palsar-grd                                        │
│ public-crop-mask                                  │
│ resourcesat-2-l2a-cog-edagro                      │
│ resourcesat-2-l2a-cog-edagro-ag-cloud-mask        │
│ sentinel-1-grd                                    │
│ sentinel-1-rtc                                    │
│ sentinel-2-c1-l2a                                 │
│ sentinel-2-c1-l2a-data-coverage                   │
│ sentinel-2-eda-cloud-mask                         │
│ sentinel-2-eda-cloud-mask-data-coverage           │
│ sentinel-2-l1c                                    │
│ sentinel-2-l1c-copernicus                         │
│ sentinel-2-l1c-data-coverage                      │
│ sentinel-2-l1c-ml-cloud-mask                      │
│ sentinel-2-l2a                                    │
│ sentinel-2-l2a-cog-ag-cloud-mask                  │
│ sentinel-2-l2a-cog-ag-cloud-mask-geosys-private   │
│ sentinel-2-l2a-cog-edagro                         │
│ sentinel-2-l2a-cog-edagro-ag-cloud-mask           │
│ sentinel-2-l2a-copernicus                         │
│ sentinel-2-l2a-data-coverage                      │
│ sentinel-2-methane-product                        │
│ simedc-ai-ready-data                              │
│ simedc-ai-ready-data-clip                         │
│ simedc-analysis-ready-data                        │
│ simedc-analysis-ready-data-clip                   │
│ simedc-quick-ortho                                │
│ simedc-quick-ortho-clip                           │
│ simedc-swir-catalog                               │
│ simedc-swir-catalog-data-coverage                 │
│ simedc-swir-l1c                                   │
│ simedc-swir-l1c-clip                              │
│ simedc-swir-l2a                                   │
│ simedc-swir-l2a-clip                              │
│ simedc-tir-catalog                                │
│ simedc-tir-l1c                                    │
│ simedc-tir-l1c-clip                               │
│ simedc-visual-nrg                                 │
│ simedc-visual-nrg-clip                            │
│ simedc-visual-rgb                                 │
│ simedc-visual-rgb-clip                            │
│ simedc-vnir-catalog                               │
│ simedc-vnir-catalog-data-coverage                 │
│ simedc-vnir-l1c                                   │
│ simedc-vnir-l1c-clip                              │
│ simedc-vnir-l2a                                   │
│ simedc-vnir-l2a-clip                              │
│ typha-classification-map                          │
│ venus-l2a                                         │
│ venus-l2a-clip                                    │
│ viirs-vj103img-021                                │
│ viirs-vj121-002                                   │
│ viirs-vj121a1d-002                                │
│ viirs-vj121a1n-002                                │
│ viirs-vj121a2-002                                 │
│ viirs-vj203img-002                                │
│ viirs-vnp03img-002                                │
│ viirs-vnp21-002                                   │
│ viirs-vnp21a1d-002                                │
│ viirs-vnp21a1n-002                                │
│ viirs-vnp21a2-002                                 │
│ worldview-cog-edagro                              │
│ worldview-cog-edagro-ag-cloud-mask                │
│ zy-1-cog-edagro                                   │
│ zy-1-cog-edagro-ag-cloud-mask                     │
└───────────────────────────────────────────────────┘

Explore a specific collection

collection = eds.explore("sentinel-2-c1-l2a")
console.log(collection.properties)
[16:51:10] {                                                 summary_stack.py:36
               'type': 'Collection',
               'id': 'sentinel-2-c1-l2a',
               'stac_version': '1.1.0',
               'description': 'sentinel-2-c1-l2a',
               'links': [
                   {
                       'rel': 'self',
                       'href':
           'https://api.eds.earthdaily.com/archive/v1/stac/v
           1/collections/sentinel-2-c1-l2a',
                       'type': 'application/json'
                   },
                   {
                       'rel': 'parent',
                       'href':
           'https://api.eds.earthdaily.com/archive/v1/stac/v
           1',
                       'type': 'application/json'
                   },
                   {
                       'rel': 'items',
                       'href':
           'https://api.eds.earthdaily.com/archive/v1/stac/v
           1/collections/sentinel-2-c1-l2a/items',
                       'type': 'application/geo+json'
                   },
                   {
                       'rel': 'root',
                       'href':
           'https://api.eds.earthdaily.com/archive/v1/stac/v
           1',
                       'type': 'application/json',
                       'title': 'Platform API (STAC
           Compliant)'
                   }
               ],
               'stac_extensions': [
                   'https://earthdaily-stac-extensions.s3.am
           azonaws.com/eda_stats/v1.0.0/schema.json'
               ],
               'item_assets': None,
               'eda_stats:items': {
                   'count': 21646858,
                   'count_by_year': {
                       '2016': 13,
                       '2017': 24560,
                       '2018': 1329389,
                       '2019': 3164538,
                       '2020': 4013060,
                       '2021': 4054546,
                       '2022': 229686,
                       '2023': 4248426,
                       '2024': 4270753,
                       '2025': 311887
                   },
                   'count_by_year_month': {
                       '2016': {
                           '2016-01': 0,
                           '2016-02': 0,
                           '2016-03': 0,
                           '2016-04': 0,
                           '2016-05': 0,
                           '2016-06': 0,
                           '2016-07': 0,
                           '2016-08': 0,
                           '2016-09': 0,
                           '2016-10': 0,
                           '2016-11': 10,
                           '2016-12': 3
                       },
                       '2017': {
                           '2017-01': 0,
                           '2017-02': 0,
                           '2017-03': 0,
                           '2017-04': 0,
                           '2017-05': 0,
                           '2017-06': 0,
                           '2017-07': 0,
                           '2017-08': 0,
                           '2017-09': 0,
                           '2017-10': 0,
                           '2017-11': 7471,
                           '2017-12': 17089
                       },
                       '2018': {
                           '2018-01': 59009,
                           '2018-02': 80335,
                           '2018-03': 109996,
                           '2018-04': 27715,
                           '2018-05': 38889,
                           '2018-06': 207054,
                           '2018-07': 176060,
                           '2018-08': 326044,
                           '2018-09': 173226,
                           '2018-10': 102601,
                           '2018-11': 20345,
                           '2018-12': 8115
                       },
                       '2019': {
                           '2019-01': 11492,
                           '2019-02': 1896,
                           '2019-03': 109083,
                           '2019-04': 356023,
                           '2019-05': 366292,
                           '2019-06': 356429,
                           '2019-07': 374489,
                           '2019-08': 377073,
                           '2019-09': 350356,
                           '2019-10': 329114,
                           '2019-11': 268138,
                           '2019-12': 264153
                       },
                       '2020': {
                           '2020-01': 274873,
                           '2020-02': 295613,
                           '2020-03': 363105,
                           '2020-04': 367428,
                           '2020-05': 377523,
                           '2020-06': 368621,
                           '2020-07': 377952,
                           '2020-08': 379940,
                           '2020-09': 361598,
                           '2020-10': 321386,
                           '2020-11': 267295,
                           '2020-12': 257726
                       },
                       '2021': {
                           '2021-01': 279753,
                           '2021-02': 289577,
                           '2021-03': 365969,
                           '2021-04': 368585,
                           '2021-05': 381747,
                           '2021-06': 368355,
                           '2021-07': 382459,
                           '2021-08': 381743,
                           '2021-09': 364462,
                           '2021-10': 336941,
                           '2021-11': 271686,
                           '2021-12': 263269
                       },
                       '2022': {
                           '2022-01': 0,
                           '2022-02': 0,
                           '2022-03': 0,
                           '2022-04': 95,
                           '2022-05': 0,
                           '2022-06': 276,
                           '2022-07': 305,
                           '2022-08': 247,
                           '2022-09': 95,
                           '2022-10': 500,
                           '2022-11': 263,
                           '2022-12': 227905
                       },
                       '2023': {
                           '2023-01': 299787,
                           '2023-02': 321719,
                           '2023-03': 383914,
                           '2023-04': 376481,
                           '2023-05': 394324,
                           '2023-06': 381254,
                           '2023-07': 394887,
                           '2023-08': 390863,
                           '2023-09': 379158,
                           '2023-10': 356207,
                           '2023-11': 290943,
                           '2023-12': 278889
                       },
                       '2024': {
                           '2024-01': 289156,
                           '2024-02': 317466,
                           '2024-03': 380890,
                           '2024-04': 378933,
                           '2024-05': 388073,
                           '2024-06': 375486,
                           '2024-07': 389872,
                           '2024-08': 384454,
                           '2024-09': 374943,
                           '2024-10': 358962,
                           '2024-11': 303460,
                           '2024-12': 329058
                       },
                       '2025': {
                           '2025-01': 296419,
                           '2025-02': 15468,
                           '2025-03': 0,
                           '2025-04': 0,
                           '2025-05': 0,
                           '2025-06': 0,
                           '2025-07': 0,
                           '2025-08': 0,
                           '2025-09': 0,
                           '2025-10': 0,
                           '2025-11': 0,
                           '2025-12': 0
                       }
                   }
               },
               'title': 'Sentinel 2 C1 L2A',
               'extent': {
                   'spatial': {
                       'bbox': [
                           [
                               -180.0,
                               -82.85171,
                               180.0,
                               82.81936
                           ]
                       ]
                   },
                   'temporal': {
                       'interval': [
                           [
                               '2016-11-02T10:01:49.457000Z'
           ,
                               '2025-02-03T11:44:01.906000Z'
                           ]
                       ]
                   }
               },
               'license': 'proprietary'
           }

List properties available per item

table = Table("properties", "values", "dtype", title=f"Properties for {collection}")
for k, v in collection.item_properties.items():  # item_properties is a dict
    table.add_row(k, str(v), type(v).__name__)
console.print(table)
            Properties for Exploring collection "sentinel-2-c1-l2a"
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━┓
┃ properties                        ┃ values                           ┃ dtype ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━┩
│ constellation                     │ sentinel-2                       │ str   │
│ created                           │ 2025-02-03T16:02:50.564829Z      │ str   │
│ datetime                          │ 2025-02-03T12:22:31.510000Z      │ str   │
│ earthsearch:payload_id            │ roda-sentinel-2-c1-l2a/workflow… │ str   │
│ eda:ag_cloud_mask_available       │ False                            │ bool  │
│ eda:cloud_mask_available          │ False                            │ bool  │
│ eda:loose_validation_status       │ VALID                            │ str   │
│ eda:source_created                │ 2025-02-03T16:02:24.966538+00:00 │ str   │
│ eda:source_updated                │ 2025-02-03T16:02:24.966538+00:00 │ str   │
│ eda:status                        │ PUBLISHED                        │ str   │
│ eda:tracking_id                   │ kzikTmUhQvGe8ZbrL87Exz           │ str   │
│ eo:cloud_cover                    │ 99.980175                        │ float │
│ grid:code                         │ MGRS-20CPE                       │ str   │
│ instruments                       │ ['msi']                          │ list  │
│ mgrs:grid_square                  │ PE                               │ str   │
│ mgrs:latitude_band                │ C                                │ str   │
│ mgrs:utm_zone                     │ 20                               │ int   │
│ platform                          │ sentinel-2b                      │ str   │
│ processing:software               │ {'sentinel-2-c1-l2a-to-stac':    │ dict  │
│                                   │ 'v2024.02.01'}                   │       │
│ proj:centroid                     │ {'lat': -72.03777, 'lon':        │ dict  │
│                                   │ -57.03583}                       │       │
│ proj:code                         │ EPSG:32720                       │ str   │
│ s2:cloud_shadow_percentage        │ 0.0                              │ float │
│ s2:datastrip_id                   │ S2B_OPER_MSI_L2A_DS_2BPS_202502… │ str   │
│ s2:datatake_id                    │ GS2B_20250203T122219_041333_N05… │ str   │
│ s2:datatake_type                  │ INS-NOBS                         │ str   │
│ s2:degraded_msi_data_percentage   │ 0.0201                           │ float │
│ s2:generation_time                │ 2025-02-03T15:20:30.000000Z      │ str   │
│ s2:high_proba_clouds_percentage   │ 61.546808                        │ float │
│ s2:medium_proba_clouds_percentage │ 18.234275                        │ float │
│ s2:nodata_pixel_percentage        │ 99.364066                        │ float │
│ s2:not_vegetated_percentage       │ 0.0                              │ float │
│ s2:processing_baseline            │ 05.11                            │ str   │
│ s2:product_type                   │ S2MSI2A                          │ str   │
│ s2:product_uri                    │ S2B_MSIL2A_20250203T122219_N051… │ str   │
│ s2:reflectance_conversion_factor  │ 1.03049113348831                 │ float │
│ s2:saturated_defective_pixel_per… │ 0.0                              │ float │
│ s2:snow_ice_percentage            │ 0.0                              │ float │
│ s2:thin_cirrus_percentage         │ 20.19909                         │ float │
│ s2:tile_id                        │ S2B_OPER_MSI_L2A_TL_2BPS_202502… │ str   │
│ s2:unclassified_percentage        │ 0.0                              │ float │
│ s2:vegetation_percentage          │ 0.0                              │ float │
│ s2:water_percentage               │ 0.019826                         │ float │
│ storage:platform                  │ AWS                              │ str   │
│ updated                           │ 2025-02-03T16:02:50.564829Z      │ str   │
│ view:azimuth                      │ 131.95578017539592               │ float │
│ view:incidence_angle              │ 3.6339017788991446               │ float │
│ view:off_nadir                    │ 3.633901778899144                │ float │
│ view:sun_azimuth                  │ 61.9065239645471                 │ float │
│ view:sun_elevation                │ 25.402460370309498               │ float │
└───────────────────────────────────┴──────────────────────────────────┴───────┘

Read assets and metadata

table = Table("assets", "common_name", "description", title=f"Assets for {collection}")
for asset in collection.assets():
    table.add_row(
        asset,
        collection.assets(asset).get("eo:bands", [{}])[0].get("common_name"),
        collection.assets(asset).get("eo:bands", [{}])[0].get("description"),
    )
console.print(table)
         Assets for Exploring collection
               "sentinel-2-c1-l2a"
┏━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━━━━━━┓
┃ assets            ┃ common_name ┃ description ┃
┡━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━╇━━━━━━━━━━━━━┩
│ aot               │             │             │
│ aot-10m-jp2       │             │             │
│ aot-20m-jp2       │             │             │
│ aot-60m-jp2       │             │             │
│ blue              │ blue        │             │
│ blue-10m-jp2      │             │             │
│ blue-20m-jp2      │             │             │
│ blue-60m-jp2      │             │             │
│ cloud             │             │             │
│ coastal           │ coastal     │             │
│ coastal-20m-jp2   │             │             │
│ coastal-60m-jp2   │             │             │
│ granule_metadata  │             │             │
│ green             │ green       │             │
│ green-10m-jp2     │             │             │
│ green-20m-jp2     │             │             │
│ green-60m-jp2     │             │             │
│ nir               │ nir         │             │
│ nir-10m-jp2       │             │             │
│ nir08             │ nir08       │             │
│ nir08-20m-jp2     │             │             │
│ nir08-60m-jp2     │             │             │
│ nir09             │ nir09       │             │
│ nir09-60m-jp2     │             │             │
│ preview           │ red         │             │
│ product_metadata  │             │             │
│ red               │ red         │             │
│ red-10m-jp2       │             │             │
│ red-20m-jp2       │             │             │
│ red-60m-jp2       │             │             │
│ rededge1          │ rededge     │             │
│ rededge1-20m-jp2  │             │             │
│ rededge1-60m-jp2  │             │             │
│ rededge2          │ rededge     │             │
│ rededge2-20m-jp2  │             │             │
│ rededge2-60m-jp2  │             │             │
│ rededge3          │ rededge     │             │
│ rededge3-20m-jp2  │             │             │
│ rededge3-60m-jp2  │             │             │
│ scl               │             │             │
│ scl-20m-jp2       │             │             │
│ scl-60m-jp2       │             │             │
│ snow              │             │             │
│ swir16            │ swir16      │             │
│ swir16-20m-jp2    │             │             │
│ swir16-60m-jp2    │             │             │
│ swir22            │ swir22      │             │
│ swir22-20m-jp2    │             │             │
│ swir22-60m-jp2    │             │             │
│ thumbnail         │             │             │
│ tileinfo_metadata │             │             │
│ visual            │ red         │             │
│ visual-10m-jp2    │             │             │
│ visual-20m-jp2    │             │             │
│ visual-60m-jp2    │             │             │
│ wvp               │             │             │
│ wvp-10m-jp2       │             │             │
│ wvp-20m-jp2       │             │             │
│ wvp-60m-jp2       │             │             │
└───────────────────┴─────────────┴─────────────┘

Total running time of the script: (0 minutes 1.860 seconds)

Gallery generated by Sphinx-Gallery