angyaloliver / bip-ml4eo

Repository for the Machine Learning for Earth Observation Summer School in Cremona, Italy

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

bip-ml4eo

Repository for the Machine Learning for Earth Observation Summer School in Pavia, Italy

Setup environment

Setup the conda environment locally with:

conda env create -f conda-env.yml

Or use mamba instead (identical result with faster dependency solving):

mamba env create -f conda-env.yml

This will create an environment named bip-ml4eo. Activate with:

conda activate bip-ml4eo

Now you can run the code and develop in this repo (except for non-Python code).

Download the data

The Sentinel-2 data has been uploaded to Kaggle: see sentinel-2-cremona dataset. The ancillary data (hydrometric levels) is on Google Drive here.

The data should be downloaded at data/Water/ with the folder tree as below:

data/Water
├── Cremona SIAP - Livello Idrometrico - 2023-01-12.csv
└── sentinel-2-cremona
    ├── images
    │   ├── S2A_MSIL2A_20220309T100841_N0400_R022_T32TNQ_20220309T134626.tif
    │   ├── S2A_MSIL2A_20220309T100841_N0400_R022_T32TNR_20220309T134626.tif
    │   ├── S2A_MSIL2A_20220322T101711_N0400_R065_T32TNQ_20220322T141030.tif
    │   ├── S2A_MSIL2A_20220322T101711_N0400_R065_T32TNR_20220322T141030.tif
    │   ├── ...
    └── S2_Cremona_DESCENDING_info.csv

Merge Sentinel-2 raster tiles

Merge the Sentinel-2 raster tiles with:

python src/merge_s2_tiles.py

This should take approx. 3-4 min to complete. This should create 31 merged images in total. The merge dataset will be in the output directory data/Water/sentinel-2-cremona/merged-images.

Notebook of analyses

This notebook contains Olivèr's work.

About

Repository for the Machine Learning for Earth Observation Summer School in Cremona, Italy


Languages

Language:Jupyter Notebook 99.8%Language:Python 0.2%Language:Shell 0.0%