Tìm kiếm

Fun with Google Earth Engine

In recent time, the question of "where to find data?" is no longer a big concern. Another bigger issue has emerged, which relates ...

In recent time, the question of "where to find data?" is no longer a big concern. Another bigger issue has emerged, which relates to "what sort of information that can be extracted from data?".

Storing raw data as files in hard disks or storage media is also no longer fashionable because "we don't have to do it, all of them are in the cloud now".

A few lines of codes below demonstrate how to use Google Earth Engine to find and extract information from cloud storage (by Google) and show them in the way you like. Of course, if you're good enough at Java programming, you can manipulate and analyze this data and turn it into more valuable information.... in a flash.



The codes work in a few seconds to acquire, select and display monthly average temperature, plus  accumulated rainfall across the country of Vietnam. You can modify desired time period to get more data if you wish. My codes are free.




// Fun with weather information, monthly values
// Written by Phuong Do, Sep 2018
// Data sources: CHIRPS (rainfall) and MODIS (temperature). Resolution: 1km
//==========================================================


var before = '2017-01-01';
var after = '2017-01-31';

//==========================================================
// Data sources

var PRE = ee.ImageCollection("UCSB-CHG/CHIRPS/DAILY")
.select(['precipitation'])
.filterDate(before, after)
.sort('system:time_start', true);

var LST = ee.ImageCollection("MODIS/006/MOD11A1")
.select(['LST_Day_1km'])
.filterDate(before, after)
.sort('system:time_start', true);

//==========================================================

var meanLST = LST.reduce('mean');
meanLST = meanLST.multiply(0.02).subtract(273.15);
var meanPRE = PRE.sum();

Map.addLayer(meanLST,{palette: '#09b6ff, #f1ff07, #e00303', min: 0, max: 50},"Temperature",false);
Map.addLayer(meanPRE,{palette: '#dbfffc, #29c9ff, #66aeff, #3801ff', min: 0, max: 2000},"Precipitation",false);


To run codes, you need to register an account with Google Earth Engine. For ones who do not have GEE's account, see the outputs below.









Xem thêm

3 Comments

  1. hi ...how to embed Google earth engine data with my web

    Trả lờiXóa
  2. Google Earth Engine does not support to embed data and interface into other web applications. You may need to go around with some Python codes. See this example for demo: https://github.com/google/earthengine-api.

    Trả lờiXóa
  3. There's a case to publish your GEE project which is using Earth Engine Apps: https://developers.google.com/earth-engine/apps

    Trả lờiXóa