In this tutorial, we will try to perform the change detection using the SAR images from the Sentinel-1 satellite images in the Google Earth Engine. As the SAR images are acquired in different polarisation medium namely VV, HH, VH, and HV, we will focus on dual polarisation medium VV and VH. Also, we will be using consistent orbital pass (among DESCENDING and ASCENDING) for processing.

The study side is the Lao dam break of 2018. We will be using one image from before and after the event, and try to find the change detection from those images. Here are the steps that are involved:

  1.  Import the SAR images and get the study area as well as the date of the event. We will get the before and after images of the event.
    var sentinel1 = e.ImageCollection("COPERNICUS/S1_GRD");
    var geometry = ee.Geometry.Point([106.57631034309566, 14.918421303522576]);
    var beforeStartDate = '2018-07-01';
    var beforeEndDate = '2018-07-15';
    var afterStartDate = '2018-07-23';
    var afterEndDate = '2018-07-30';
  2. Next filter the sentinel1 collection to the geometry and the date of the events.
    var sentinel1Before = sentinel1.filterBounds(geometry).filterDate(beforeStartDate, beforeEndDate);
    var sentinel1After = sentinel1.filterBounds(geometry).filterDate(afterStartDate, afterEndDate);
  3. Now we will filter the images to contain the VV and VH polarisation as we will be using VV/VH ratio for the change detection and the DESCENDING orbital pass
    sentinel1Before = sentinel1Before.filter(ee.Filter.listContains('transmitterReceiverPolarisation', 'VV')).filter(ee.Filter.listContains('transmitterReceiverPolarisation', 'VH'));
    sentinel1Before = sentinel1Before.filter(ee.Filter.eq('orbitProperties_pass', 'DESCENDING'));
    sentinel1After = sentinel1After.filter(ee.Filter.listContains('transmitterReceiverPolarisation', 'VV')).filter(ee.Filter.listContains('transmitterReceiverPolarisation', 'VH'));
    sentinel1After = sentinel1After.filter(ee.Filter.eq('orbitProperties_pass', 'DESCENDING'));
  4. We will now convert the dB values to Amplitude (A) and then to Intensity (I). Intensity is the square of the Amplitude.
    I = A * A

    The Amplitude from the dB value can be converted as

    A = 10 ^ (db/20)

    We also filter the dB values between -30 dB to 30 dB as a threshold for better result.

    var intensityConversion = function (img) {
      img = img.updateMask(img.gte(-30));
      img = img.updateMask(img.lte(30));
      // Amplitude
      var VV = img.expression( '10 ** (VV / 20)', {'VV':'VV')});
      VV =['constant'], ['VV']);
      var VH = img.expression( '10 ** (VH / 20)', {'VH':'VH')});
      VH =['constant'], ['VH']);
      // Intensity
      VV = VV.multiply(VV);
      VH = VH.multiply(VH);
      return VV.addBands(VH);
    var intensityBefore =;
    var intensityAfter =;
  5. Let’s add these images to the Map and see the result. If you look carefully, the terrain correction with Sentinel-1 images is not that great with the GEE. According to Google as described here, the Sentinel-1 images do not take terrain in the account, the merging to cross polarisation might have issues with the align and the might have some strip problem along the border. You can compare those results from SNAP and see the difference.
    However, the change detection from GEE matches very closely with that from SNAP. So the change detection can be done with GEE but analysis using single images might not be a great idea especially because of prevalent terrain.

    Map.addLayer(intensityBefore, {bands: 'VV', min: 0, max: 0.8}, 'intensityBefore');
    Map.addLayer(intensityAfter, {bands: 'VV', min: 0, max: 0.8}, 'intensityAfter');
  6. The last step is the calculation of the Change Detection images. The change detection can be calculated as the difference between after and before images. For intensity unit, it is the ratio of the after and before images.
    var change ='VV').divide('VV'));
    Map.addLayer(change, {bands: 'VV', min: 0.5, max: 1.5}, 'change');


The link to the change detection using GEE can be found here.
Happy Earth Science 🙂