Dataset Viewer
The dataset viewer is not available for this dataset.
Unexpected token '<', "<html> <h"... is not valid JSON

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

S2-100K Preprocessed

Derived from torchgeo/s2-100k.

What changed

The original dataset stores patches as uint16 GeoTIFF files inside plain tar archives with no compression. This version converts every patch to a blosc2/zstd-compressed float32 array for faster I/O in training pipelines.

No season selection is performed. Each patch in the source dataset is a single Sentinel-2 L2A acquisition (no temporal dimension), so every patch is included as-is.

Source statistics

Property Value
Total patches 100,000
Shards 100 (1,000 patches each)
Spatial size 256 × 256 px (resampled to 10 m/px)
Spectral bands 12 (B01–B09, B11, B12; no B10)
DN scale L2A reflectance × 10000 (uint16 in source)

Band order (index 0–11): B01, B02, B03, B04, B05, B06, B07, B08, B08A, B09, B11, B12

Format

WebDataset .tar shards under train/. Each sample contains two files:

File Description
{patch_id}.bands.b2 blosc2/zstd-compressed [12, 256, 256] float32 array
{patch_id}.meta.json {"lon":…,"lat":…,"fn":…,"shard":…,"patch_idx":…}

patch_id format: s2100k_{shard:05d}_{patch_idx:05d}

patch_idx is the shard-local 0-based index (0–999), matching the patch_idx column in the source metadata.parquet. e.g. s2100k_00003_00042 = shard 3, the 43rd patch in that shard (0-indexed).

Loading a sample

import blosc2, numpy as np, json, tarfile

N_CHANNELS, H, W = 12, 256, 256

with tarfile.open('s2100k_preprocessed_shard_00000.tar') as tf:
    members = {m.name: m for m in tf.getmembers()}
    patch_id = 's2100k_00000_00000'
    raw  = blosc2.decompress(tf.extractfile(members[f'{patch_id}.bands.b2']).read())
    arr  = np.frombuffer(raw, dtype=np.float32).reshape(N_CHANNELS, H, W)
    meta = json.loads(tf.extractfile(members[f'{patch_id}.meta.json']).read())
    print(arr.shape, arr.dtype, meta)
Downloads last month
136