I'm using GEE for NDVI (using landsat 8) but there is many holes in my image, can someone explain me what happened? here's the code
// Function to mask clouds using the quality band of Landsat 8.
var maskL8 = function(image) {
var qa = image.select('pixel_qa');
/// Check that the cloud bit is off.
// See https://landsat.usgs.gov/collectionqualityband
var mask = qa.bitwiseAnd(1 << 5).eq(0);
return image.updateMask(mask);
};
var filter = l8.filterDate('2021-01-01','2023-12-31').map(maskL8).median().clip(table);
var ndvi = filter.normalizedDifference(['B5','B4']);
var lst = filter.select(['B10']).subtract(273);
Map.addLayer(lst)
Map.addLayer(ndvi)
Export.image.toDrive({
image: ndvi,
scale: 100,
description: 'MAXENT-NDVI',
region: table,
maxPixels: 1e12
});
pixel_qa
bits definition directly in the GEE collection information to mask exactly what you want, for example: developers.google.com/earth-engine/datasets/catalog/….pixel_qa
) I assume you are running an old code relying on Landsat Collection 1