The version 3.2.2 of MAJA cloud detection and atmospheric correction software has just been released! It brings a lot of improvements. It can be used to process Sentinel-2 data in four different manners that will be described below :


MAJA 3.2.2 brings a lot of improvements:

  • MAJA 3.2 adapts to a bug from Sentinel-2 L1C products, which sometimes (but quite frequently) provides the detector footprints (DEFOO masks) in an incorrect order since October 2018. When this happened, MAJA crashed, but with MAJA 3.2.2, it is over.
  • MAJA 3.2 still only works for linux systems, but not anymore for only with Red Hat and CentOS, as it is now provided with the complete set of necessary libraries. It was for instance successfully tested on Ubuntu systems.
  • We have updated the water vapour LUT to cancel a bias we had for high water vapour contents. The improvement was already described in this post.
  • We have slightly changed a few parameters for a stricter cloud detection, but the cloud mask will significantly improve with MAJA V3.3.
  • If the option to use Copernicus Atmosphere Monitoring Service (CAMS) data is selected, the CAMS Aerosol Optical Thickness can be used not only to define the type of aerosol, as introduced in MAJA 3.1, but also as a default value with a low weight in the cost function. If MAJA does not find many suitable pixels to estimate the AOT, the CAMS value will have an influence, but in general, a large number of measurements are available in an image, and in that case, CAMS has no influence (except on the aerosol type, see below, V3.1). Finally, this improvement will be useful over snow covered landscapes, or bright deserts, of for images almost fully covered by clouds.

Left, without default CAMS value, right with default CAMS value, for neighbourhoods for which more than 50% of pixels can be used to estimate aerosols. In that case, use of CAMS does not really change the results.
Left, without default CAMS value, right with default CAMS value, for neighbourhoods for which less than 50% of pixels can be used to estimate aerosols. These situations correspond to a large proportion of snow or cloud covered pixels. Before version 3.2.2, these pixels were gap filled. A notable improvement is observed.

Free executable version

MAJA free executable version can be downloaded from CNES free software site. It has already been downloaded 800 times from this site. MAJA now works on any Linux workstation, with at least 8GB of RAM. We have tested it on Red Hat, Cent OS and Ubuntu. To run it and obtain all the necessary inputs and parameters, we advise to use our simple pyhon orchestrator, which handles the processing of a whole time series of images for a given tile. has been updated, it is now available on CNES github repository. The script itself has been improved. Generation of DEM file is much easier as the parameters of each tile are generated thanks to the kml file provided by ESA (a contribution from Peter Kettig). We also enabled the script to work with zipped input files if you prefer to save disk space even if it may cost processing time.

On demand processing with PEPS

As already mentioned here, you may ask PEPS, the French collaborative ground segment, to process data with MAJA for you. Thanks to MAJA 3.2.2, we have solved several of the issues we had so far because of the errors in ESA L1C format (already mentioned above).The user manual is available here, and a script to launch it via a command line interface is available on github. Here is an example of command line :

python ./  -l Toulouse -a peps.txt -d 2017-11-01 -f 2017-12-01 -p prod_list_toulouse.txt

However, the current version is still a beta version. We should have an alpha version very soon which will be much more efficient in terms of computing resources, and will be able to produce for you up to a whole year of data, for a given tile, with just one command line to start.

Operational processing in MUSCATE processing center

As Theia's MUSCATE processing center is an operational service, every new version has to go through a large number of tests. Introducing MAJA 3.2.2 in MUSCATE processing center is complex, because we had to introduce a new interface with MAJA, using CAMS data. For this, we also have to take care of the fall-back strategies in case CAMS is not available.We are currently doing the last tests in operational configuration before starting the production, and we hope to start the production very soon. And when we have controlled the real time production is OK, we will do a complete reprocessing, probably this summer; as we expect a large improvement in data quality.

MAJA processing within Sen2Agri

MAJA 3.2.2 will also be added in the next version of Sen2Agri system. Sen2Agri is a processing systems, which provides advanced tools to monitor agriculture at the scale of a country. All its products are based on Level 2A products obtained with MAJA. 


This new version is the result of a LOT of work, with the contribution of- CS-SI team, who develops the operational version of MAJA (many thanks to Aurelien Bricier and Benjamin Esquis)- CNES team, who handles that development, organises the validation and contributes to Start-MAJA processor. Many thanks to Peter Kettig and Pierre Lassalle. They were helped in 2018 by Bruno Angeniol, from Cap Gemini.- CNES image quality team (Camille Desjardins) with the help of Elsa Bourgeois from Cap Gemini, for the maintenance of the reference MAJA processor, and for validation and several improvements ncluding water vapour estimation.- CESBIO team, Bastien Rouquie and myself, for the research part, including the use of CAMS data and the cloud mask adjusments.

3 thoughts on “Release of MAJA 3.2

  1. This is fabulous! Congratulations for the accomplished work and a huge thank you for making MAJA accessible to all! and... long live time series!

Laisser un commentaire

Votre adresse de messagerie ne sera pas publiée. Les champs obligatoires sont indiqués avec *

Ce site utilise Akismet pour réduire les indésirables. En savoir plus sur comment les données de vos commentaires sont utilisées.