eemont
eemont copied to clipboard
.preprocess() failed for the new COPERNICUS/S2_SR_HARMONIZED
Hi,
GEE recently recommended switching to COPERNICUS/S2_HARMONIZED and COPERNICUS/S2_SR_HARMONIZED.
I am not sure if the .preprocess() supports COPERNICUS/S2_SR_HARMONIZED natively, but I ran into errors running .preprocess() on the S2_SR_HARMONIZED image collection
Thanks, Daniel
Hi @Daniel-Trung-Nguyen, I just bumped onto the same issue. What I figured out so far is that the issue is coming from the underlying method .maskClouds() of the .preprocess() method.
Code below raises the same error than you showed except if one removes .maskClouds()
s2_prep_detailed = ee.ImageCollection('COPERNICUS/S2_SR_HARMONIZED') \ .filterDate('2022-08-01', '2022-08-31') \ .filterBounds(ee.Geometry.Point([-74.0592,11.3172])) \ .scaleAndOffset() .maskClouds()
I though it was due to missing masks in some products (https://developers.google.com/earth-engine/datasets/catalog/COPERNICUS_S2_SR_HARMONIZED#bands), but this is also the case in the COPERNICUS/S2_SR products.
@davemlz, any idea where it could bug? Any advice also on applying the .scaleAndOffset() method on S2_SR_HARMONIZED dataset for which some range values have been shifted by 1000?
Thanks, Adrien
any updates? I'm also experiencing this exact issue, would love to get some help
Same issue here. My code using scaleAndOffset() and masClouds() works great for COPERNICUS/S2_SR but throws the error shown above when switching to COPERNICUS/S2_SR_HARMONIZED.
Having the same issue.
The issue lies with ee_extra
. I've created a pull request to fix this issue.