Skip to content

PRACTICE 09

CZU Lightning Complex Burn Severity

goal

This tutorial introduces a general workflow to map the burn severity of wildfire with Sentinel-2 MSI data.

We will use the CZU Lightning Complex fires on California’s Slow Coast as a case study. This practice problem complements a research article on CZU impacts to the old growth forests in Big Basin Redwoods State Park (Potter 2023).

Your script should reproduce the map layers shown in the app below.


open app in new tab


deliverables

Please take the checkup on Canvas by 5pm Friday 11/15. This checkup will ask you to report checkpoint answers and will be automatically graded, so you will be able to retake the checkup as many times as you would like until 5pm on Monday 11/18. Your final score for the checkup will be your maximum score.


workflow

Please work through the steps outlined below.


00 Start a script

Start a new script with the code block below. I define an area of interest for you by buffering a point near Bonny Doon, California. For the checks to work, please use this aoi.

/*    
// ><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><

    AUTHOR:   
    DATE:      
    TITLE:    09 Practice - CZU burn severity

// ><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><
*/

var geo = require("users/jhowarth/eePatterns:modules/geo.js");

print("geo methods dictionary", geo.help);    // Prints dictionary of all tools in module.  

var geometry = 

    ee.Geometry.Point([-122.2241722048408, 37.148316599201095]);

var aoi = geometry.buffer(20 * 1000);

01 Set up map

// -------------------------------------------------------------
//  1. SET UP MAP.
// -------------------------------------------------------------

// Center map on AOI at zoom 10.



// Set base map to terrain.

02 Make post-burn image

// -------------------------------------------------------------
//  2. MAKE POST-BURN IMAGE.
// -------------------------------------------------------------

Please adapt the S2 starter script for this step. Your post-burn image should:

  1. Filter by aoi location.
  2. Filter for September 2020.
  3. Filter for images with less that 20% cloud cover.
  4. Apply the scale and cloud mask methods for S2.
  5. Flatten to median image.
  6. Clip image by aoi (see pattern below).
  7. Display RGB as SWIR2, NIR, Red
  8. Stretch enhance the RGB composite.

To clip the image, please use this method :

 var clipped_image = image.clip(aoi)

03 Make pre-burn image

// -------------------------------------------------------------
//  3. MAKE PRE-BURN IMAGE.
// -------------------------------------------------------------

Your pre-burn image should replicate the criteria of Step 2 with one exception: you now want to filter for 2019. This image should show conditions in the same place and season for the year before the burn.


04 Map post-burn NBR

// -------------------------------------------------------------
//  4. MAP NORMALIZED BURN RATIO FOR POST-BURN SNAPSHOT
// -------------------------------------------------------------

For this step, you will need to:

  1. Load spectral indices module.
  2. Define parameters for Sentinel 2 Surface Reflectance.
  3. Compute NBR index.
  4. Isolate NBR band as a new single-band image.
  5. Display result as map layer using the viz parameters defined below.
var nbr_viz = {bands: ["NBR"], min:-1, max:1, palette: ['purple', 'white', 'green']};

05 Map pre-burn NBR

// -------------------------------------------------------------
//  5. MAP NORMALIZED BURN RATIO FOR PRE-BURN SNAPSHOT
// -------------------------------------------------------------

You do not need to reload the spectral indices module, since you already did that above. You will need to do the other steps described above (2-5) using the pre-burn image as the input.


06 Map burn severity

From the readings this week, you saw that burn severity is the change in NBR caused by a fire.

burn-severity

Please calculate and map the burn severity based on your two NBR images.

// ------------------------------------------------------------------------
//  6. MAP BURN SEVERITY INDEX.
// ------------------------------------------------------------------------

07 Reclassify burn severity

Please use the thresholds shown below to reclassify the burn severity image.

usu-thresholds

// ------------------------------------------------------------------------
//  7. RECLASSIFY BURN SEVERITY BASED ON USGS THRESHOLDS. 
// ------------------------------------------------------------------------

// Viz parameters for classified layer.

var burn_severity_viz = {
  min: 0,
  max: 6,
  palette: [
    '#778735', 
    '#a7c04f', 
    '#07e444', 
    '#f6fc0d', 
    '#f7b140', 
    '#f86819', 
    '#a601d4'
  ]
};

08 Add legend

// ------------------------------------------------------------------------
//  8. ADD BURN SEVERITY CLASS LEGEND TO MAP. 
// ------------------------------------------------------------------------

var burn_severity_labels = [
  'High post-fire regrowth',
  'Low post-fire regrowth',
  'Unburned',
  'Low Severity',
  'Moderate-low Severity',
  'Moderate-high Severity',
  'High Severity'
  ]
;

// Make legend from image with nominal data.

var legend_nominal = geo.iCart.legendNominal(
  "Burn Severity Classes", 
  burn_severity_viz, 
  burn_severity_labels, 
  "bottom-left"
  )
;

// Add legend to Map.  

Map.add(legend_nominal);

09 Make ocean mask

// ------------------------------------------------------------------------
//  9. MAKE OCEAN MASK. 
// ------------------------------------------------------------------------
  1. Gather an image from this cloud address: “NASA/NASADEM_HGT/001”.
  2. Select “elevation” band.
  3. Make a boolean image where land is 1 and ocean is 0.
  4. Display mask as a Map layer.

10 Display burn severity with mask

// ------------------------------------------------------------------------
//  10. DISPLAY BURN SEVERITY WITH OCEAN MASK. 
// ------------------------------------------------------------------------

// Display the burn severity class image with the ocean mask with opacity of 0.6.
// All other layers should not be displayed by default. 

CHECKS

// ----------------------------------------------------------------------
//  CHECKS
//
//  Please update the "result_step#" variable as needed for each step.  
// ----------------------------------------------------------------------

var check = require('users/jhowarth/eePatterns:checks/p09.js');

check.checkPoint("CHECK STEP 2:", result_step2.select("B8"));
check.checkPoint("CHECK STEP 3:", result_step3.select("B8"));
check.checkPoint("CHECK STEP 4:", result_step4);
check.checkPoint("CHECK STEP 5:", result_step5);
check.checkPoint("CHECK STEP 6:", result_step6);
check.checkPoint("CHECK STEP 7:", result_step7);
check.checkPoint("CHECK STEP 9:", result_step9);

This work is licensed under CC BY-NC-SA 4.0