Colleagues from ESA are reportedly claiming that the cloud masks from the new version v2.10 of Sen2cor are « as good as those of MAJA, if not better ». Well, let’s check. MAJA is the Level2A processor we designed within CESBIO and CNES, to process time series of images such as those of Sentinel-2, LANDSAT, VENµS, TRISHNA, LSTM… It is developed by CS GROUP. Sen2Cor is the corresponding tool funded by ESA, and developed by Telespazio and DLR.
As far as I know, the main improvement of Sen2cor v10 cloud masks is the use of a new method, already implemented within MAJA in 2008 for VENµS, and more recently within FMask. This method uses the differences in observation direction between some of the bands of Sentinel-2. The ortho-rectification process uses the digital elevation model and the viewing direction to determine the location of each pixel. As a cloud is above the earth surface, the apparent location of a high cloud after ortho-rectification will be different according to the band observation direction. But the difference in angle between the spectral bands is very small. The base height ratio on Sentinel-2 is about 0.02. This means that the positions of cloud at an altitude of 100 m will differ by only 2 m, or 0.1 pixel at 20m resolution, which is very hard to measure. I don’t know what threshold is used by Sen2cor, but more or less, the detectivity will be limited to clouds which are at least 500 m above the land surface. As a result, the new v2.10 version of Sen2cor might not have improved much on low layers of clouds.
Let’s check on it ! Jerome Colin quickly searched for some examples … and Bingo !
On the images displayed below, we use the same process to outline the detections in the newest versions Sen2cor (left) and MAJA (right), on the same images. The detected clouds are circled in green, the shadows in yellow, water in blue and snow in pink. By clicking on the images, you can see them at a better resolution.
|Sen2cor v2.10||MAJA v4|
|Tile 22KGA India||2022-03-30|
This image is an easy case, with sharp cumulus clouds. It shows the real improvement brought by sen2cor v2.10. The clouds are well detected and false detection due to bright pixels, which were quite frequent with the previous versions have almost disappeared.
I think I still spotted several unjustified green spots, along with missed cloud edges or small clouds in the zoom provided to the right, but it’s still better than before. However, you might have noticed that the limits of clouds are thicker on Sen2cor, because of the absence of dilation, while the contours of MAJA are much simpler.
Here is the same comparison, using juxtaposed images and a slider. MAJA is on the right, Sen2Cor is on the left.
|Sen2cor v2.10||MAJA v4|
|Tile 31UFU Netherlands||2022-03-30|
This image contains high clouds in the North, and low clouds in the South and West along the shore. You can see that the extent of high clouds is greater on Sen2cor, and lower for MAJA. We think that the pixels flagged by sen2cor and not by MAJA correspond to clouds thin enough to be accurately corrected by the atmospheric correction, and for this reason they do not need to be masked. However, it is easy to change the high cloud threshold within MAJA to change this classification. Regarding the low clouds along the shore, the detection by Sen2cor misses a large amount of clouds, which are perfectly detected by MAJA.
Good observer may also have noted that in the North East of the image, the cirrus clouds have mostly disappeared from MAJA image. This is due to our implementation of the DLR algorithm to correct for cirrus clouds. However, as the result is not always perfect, we keep the pixels flagged as clouds.
Here is again a juxtaposition of both images, with the slider to swap between them.
|Sen2cor v2.10||MAJA v4|
|Tile 30TYN France/Spain||2022-01-30|
On this last example, the low clouds in the North of the images are almost not detected in Sen2cor, while MAJA detects them perfectly again. The snow is also better detected in MAJA, but that’s another subject. So « almost as good » ? Not really, but still improved, which is a good news for the users of ESA’s level2A products. However, users who need a high quality of results can also use the results of MAJA, using one of the three options below :
- using the products delivered by THEIA on specific zones (on more than 1000 tiles).
- using the on-demand processing facility at the PEPS collaborative ground segment
- using MAJA on your own linux computer, but maybe not on a laptop (MAJA is a fully open source software)
MAJA has its own limitations, that occur in places where the presence of clouds is almost constant, such as Guyana and Gabon. MAJA is a multi-temporal method that needs to see the earth surface from time to time, which is very difficult in these countries.