Skip to main content

A collection of common tools to interact with the BigEarthNet dataset.

Project description

Common BigEarthNet Tools

A personal collection of common tools to interact with the BigEarthNet dataset.

This library provides a collection of high-level tools to better work with the BigEarthNet dataset.

ben_common tries to accomplish three goals:

  1. Collect the most relevant constants into a single place to reduce the time spent looking for these, like:
    • The 19 or 43 class nomenclature strings
    • URL
    • Band statistics (mean/variance) as integer and float
    • Channel names
    • etc.
  2. Provide parsing functions to convert the metadata json files to a geopandas GeoDataFrame's.
    • Allow for easy top-level statistical analysis of the data in a familiar pandas-style
    • Provide functions to enrich GeoDataFrames with often required BigEarthNet metadata (like the season or country of the patch)
  3. Simplify the building procedure by providing a command-line interface with reproducible results

Deep Learning

One of the main purposes of the dataset is to allow deep learning researchers and practitioners to train their model on multi-spectral satellite data easily. In that regard, there is a general recommendation to drop patches that are covered by seasonal snow or clouds. Also, the novel 19-class nomenclature should be preferred over the original 43-class nomenclature. As a result of these recommendations, some patches have to be excluded from the original raw BigEarthNet dataset that is provided at BigEarthNet. This is especially important for higher-level statistical analysis.

To simplify the procedure of pre-converting the json metadata files, the library provides a single command that will generate a recommended GeoDataFrame with extra metadata (country/season data of each patch) while dropping all patches that are not recommended for deep learning research.

To generate such a GeoDataFrame and store it as an parquet file, use:

  • ben_gdf_builder build-recommended-parquet (available after installing package) or
  • python -m bigearthnet_common.gdf_builder build-recommended-parquet

If you want to read the raw json files and convert those to a GeoDataFrame file, without dropping any patches or adding any metadata, use:

  • ben_gdf_builder build-raw-ben-parquet (available after installing package) or
  • python -m bigearthnet_common.gdf_builder build-raw-ben-parquet

Local Installation

Use just to install the package or run steps from justfile directly. Requires mamba (highly recommended) or poetry to be installed.

Local Documentation

{% include note.html content='Building and serving the documentation requires Docker to be installed!' %} After creating the ben_common_env environment, run

docker-compose up

Or with just:

just docs

After running the command, the documentation server will be available at

To review the source code, please look at the corresponding ipynb notebook from the nbs folder. These notebooks include extensive documentation, visualizations, and tests. The automatically generated Python files are available in the bigearthnet_common module.

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

bigearthnet_common-0.2.0.tar.gz (20.2 kB view details)

Uploaded Source

Built Distribution

bigearthnet_common-0.2.0-py3-none-any.whl (25.0 kB view details)

Uploaded Python 3

File details

Details for the file bigearthnet_common-0.2.0.tar.gz.

File metadata

  • Download URL: bigearthnet_common-0.2.0.tar.gz
  • Upload date:
  • Size: 20.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.12 CPython/3.7.12 Linux/5.11.0-1022-azure

File hashes

Hashes for bigearthnet_common-0.2.0.tar.gz
Algorithm Hash digest
SHA256 37d209c2cc155545e4805652561f2eb07893c92fc4a2b1a411da7d07ef24716d
MD5 d9f33e5f0be4d874caa6e5720706e831
BLAKE2b-256 4042ede8a152e901a6232d5f9dfb6beb713e761edd723d5fe7bb2e8853f24a1f

See more details on using hashes here.

File details

Details for the file bigearthnet_common-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: bigearthnet_common-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 25.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.12 CPython/3.7.12 Linux/5.11.0-1022-azure

File hashes

Hashes for bigearthnet_common-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d7e5a6045f228b224d3e6a4a32aaefc23972bbfff756ae9d5fe17b748b1d8547
MD5 34bd20d632b8f96e0448346878dd7dc8
BLAKE2b-256 aa3bda16c2ae20b7bfbf16e18c9ed2550dec047528c30a8ef9bbd8712f1d9764

See more details on using hashes here.

Supported by

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