Skip to main content

Sentinel Hub's cloud detector for Sentinel-2 imagery

Project description

Package version Conda version Supported Python versions Build Status Overall downloads Last month downloads Code coverage

Sentinel Hub's cloud detector for Sentinel-2 imagery

NOTE: s2cloudless masks are now available as a precomputed layer within Sentinel Hub. Check the announcement blog post and technical documentation.

The s2cloudless Python package provides automated cloud detection in Sentinel-2 imagery. The classification is based on a single-scene pixel-based cloud detector developed by Sentinel Hub's research team and is described in more detail in this blog.

The s2cloudless algorithm was part of an international collaborative effort aimed at intercomparing cloud detection algorithms. The s2cloudless algorithm was validated together with 9 other algorithms on 4 different test datasets and in all cases found to be on the Pareto front. See the paper

Installation

The package requires a Python version >= 3.7. The package is available on the PyPI package manager and can be installed with

$ pip install s2cloudless

To install the package manually, clone the repository and

$ pip install .

One of s2cloudless dependencies is lightgbm package. If having problems during installation, please check the LightGBM installation guide.

Before installing s2cloudless on Windows, it is recommended to install package shapely from Unofficial Windows wheels repository

Input: Sentinel-2 scenes

The inputs to the cloud detector are Sentinel-2 images. In particular, the cloud detector requires the following 10 Sentinel-2 band reflectances: B01, B02, B04, B05, B08, B8A, B09, B10, B11, B12, which are obtained from raw reflectance values in the following way: B_i/10000. From product baseline 04.00 onward additional harmonization factors have to be applied to data according to instructions from ESA.

You don't need to worry about any of this, if you are using Sentinel-2 data obtained from Sentinel Hub Process API. By default, the data is already harmonized according to documentation. The API is supported in Python with sentinelhub-py package and used within s2cloudless.CloudMaskRequest class.

Examples

A Jupyter notebook on how to use the cloud detector to produce cloud mask or cloud probability map can be found in the examples folder.

License

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

s2cloudless-1.6.2.tar.gz (4.8 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

s2cloudless-1.6.2-py3-none-any.whl (4.8 MB view details)

Uploaded Python 3

File details

Details for the file s2cloudless-1.6.2.tar.gz.

File metadata

  • Download URL: s2cloudless-1.6.2.tar.gz
  • Upload date:
  • Size: 4.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.10

File hashes

Hashes for s2cloudless-1.6.2.tar.gz
Algorithm Hash digest
SHA256 6bc3b76c9917c2b07f5457b17a119b915e505f41feb92e0c28931f2c8cb9d7e7
MD5 3340d22c61e47b4aeee4474e7865a1fc
BLAKE2b-256 de1a2f967bb01907b63c15b668ed7499fae0adc9b9c58cb2066548b003fdd0a2

See more details on using hashes here.

File details

Details for the file s2cloudless-1.6.2-py3-none-any.whl.

File metadata

  • Download URL: s2cloudless-1.6.2-py3-none-any.whl
  • Upload date:
  • Size: 4.8 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.10

File hashes

Hashes for s2cloudless-1.6.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6124bd8147c3022cae731a748e4f3eff924368605366d4d4d58ca90894d06ad4
MD5 0abd9a5fb5ddde3c34c0ea7cf2794f76
BLAKE2b-256 436255522fff75e7db4fb7edb1ffabd625456a08d8a911eb3fe97e0b0f365a8e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page