Zerua Tech Logo

Cloud Detection in Satellite Images with Deep Learning

Date: Monday, Jan 26th 2026, 00:35
Share on
Share on Twitter
Share on Facebook
Share on LinkedIn
A satellite above a layer of clouds, with cyan outlines along the cloud edges and glowing data panels around it
More than two thirds of the Earth is under cloud on average, according to the International Satellite Cloud Climatology Project figure quoted by Wang and colleagues (2024), so a large share of optical satellite images shows cloud instead of ground. A cloud mask labels each pixel as usable or not, and the quality of that label matters. Baetens and colleagues (2019) plotted Sentinel-2 reflectances over a meadow in central France: the series was noisy before cloud screening and much smoother after it, and at that low-aerosol site, screening clouds improved the smoothness more than atmospheric correction did. Optical imaging depends on getting this mask right, one of the steps in the post on satellite data preprocessing.

Why clouds are hard to mask

Baetens and colleagues describe three difficulties. Bright ground such as sand, snow or city roofs is easily taken for cloud. Thin clouds are semi-transparent, so a pixel mixes cloud and land. Cloud shadows are as dark as water, burnt ground or mountain shadows, and shadows under thin clouds are harder still. The Landsat and Sentinel-2 archives are far too large for masks drawn by hand, so the masking has to be automatic.

Masks built from rules

The operational masks are rule-based. Fmask for Landsat and Sen2Cor for Sentinel-2 apply thresholds to spectral bands, using properties of clouds such as whiteness, flatness and temperature (López-Puigdollers and colleagues, 2021). MAJA, used by the French space agency, also compares an image with earlier ones of the same place. Baetens and colleagues tested the three on 32 Sentinel-2 scenes from 10 sites, from equatorial forest to desert. With all masks dilated in the same way, the overall accuracy was 90.8% for MAJA, 89.8% for Fmask and 84% for Sen2Cor, with a wide spread between scenes. The time-series mask had only a small lead over a well-tuned single-image one.

Who judges the masks

Accuracy needs a reference, and a reference needs people. Baetens and colleagues built a tool where an operator labels a few pixels, a classifier fills in the rest, and the operator corrects it in rounds, so a complete reference mask for one scene took less than two hours. The CloudSEN12 dataset (Aybar and colleagues, 2022) went further: 14 experts labeled Sentinel-2 patches, 10,000 of them pixel by pixel and 10,000 with scribbles. In a timed sample, pixel-level labels took on average 150 minutes per patch, against 16 minutes for scribbles. The authors also note that there is no agreed rule for where a thin cloud ends and a thick one begins, so the labels depend partly on the interpreter.

A small network for the mask

Deep learning treats the mask as segmentation: the network receives the bands of an image and returns a cloud label for every pixel. Wang and colleagues sort the models into four families, fully convolutional networks, encoder-decoder networks, attention models and generative adversarial networks, and note that none needs hand-set thresholds. López-Puigdollers and colleagues chose a deliberately small network in the U-Net style, with about 96,000 trainable parameters, roughly 1% of the 7.8 million of the original U-Net. They trained it on 96 Landsat-8 scenes from eight biomes, and trained ten copies to report the spread of the results, not only the best run.
A satellite view of a cloudy coastline with a glowing neural network above it and a cyan line along the cloud edge

The benchmark

The main finding is that the result depends on the dataset. On held-out scenes of the same dataset, the network reached 93.16 to 94.35% overall accuracy, depending on the bands used, against 89.59% for Fmask, a figure the paper takes from an earlier study. On a second dataset the two were close, 92.69 to 93.57% against 92.47%, again an earlier result for Fmask. On a third, Fmask scored 96.66% and the network 90.36 to 91.39%, which the authors trace to labels that were built from Fmask output in the first place. Methods tend to do best on the dataset used to tune them, and the authors call for standard datasets and procedures.

To a new satellite without new labels

Labeled Sentinel-2 scenes are scarce, so the authors trained only on Landsat-8, resampled the Sentinel-2 bands to 30 m and tested on labeled Sentinel-2 scenes. The transferred models scored 89.79 to 89.81% overall accuracy, against 90.64% for Fmask, 88.55% for Sen2Cor and 93.51% for s2cloudless, a model trained on Sentinel-2 itself. Thin clouds are nearly half of the cloud labels, and leaving them out raised the score of every method. In one example scene the version that also used shortwave infrared bands avoided an error that Sen2Cor and Fmask made, calling snow on mountains cloud.
A nanosatellite sorting image tiles in orbit, with bright clear tiles streaming toward Earth and dark cloudy tiles falling away

Deciding on board

A nanosatellite has little downlink bandwidth, so sending cloudy images wastes it. CloudScout (Giuffrida and colleagues, 2020) is a network built to run on the satellite itself, on the HyperScout-2 payload of the European Space Agency's PhiSat-1 mission, and to keep only images with less than 70% cloud. It had to fit in 5 MB and reach at least 85% accuracy with at most 1.2% false positives, meaning good images thrown away. Trained on Sentinel-2 data processed to look like the HyperScout-2 sensor, it reached 92% accuracy with 1% false positives and 6.8% false negatives, in 2.1 MB, 325 ms per image and 1.8 W on a Myriad 2 chip. On a hard set of 24 images with snow, ice, fog and cloud close to the 70% mark, accuracy was 67%. The paper was written before launch, so these are results on simulated data, not from orbit. The post on AI in space covers the wider limits of computing on board.

What is still open

Wang and colleagues name four open problems: lightweight models fast enough for real time use on satellites, a model that works across sensors, large finely labeled datasets, and less dependence on manual labels. López-Puigdollers and colleagues add that datasets disagree most on thin clouds and cloud edges, so a score is only comparable between studies that use the same labels. The CloudScout authors point out that a yes or no answer discards a whole image, and suggest a segmentation network on board as future work.
A cloud mask is only as good as the labels it is judged against. The step the papers point to is a model small enough to run before downlink that marks pixels, instead of discarding whole images.
References

Recent Posts

Machine Learning for Ship Detection in Satellite Images
Oct 25th 2026
Radar sees ships through cloud and night. Correcting labels lifted optical ship recognition from 0.66-0.70 to about 0.80 mAP, more than a newer model did.
Why Ships Go Missing from Satellite AIS
Aug 14th 2026
Satellite AIS loses ships to message collisions, late data and gaps between passes. Six studies show how much is missed and how analysts work around it.
Orbit Propagation: Which Perturbations Matter
Jun 4th 2026
Across 320 propagator setups, gravity fields beyond 32 by 32 added no accuracy, while drag, the Sun and Moon, and sunlight pressure matter in different orbits.