{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Simple load collection example: ESA WorldCover\n",
"\n",
"\n",
"This notebook is a simple example of how to load the ESA WorldCover dataset using the `load_collection` function from the `openeo` Python package. Here we will load the ESA WorldCover dataset for the year 2021 apply simple UDF and visualize the result."
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Authenticated using refresh token.\n"
]
}
],
"source": [
"import openeo\n",
"import json\n",
"import folium\n",
"import xarray as xr\n",
"import numpy as np\n",
"import matplotlib.pyplot as plt\n",
"import matplotlib.colors as mcolors\n",
"\n",
"\n",
"# connect to the federated backend\n",
"connection = openeo.connect(\"openeo.dataspace.copernicus.eu\").authenticate_oidc()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"List the available collections from the backend and fetch its description."
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"['SENTINEL3_OLCI_L1B',\n",
" 'SENTINEL3_SLSTR',\n",
" 'SENTINEL_5P_L2',\n",
" 'COPERNICUS_VEGETATION_PHENOLOGY_PRODUCTIVITY_10M_SEASON1',\n",
" 'COPERNICUS_VEGETATION_PHENOLOGY_PRODUCTIVITY_10M_SEASON2',\n",
" 'COPERNICUS_PLANT_PHENOLOGY_INDEX',\n",
" 'ESA_WORLDCOVER_10M_2020_V1',\n",
" 'ESA_WORLDCOVER_10M_2021_V2',\n",
" 'COPERNICUS_VEGETATION_INDICES',\n",
" 'SENTINEL2_L1C',\n",
" 'SENTINEL2_L2A',\n",
" 'SENTINEL1_GRD',\n",
" 'COPERNICUS_30',\n",
" 'LANDSAT8_L2',\n",
" 'SENTINEL3_SYN_L2_SYN',\n",
" 'SENTINEL3_SLSTR_L2_LST',\n",
" 'SENTINEL1_GLOBAL_MOSAICS']"
]
},
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"connection.list_collection_ids()"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"\n",
" \n",
"