Google Earth Engine(GEE)下载landsat影像
生活随笔
收集整理的這篇文章主要介紹了
Google Earth Engine(GEE)下载landsat影像
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
今天分享一下如何在GEE中下載landsat影像,以landsat8為例,因為我的目標是下載地表真實影像,所以選擇的數據集為’LANDSAT/LC08/C01/T1_SR;這個數據集已經進行過輻射定標和大氣校正;運行代碼如下:
研究區還是以山西省為例
//以山西省為研究區 var roi = ee.FeatureCollection("users/lilei655123/shanxi"); // 去云函數 function maskL8sr(image) {// Bits 3 and 5 are cloud shadow and cloud, respectively.var cloudShadowBitMask = (1 << 3);var cloudsBitMask = (1 << 5);// Get the pixel QA band.var qa = image.select('pixel_qa');// Both flags should be set to zero, indicating clear conditions.var mask = qa.bitwiseAnd(cloudShadowBitMask).eq(0).and(qa.bitwiseAnd(cloudsBitMask).eq(0));return image.updateMask(mask); } //Landsat8SR數據,經過輻射定標和大氣校正 var l8SR = ee.ImageCollection('LANDSAT/LC08/C01/T1_SR').filterBounds(roi).filterDate('2020-06-01', '2020-09-30').map(maskL8sr).select('B1','B2','B3','B4','B5','B6','B7','B10','B11').median() //中值合成.clip(roi)print("l8SR",l8SR)var rgbVis = {min: 0.0,max: 3000,gamma: 1.4,bands: ['B4', 'B3', 'B2'], };Map.addLayer(l8SR, rgbVis, 'l8SR'); Map.centerObject(roi,7)//boundary var styling = {color:"red",fillColor:"00000000"}; Map.addLayer(roi.style(styling),{},"geometry")//影像導出函數 Export.image.toDrive({image: l8SR.select('B4', 'B3', 'B2'),description: 'l8SR',crs: "EPSG:4326",scale: 30,region: roi,maxPixels: 1e13,folder: 'shanxi' });因為我的目標是查看地表的真實影像,所以選用波段為’B4’, ‘B3’, ‘B2’,為真彩色合成
顯示結果如下:
下載至云盤:
感謝關注,歡迎轉發!
聲明:僅供學習使用!
更多內容請關注微信公眾號“生態遙感監測筆記”:
總結
以上是生活随笔為你收集整理的Google Earth Engine(GEE)下载landsat影像的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: python批量爬取下载网易云音乐
- 下一篇: 软件工程理论与实践学习——炸鸡的序言