Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

earth and related environmental sciences

Surface Water Level Monitoring with Sentinel-2

Timeseries of water covered area at Santa Giustina lake, Italy

Authors
Affiliations
Eurac Research
Eurac Research
ESA EOPF Zarr Logo

🚀 Launch in JupyterHub

Run this notebook interactively with all dependencies pre-installed

Introduction

This notebook demonstrates how to estimate and visualize surface water area measurements at Santa Giustina lake, Italy, using Sentinel-2 data stored in EOPF-Zarr format.

The lake

Lago di Santa Giustina is an artificial lake located in the Trentino region of northern Italy. It was created in the 1950s by damming the Noce River for hydroelectric power generation. The lake is situated at an elevation of approximately 500 meters above sea level and has a surface area of about 3.5 square kilometers.

Lago di Santa Giustina

Image source: By Mosco - Own work, CC BY-SA 3.0, https://commons.wikimedia.org/w/index.php?curid=5144281

Setup

Start importing the necessary libraries

Loading...

Access data

Query the EOPF Sentinel-2 STAC Collection for the area and time of interest.

items found: 434

Combine the products into a single datacube:

CPU times: user 3.12 s, sys: 181 ms, total: 3.3 s
Wall time: 35.2 s
Loading...

Open the geoJSON file containing the lake boundaries:

Visualize datacube sample

In this section we visualize an RGB composite for a random date and use the lake polygon as an outline to see if it is aligned correctly.

<Figure size 800x800 with 1 Axes>

Cloud masking

In this section we apply the scl band to mask out the clouds. We visualize the same RGB composite as before, but with the mask applied.

<Figure size 800x800 with 1 Axes>

We keep only the dates with a cloud coverage less than 5% over the lake:

Loading...

NDWI

Water detection is performed using the Normalized Difference Water Index (NDWI), which utilizes the green and near-infrared (NIR) bands of the Sentinel-2 imagery. The NDWI is calculated as follows:

NDWI=GREEN−NIRGREEN+NIRNDWI = \frac {GREEN - NIR} {GREEN + NIR}

Water detection

The water area is selected applying Otsu Thresholding:

Loading...

Sample visualization of computed water mask:

<Figure size 800x800 with 1 Axes>

Water surface area extraction

<Figure size 1200x500 with 1 Axes>