gee-ccdc-tools icon indicating copy to clipboard operation
gee-ccdc-tools copied to clipboard

sensor argument in getLandsat() function does not work

Open ZZMitch opened this issue 2 years ago • 0 comments

Hello,

The sensors argument in the getLandsat() function does not properly filter by Satellite (l4, l5, l7, l8). The function will output all sensors, even if all sensors are set to false.

Looking into the source code, this error is likely because the filterMetadata command below is looking for a 'SATELLITE' property. However, at least in Collection 2, there is no 'SATELLITE' property. The correct property instead appears to be 'SPACECRAFT_ID'.

A simple change of replacing 'SATELLITE' with 'SPACECRAFT_ID' should fix this issue.

ZZMitch avatar Sep 26 '22 16:09 ZZMitch