Changes in band data after 25 Jan 2022 | Baseline 04.00 harmonizeValues | Sentinel 2 L2A | Snappy

Kind regards to all,

Using L2A products, after the update 04.00 (Copernicus Sentinel-2: Major Products Upgrade Upcoming - Copernicus Sentinel-2: Major Products Upgrade Upcoming - Sentinel Online) there is a change in the data as stated in the entry:

Provision of negative radiometric values (implementing an offset): Similarly to Level-1C, the dynamic range will be shifted by a band-dependent constant, i.e. BOA_ADD_OFFSET. From the user’s point of view, the L2A Bottom of Atmosphere (BOA) reflectance (L2A_BOA) shall be retrieved from the output radiometry as follows:

  • Digital Number DN=0 remains the “NO_DATA” value
  • For a given DN in [1;2^(15)-1], the L2A BOA reflectance value will be: L2A_BOAi = (L2A_DNi + BOA_ADD_OFFSETi) / QUANTIFICATION_VALUEi

Due to this change, after 25 January of 2022, it can be seen that when extracting the values of the bands using snappy in the same way as before, these values are approximately 0.1 higher.
I attach an interpolated graph of the B2 band for the year 2021 and 2022

B2 Band 2021_2022

product = ProductIO.readProduct(file)
band = product.getBand("B2") 

After checking the forum, we see that this problem may be solved by a parameter called “harmonizeValues”.

The problem we are currently facing is how to get this “pre-corrected” data from each of the bands through snappy. How to introduce this parameter before the getBand, so that the values are given to us in the same way as before.

In the event that it would be resolved with harmonizeValues, we have seen that, for example, to introduce a resolution change parameter would be to add the targetResolution parameter to 60 and do a Resample operation.

HashMap = jpy.get_type('java.util.HashMap')  
parameters = HashMap()
result = GPF.createProduct('Resample', parameters, product)

For the harmonizeValues parameter, what kind of operation or process should be done or if there is anything else to take into account?

Thanks to all

@GSiesto! I have the same problem.

I hope someone here can help us.


1 Like

I found the solution in SNAP. To do this, you need to do the following:
Tools > Options > S2TBX >Sentinel-2 Reader > Check Add Negative Radius Offset
Is a SNAP configuration but, for Snappy, I can’t find a solution. I hope someone can help us

1 Like

Once this setting is set it should be applied to the data in Python too if you are using snappy for reading the data.
If you read the plain jp2 files you need to do the scaling your self.

1 Like

Thank you very much for the answers, I followed the procedure and found it to be effective. Following the steps would be :

  • Update SNAP to the latest version (at least version 8)
  • Change the software configuration as indicated by @acaballegn
    Tools > Options > S2TBX >Sentinel-2 Reader > Check Add Negative Radius Offset
  • Read through Snappy the original sentinel image.

Note: In case of opening an image that is not the original one, for example an image that has been previously processed by a previous version of SNAP (less than 8), such as a clipped image, calculated indicators, etc., it would not work, and you would have to do the same processing to the original image with the new version of SNAP).