天天看點

Google Earth Engine(GEE)—— ImageCollection 影像集合上的映射

每次Image在ImageCollection使用imageCollection.map()。的唯一參數map()是一個接受一個參數的函數:一個ee.Image。

代碼中所反應的主要是通過循環周遊添加這個時間波段。

Google Earth Engine(GEE)—— ImageCollection 影像集合上的映射
Google Earth Engine(GEE)—— ImageCollection 影像集合上的映射
Google Earth Engine(GEE)—— ImageCollection 影像集合上的映射
// 加載一個明确行列号的影像
var collection = ee.ImageCollection('LANDSAT/LC08/C01/T1_TOA')
  .filter(ee.Filter.eq('WRS_PATH', 44))
  .filter(ee.Filter.eq('WRS_ROW', 34));

// 建立一個函數主要是給影像添加一個波段(時間).
var addTime = function(image) {
  return image.addBands(image.metadata('system:time_start'));
};

// 就是周遊整個影像,添加時間波段
print(collection.map(addTime));      

繼續閱讀