Over the weekend, as I scrolled through my Twitter feed, I saw the news about Dubai Airport getting flooded during a rare storm (more than 250 mm of rainfall in 24 hours!!). I hoped to find clear satellite images to demonstrate a simple method of separating flooded and non-flooded areas. Luckily, Sentinel-2 captured two images on April 7th (pre-flood event) and 17th (post-flood event), mostly free of clouds over Dubai. Those images sparked my interest in writing a story about detecting flood events using satellite images.
In this post, we begin by downloading Sentinel-2 imagery of a flooded location in Dubai using a Python script. Then, we’ll use the rasterio package to read the imagery and compute the Normalized Difference Water Index (NDWI) using near-infrared and green bands. Afterward, we’ll plot histograms of NDWI for both pre and post-flood images. Comparing these histograms will reveal how dry areas in the pre-flood image shifted to wet areas in the post-flood image. Finally, we’ll separate the flooded pixels using a threshold extracted from the histogram analysis and map the flooded regions. If this sounds interesting, keep reading!
- 🌅 Introduction
- 💾 Downloading Sentinel-2 Imagery