Skip to content

Generates a merged raster mosaic for the entire AMD0 boundary, overcoming DEA sandbox disk and memory limitations.

License

Notifications You must be signed in to change notification settings

rhinejoel/dea-mosaic-builder

Repository files navigation

Contributors Forks Stargazers Issues MIT License LinkedIn



Readme header image showing pre-flood and flood outputs using the RWD raster builder for a location in Lake Chad, Chad, Africa.


RWD Raster Builder

The RWD Raster Builder, builds a raster dataset using the Digital Earth Africa (DEA) Toolkit based on Sentinel-1 analysis-ready radar backscatter data. Sentinel-1, operated by the ESA as part of the Copernicus Program provides these observatiosns every 6-12 days over Africa. This gives near real-time data for accurate field analysis and estimation.

The DEA Toolkit also has ready-to-work workflows of complex real-world problems that can be cutomized to requirements. More on this can be found on the Read World Examples page. A major part of the flood-mosaic Jupyter Notebook was developed using the Water Detection With Sentinel-1, which is one of the real world examples in the DEA Toolkit.


The Jupyter Notebooks in this repository run in the DEA Analysis Sandbox.


Table of Contents
  1. Prerequisites
  2. Clone Repository
  3. Create Directories
  4. Run Notebook
  5. Contributors
  6. License
  7. Contact
  8. References


1. Prerequisites

The DEA Analysis Sandbox runs on the DEA server, which is an AWS EC2 instance. In order to access the Sandbox, create an account by following the instructions on the Getting Started Page

Navigate to the Login page, once the account has been created.

After logging in, choose the default environment with 2 Cores and 16 GB RAM. Hit "Start" and the server should begin starting up.



Image of the Digital Earth Africa analysis sandbox environment selection. Two options shown - Default Environment with 2 cores and 14 GB RAM and Large environment with 4 cores and 32 GB RAM


If for some reason this environment is slow, a later switch to the large environment is possible as well, without any loss of data


2. Clone Repository



Image of new project folder creation process and new terminal launch within the project folder



  1. Navigate to the root directory by clicking the "folder" icon in directory path
  2. In the root directory, create a new folder with any project name. Open the project folder
  3. Inside the project folder, click on the "+" icon and select "Terminal". This will open a terminal in the project folder
  4. Copy the command below. Click on the Terminal window, paste and hit "Enter"


    git pull https://github.com/rhinejoel/rwd-raster-builder.git


Image of the Digital Earth Africa analysis sandbox environment selection. Two options shown - Default Environment with 2 cores and 14 GB RAM and Large environment with 4 cores and 32 GB RAM


The repo will be cloned to the new project directory.


Contents of the directory may differ from that of the image. The image just serves as a reference


3. Create Directories

Create two new folders inside the repo directory and name them "input" and "output".


These directories are required for data management and proper functioning of the code


Open the "input" directory and upload the gridded vector (geojson) file here.


The CRS of the vector file must be EPSG:4326 and the grid size must be 0.1 degrees


If using ESRI shapefile, upload all the auxillary files individually along with the .shp file


4. Run Notebook

Ensure all steps have been followed and a proper vector file is present in the "input" folder.

Once done, in the "Customize Data" section of the notebook, make changes based on requirements and the vector file name


    # DEFINE PERIODS
    pre_flood = ['2024-04-15', '2024-05-15', '2024-06-15', '2023-07-15'] # 4 MONTHS PRIOR
    flood = ['2024-07-26', '2024-08-26', '2024-09-26', '2024-10-15'] # 4 MONTHS DURING

    # DEFINE THRESHOLD
    threshold_vh = -35  # IF REQUIRED

    # UPLOAD FILE
    grid = gpd.read_file("input/vector_file_name.geojson")

Save changes in the notebook and run.


5. Contributors:

contrib.rocks image

6. License

Distributed under the MIT License. See LICENSE.txt for more information.

7. Contact

Joel Rhine: Email Website Link: Joel Rhine | Home

8. References