timm/bigearthnet-v2-rgb
BigEarthNet v2.0 (reBEN) - Sentinel-2 RGB Description BigEarthNet v2.0 (reBEN, "refined BigEarthNet"), a multi-label land-cover classification dataset of Sentinel-2 image patches from 10 European countries. Each 1200 m x 1200 m patch (120x120 pixels at 10 m) is labelled with one or more of 19 land-cover classes. The labels come from the CORINE Land Cover 2018 map, using the 19-class BigEarthNet nomenclature. This variant is RGB-only, stored as JPEG (quality 98… See the full description on the dataset page: https://huggingface.co/datasets/timm/bigearthnet-v2-rgb.
BigEarthNet v2.0 (reBEN) - Sentinel-2 RGB
Description
BigEarthNet v2.0 (reBEN, "refined BigEarthNet"), a multi-label land-cover classification dataset of Sentinel-2 image patches from 10 European countries. Each 1200 m x 1200 m patch (120x120 pixels at 10 m) is labelled with one or more of 19 land-cover classes. The labels come from the CORINE Land Cover 2018 map, using the 19-class BigEarthNet nomenclature.
This variant is RGB-only, stored as JPEG (quality 98, 4:4:4 chroma, ~40 dB+ PSNR vs. the tone-mapped values). See timm/bigearthnet-v2-rgb-nir-swir for lossless PNG RGB plus raw NIR / SWIR bands.
This is a derived version of the Sentinel-2 part of the official release. It contains only the 480,038 patches in metadata.parquet; the 69,450 patches flagged for seasonal snow or cloud / shadow are excluded, as in the standard benchmark. It uses the official train / validation / test splits (237,871 / 122,342 / 119,825). reBEN assigns these geographically to reduce spatial correlation between splits, so do not re-split randomly.
- Website: https://bigearth.net
- Source data: https://zenodo.org/records/10891137 (BigEarthNet-S2.tar.zst, metadata.parquet)
- Paper: https://arxiv.org/abs/2407.03653
Labels
Every patch has at least one label (mean 2.95). Class indices follow the short snake_case names in alphabetical order. The original names are in the table:
RGB tone mapping
The source bands are 16-bit L2A surface reflectance (reflectance x 10000). RGB (B04, B03, B02) is converted to 8-bit with one fixed, global tone curve. Nothing is adjusted per image, so brightness stays radiometrically consistent across patches:
x = DN / 3500- highlight shoulder: identity for
x <= 0.6(DN <= 2100, ~98% of pixels). Above that, an extended-Reinhard roll-off (slope-continuous at the knee) reaches 1.0 at DN 12000. Snow, cloud and bright surfaces are compressed instead of clipped. - gamma:
y = x ** (1 / 2.2),v = round(255 * y)
This follows the same idea as Sentinel Hub's "L2A True Color Optimized" rendering: display gamma plus highlight compression. It is not the linear, clipped ESA TCI product. On clean patches, 0% of pixels clip at 255. Mean / std of the tone-mapped RGB over train (0-1 scale): mean [0.3956, 0.4205, 0.3508], std [0.174, 0.141, 0.1355].
To map values back to approximate reflectance DN (exact up to 8-bit quantization of the forward curve):
import numpy as np
def inverse_tone_map(v):
"""8-bit tone-mapped value(s) -> approximate L2A reflectance DN (reflectance * 10000)."""
scale, white, knee, gamma = 3500., 12000., 0.6, 2.2
x = (np.asarray(v, dtype=np.float64) / 255) ** gamma # undo gamma
tw = (white / scale - knee) / (1 - knee)
s = np.clip((x - knee) / (1 - knee), 0, None) # undo extended-Reinhard shoulder above the knee
a = 1 / tw ** 2
t = (-(1 - s) + np.sqrt((1 - s) ** 2 + 4 * a * s)) / (2 * a)
x = np.where(x <= knee, x, knee + (1 - knee) * t)
return x * scaleDataset Structure
image- RGB (B04, B03, B02), 120x120 (10 m), tone-mapped to 8-bit (see below), JPEG q98 4:4:4.labels- sequence ofClassLabelindices of the positive classes.label_names- short names of the positive classes.image_id- reBENpatch_id, e.g.S2A_MSIL2A_20170613T101031_N9999_R022_T33UUP_26_57.country- country of the patch.tile,acquisition_time,satellite,relative_orbit,patch_row,patch_col- parsed fromimage_id(Sentinel-2 tile, sensing time (UTC), S2A / S2B, relative orbit, patch position in the tile grid).epsg,utm_x,utm_y- projection (UTM zone EPSG code) and top-left corner of the patch in metres, from the source GeoTIFF.lat,lon- WGS84 coordinates of the patch centre.s1_name- the paired Sentinel-1 patch in reBEN (BigEarthNet-S1).s2v1_name- the corresponding BigEarthNet v1.0 patch name.
Usage
This dataset follows the same multi-label format as timm/plant-pathology-2021 for use with timm 1.0.31 or greater:
python train.py --dataset hfds/timm/bigearthnet-v2-rgb --train-split train --val-split validation \
--task multilabel --target-key labels --num-classes 19 \
--model resnet50.ram_in1k --pretrained --img-size 128 --batch-size 256 --epochs 30 \
--opt adamw --lr 1e-3 --weight-decay 0.05 --ampThe usual metrics are mAP (macro / micro average precision) and F1.
License
The source data is released under the Community Data License Agreement - Permissive, Version 1.0 (CDLA-Permissive-1.0). It contains modified Copernicus Sentinel data (2017-2018) and CORINE Land Cover 2018 data. This derived version (tone-mapped RGB, JPEG q98 (4:4:4)) is distributed under the same license.
Citation
@inproceedings{clasen2025reben,
title = {reBEN: Refined BigEarthNet Dataset for Remote Sensing Image Analysis},
author = {Clasen, Kai Norman and Hackel, Leonard and Burgert, Tom and Sumbul, Gencer and Demir, Beg{\"u}m and Markl, Volker},
booktitle = {IEEE International Geoscience and Remote Sensing Symposium (IGARSS)},
year = {2025},
note = {arXiv:2407.03653}
}