Last active
July 16, 2022 11:14
-
-
Save PratyushTripathy/cedb767fffd6c3bc1305149a393dffa2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// query landsat 8 collection for given AOI | |
var band_names = ['Blue', 'Green', 'Red', 'NIR', 'SWIR1', 'Thermal', 'SWIR2']; | |
var landsat8 = ee.ImageCollection("LANDSAT/LC08/C02/T1_L2") | |
.filterBounds(geometry) | |
.filterDate('2020-03-15', '2020-03-25') | |
.filter(ee.Filter.lte('CLOUD_COVER', 5)) | |
.select( | |
['SR_B2', 'SR_B3', 'SR_B4', 'SR_B5', 'SR_B6', 'ST_B10', 'SR_B7'], | |
band_names | |
); | |
print(landsat8); | |
// Seggregate master and slave scenes using path numbers | |
var master = landsat8.filter(ee.Filter.eq('TARGET_WRS_PATH', 144)).first(); | |
var slave = landsat8.filter(ee.Filter.eq('TARGET_WRS_PATH', 143)).first(); | |
// Define visualisation parameters and display | |
var l8_vis_params = {bands: ['NIR', 'Red', 'Green'], min: 5000, max: 23000}; | |
Map.addLayer(master, l8_vis_params, 'Master'); | |
Map.addLayer(slave, l8_vis_params, 'Slave'); | |
Map.setCenter(77.9456, 12.94, 8); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment