Python library for accessing and working with Tessera geospatial foundation model embeddings.
GeoTessera provides access to geospatial embeddings from the Tessera foundation model, which processes Sentinel-1 and Sentinel-2 satellite imagery to generate 128-channel representation maps at 10m resolution. These embeddings compress a full year of temporal-spectral features into dense representations optimized for downstream geospatial analysis tasks. Read more details about the model.
This repo provides precomputed embeddings for multiple years and regions. Embeddings are generated by randomly sampling tiles within each region to ensure broad spatial coverage.
If some years (2017–2024) / areas are still missing for your use case, please submit an Embedding Request:
- 👉 Open an Embedding Request
- Please include: your organization, intended use, ROI as a bounding box with four points (lon,lat, 4 decimals), and the year(s).
After you submit the request, we will prioritize your ROI and notify you via a comment in the issue once the embeddings are ready.
On 20th August 2025, we updated the data processing pipeline of GeoTessera to resolve the issue of tiling artifacts, as shown below. We have retained the embeddings generated before August 20, as they remain effective for use in small-scale areas. After the 2024 embedding generation is completed, we will reprocess the tiles affected by tiling artifacts. If you observe such artifacts during use and they significantly impact performance, please raise the issue here, and we will prioritize reprocessing your request.
Please note that if the artifacts you observe are slanted, this is not a bug in the pipeline but rather a result of the Sentinel-1/2 satellite trajectories. Currently, Tessera cannot completely eliminate such artifacts, as they reflect the inherent characteristics of the raw data. However, we have observed that they have minimal impact on downstream tasks.
- Installation
- Architecture
- Quick Start
- Python API
- CLI Reference
- Complete Workflows
- Registry System
- Data Organization
- Contributing
pip install geotesseraFor development:
git clone https://github.com/ucam-eo/geotessera
cd geotessera
pip install -e .GeoTessera is built around a simple two-step workflow:
- Retrieve embeddings: Fetch raw numpy arrays for a geographic bounding box
- Export to desired format: Save as raw numpy arrays or convert to georeferenced GeoTIFF files
The Tessera embeddings use a 0.1-degree grid system:
- Tile size: Each tile covers 0.1° × 0.1° (approximately 11km × 11km at the equator)
- Tile naming: Tiles are named by their center coordinates (e.g.,
grid_0.15_52.05) - Tile bounds: A tile at center (lon, lat) covers:
- Longitude: [lon - 0.05°, lon + 0.05°]
- Latitude: [lat - 0.05°, lat + 0.05°]
- Resolution: 10m per pixel (variable number of pixels per tile depending on latitude)
When you request embeddings, GeoTessera downloads files directly via HTTP to temporary locations:
-
Quantized embeddings (
grid_X.XX_Y.YY.npy):- Shape:
(height, width, 128) - Data type: int8 (quantized for storage efficiency)
- Contains the compressed embedding values
- Shape:
-
Scale files (
grid_X.XX_Y.YY_scales.npy):- Shape:
(height, width)or(height, width, 128) - Data type: float32
- Contains scale factors for dequantization
- Shape:
-
Dequantization:
final_embedding = quantized_embedding * scales -
Temporary Storage: Files are downloaded to temp locations and automatically cleaned up after processing
When exporting to GeoTIFF, additional landmask files are fetched:
- Landmask tiles (
grid_X.XX_Y.YY.tiff):- Provide UTM projection information
- Define precise geospatial transforms
- Contain land/water masks
- Also downloaded to temp locations and cleaned up after use
User Request (lat/lon bbox)
↓
Parquet Registry Lookup (find available tiles from registry.parquet)
↓
Direct HTTP Downloads to Temp Files
├── embedding.npy (quantized) → temp file
└── embedding_scales.npy → temp file
↓
Dequantization (multiply arrays)
↓
Automatic Cleanup (delete temp files)
↓
Output Format
├── NumPy arrays → Direct analysis
└── GeoTIFF → GIS integration
Storage Note: Only the Parquet registry (~few MB) is cached locally. All embedding data is downloaded on-demand to temporary files and immediately cleaned up, resulting in zero persistent storage overhead for tile data.
Before downloading, check what data is available:
# Generate a coverage map showing all available tiles
geotessera coverage --output coverage_map.png
# Generate a coverage map for the UK
geotessera coverage --country uk
# View coverage for a specific year
geotessera coverage --year 2024 --output coverage_2024.png
# Customize the visualization
geotessera coverage --year 2024 --tile-color blue --tile-alpha 0.3 --dpi 150Download embeddings as either numpy arrays or GeoTIFF files:
# Download as GeoTIFF (default, with georeferencing)
geotessera download \
--bbox "-0.2,51.4,0.1,51.6" \
--year 2024 \
--output ./london_tiffs
# Download as raw numpy arrays (with metadata JSON)
geotessera download \
--bbox "-0.2,51.4,0.1,51.6" \
--format npy \
--year 2024 \
--output ./london_arrays
# Download using a GeoJSON/Shapefile region
geotessera download \
--region-file cambridge.geojson \
--format tiff \
--year 2024 \
--output ./cambridge_tiles
# Download specific bands only
geotessera download \
--bbox "-0.2,51.4,0.1,51.6" \
--bands "0,1,2" \
--year 2024 \
--output ./london_rgbGenerate web maps from downloaded GeoTIFFs:
# Create an interactive web map
geotessera visualize \
./london_tiffs \
--type web \
--output ./london_web
# Create an RGB mosaic
geotessera visualize \
./london_tiffs \
--type rgb \
--bands "30,60,90" \
--output ./london_rgb
# Serve the web map locally
geotessera serve ./london_web --openThe library provides two main methods for retrieving embeddings:
from geotessera import GeoTessera
# Initialize the client
gt = GeoTessera()
# Method 1: Fetch a single tile
embedding, crs, transform = gt.fetch_embedding(lon=0.15, lat=52.05, year=2024)
print(f"Shape: {embedding.shape}") # e.g., (1200, 1200, 128)
print(f"CRS: {crs}") # Coordinate reference system from landmask
# Method 2: Fetch all tiles in a bounding box
bbox = (-0.2, 51.4, 0.1, 51.6) # (min_lon, min_lat, max_lon, max_lat)
tiles_to_fetch = gt.registry.load_blocks_for_region(bounds=bbox, year=2024)
embeddings = gt.fetch_embeddings(tiles_to_fetch)
for year, tile_lon, tile_lat, embedding_array, crs, transform in embeddings:
print(f"Tile ({tile_lat}, {tile_lon}): {embedding_array.shape}")# Export embeddings for a region as individual GeoTIFF files
# Step 1: Get the tiles for the region
bbox = (-0.2, 51.4, 0.1, 51.6)
tiles_to_fetch = gt.registry.load_blocks_for_region(bounds=bbox, year=2024)
# Step 2: Export those tiles as GeoTIFFs
files = gt.export_embedding_geotiffs(
tiles_to_fetch=tiles_to_fetch,
output_dir="./output",
bands=None, # Export all 128 bands (default)
compress="lzw" # Compression method
)
print(f"Created {len(files)} GeoTIFF files")
# Export specific bands only (e.g., first 3 for RGB visualization)
files = gt.export_embedding_geotiffs(
tiles_to_fetch=tiles_to_fetch,
output_dir="./rgb_output",
bands=[0, 1, 2] # Only export first 3 bands
)# Fetch and process embeddings directly
tiles_to_fetch = gt.registry.load_blocks_for_region(bounds=bbox, year=2024)
embeddings = gt.fetch_embeddings(tiles_to_fetch)
for year, tile_lon, tile_lat, embedding, crs, transform in embeddings:
# Compute statistics
mean_values = np.mean(embedding, axis=(0, 1)) # Mean per channel
std_values = np.std(embedding, axis=(0, 1)) # Std per channel
# Extract specific pixels
center_pixel = embedding[embedding.shape[0]//2, embedding.shape[1]//2, :]
# Apply custom processing
processed = your_analysis_function(embedding)from geotessera.visualization import (
create_rgb_mosaic,
visualize_global_coverage
)
from geotessera.web import (
create_coverage_summary_map,
geotiff_to_web_tiles
)
# Create an RGB mosaic from multiple GeoTIFF files
create_rgb_mosaic(
geotiff_paths=["tile1.tif", "tile2.tif"],
output_path="mosaic.tif",
bands=(0, 1, 2) # RGB bands
)
# Generate web tiles for interactive maps
geotiff_to_web_tiles(
geotiff_path="mosaic.tif",
output_dir="./web_tiles",
zoom_levels=(8, 15)
)
# Create a global coverage visualization
visualize_global_coverage(
tessera_client=gt,
output_path="global_coverage.png",
year=2024, # Or None for all years
width_pixels=2000,
tile_color="red",
tile_alpha=0.6
)Download embeddings for a region in your preferred format:
geotessera download [OPTIONS]
Options:
-o, --output PATH Output directory [required]
--bbox TEXT Bounding box: 'lon,lat' (single tile) or 'min_lon,min_lat,max_lon,max_lat'
--tile TEXT Single tile by any point within it: 'lon,lat'
--region-file PATH GeoJSON/Shapefile to define region
--country TEXT Country name (e.g., 'United Kingdom', 'UK', 'GB')
-f, --format TEXT Output format: 'tiff' or 'npy' (default: tiff)
--year INT Year of embeddings (default: 2024)
--bands TEXT Comma-separated band indices (default: all 128)
--compress TEXT Compression for TIFF format (default: lzw)
--list-files List all created files with details
-v, --verbose Verbose outputSingle tile examples:
# Download a single tile containing a specific point
geotessera download --tile "0.17,52.23" --year 2024 -o ./single_tile
# Same result using --bbox with 2 coordinates
geotessera download --bbox "0.17,52.23" --year 2024 -o ./single_tileOutput formats:
- tiff: Georeferenced GeoTIFF files with UTM projection
- npy: Raw numpy arrays with metadata.json file
Create visualizations from GeoTIFF files:
geotessera visualize INPUT_PATH [OPTIONS]
Options:
-o, --output PATH Output directory [required]
--type TEXT Visualization type: rgb, web, coverage
--bands TEXT Comma-separated band indices for RGB
--normalize Normalize bands
--min-zoom INT Min zoom for web tiles (default: 8)
--max-zoom INT Max zoom for web tiles (default: 15)
--force Force regeneration of tilesGenerate a world map showing data availability:
geotessera coverage [OPTIONS]
Options:
-o, --output PATH Output PNG file (default: tessera_coverage.png)
--year INT Specific year to visualize
--bbox TEXT Bounding box: 'lon,lat' (single tile) or 'min_lon,min_lat,max_lon,max_lat'
--tile TEXT Single tile by any point within it: 'lon,lat'
--region-file PATH GeoJSON/Shapefile to focus on specific region
--country TEXT Country name to focus on (e.g., 'United Kingdom')
--tile-color TEXT Color for tiles (default: red)
--tile-alpha FLOAT Transparency 0-1 (default: 0.6)
--tile-size FLOAT Size multiplier (default: 1.0)
--width INT Output image width in pixels (default: 2000)
--no-countries Don't show country boundariesServe web visualizations locally:
geotessera serve DIRECTORY [OPTIONS]
Options:
-p, --port INT Port number (default: 8000)
--open/--no-open Auto-open browser (default: open)
--html TEXT Specific HTML file to serveDisplay information about GeoTIFF files or the library:
geotessera info [OPTIONS]
Options:
--geotiffs PATH Analyze GeoTIFF files/directory
--dataset-version TEXT Tessera dataset version
-v, --verbose Verbose outputGeoTessera uses a Parquet-based registry system to efficiently manage and access the large Tessera dataset:
- Single Parquet file: All tile metadata stored in one efficient
registry.parquetfile - Fast queries: Uses pandas DataFrames for efficient spatial and temporal filtering
- Block-based organization: Internal 5×5 degree geographic blocks for efficient queries
- Minimal storage: Registry file is ~few MB and cached locally
- Integrity checking: SHA256 checksums ensure data integrity during downloads
- Embedding files verified using
hashcolumn - Scales files verified using
scales_hashcolumn - Landmask files verified using landmasks registry
hashcolumn - Enabled by default for data integrity and security
- Can be disabled with
verify_hashes=False,--skip-hashCLI flag, orGEOTESSERA_SKIP_HASH=1environment variable
- Embedding files verified using
The registry can be loaded from multiple sources (in priority order):
- Local file (via
--registry-pathorregistry_pathparameter) - Local directory (via
--registry-dirorregistry_dirparameter, looks forregistry.parquet) - Remote URL (via
--registry-urlorregistry_urlparameter) - Default remote (from
https://dl2.geotessera.org/{version}/registry.parquet)
# Use local registry file
gt = GeoTessera(registry_path="/path/to/registry.parquet")
# Use local registry directory
gt = GeoTessera(registry_dir="/path/to/registry-dir")
# Use custom remote registry
gt = GeoTessera(registry_url="https://example.com/registry.parquet")
# Use default remote registry (downloads and caches automatically)
gt = GeoTessera() # Default behaviorThe Parquet registry contains columns for:
- Coordinates:
lon,lat(tile center coordinates) - Year:
year(data year, 2017-2024) - Hash:
sha256(file integrity checksum) - Paths: File paths for embeddings, scales, and landmasks
- Block info: Internal 5×5 degree block identifiers for efficient queries
# Example registry query
import pandas as pd
registry = pd.read_parquet("registry.parquet")
print(registry.head())
# lon lat year sha256 ...
# 0.15 52.05 2024 abc123...- Load Parquet registry → Download and cache registry file (if not local)
- Request tiles for bbox → Query DataFrame for tiles in region
- Filter by year → Select tiles matching requested year
- Find available tiles → Return list of matching tiles
- Direct HTTP download → Fetch tiles on-demand to temp files with hash verification
- Automatic cleanup → Delete temp files after processing
Remote Server (https://dl2.geotessera.org)
├── v1/ # Dataset version
│ ├── registry.parquet # Parquet registry with all metadata
│ ├── 2024/ # Year
│ │ ├── grid_0.15_52.05/ # Tile (named by center coords)
│ │ │ ├── grid_0.15_52.05.npy # Quantized embeddings
│ │ │ └── grid_0.15_52.05_scales.npy # Scale factors
│ │ └── ...
│ └── landmasks/
│ ├── grid_0.15_52.05.tiff # Landmask with projection info
│ └── ...
~/.cache/geotessera/ # Default cache location
└── registry.parquet # Cached Parquet registry (~few MB)
# Note: Embedding and landmask tiles are NOT cached persistently.
# They are downloaded to temporary files and immediately cleaned up after use.
- Embeddings: Stored in simple arrays, referenced by center coordinates
- GeoTIFF exports: Use UTM projection from corresponding landmask tiles
- Web visualizations: Reprojected to Web Mercator (EPSG:3857)
GeoTessera caches only the Parquet registry file (~few MB). Embedding and landmask tiles are downloaded to temporary files and immediately cleaned up after use.
from geotessera import GeoTessera
# Use custom cache directory for registry
gt = GeoTessera(cache_dir="/path/to/cache")
# Use default cache location (recommended)
gt = GeoTessera()# Specify custom cache directory
geotessera download --cache-dir /path/to/cache ...
# Use default cache location
geotessera download ...When cache_dir is not specified, the registry is cached in platform-appropriate locations:
- Linux/macOS:
$XDG_CACHE_HOME/geotesseraor~/.cache/geotessera - Windows:
%LOCALAPPDATA%/geotessera
GeoTessera verifies SHA256 checksums for all downloaded files (embeddings, scales, and landmasks) by default to ensure data integrity. You can disable this verification if needed:
from geotessera import GeoTessera
# Disable hash verification via parameter
gt = GeoTessera(verify_hashes=False)
# Or use environment variable
import os
os.environ['GEOTESSERA_SKIP_HASH'] = '1'
gt = GeoTessera()# Disable hash verification with flag
geotessera download --bbox "0,52,0.2,52.2" --year 2024 -o ./data --skip-hash
# Or use environment variable
GEOTESSERA_SKIP_HASH=1 geotessera download --bbox "0,52,0.2,52.2" --year 2024 -o ./dataNote: Hash verification is enabled by default for security. Only disable it in trusted environments or for testing purposes.
Contributions are welcome! Please see our Contributing Guide for details. This project is licensed under the MIT License - see the LICENSE file for details.
If you use Tessera in your research, please cite the arXiv paper:
@misc{feng2025tesseratemporalembeddingssurface,
title={TESSERA: Temporal Embeddings of Surface Spectra for Earth Representation and Analysis},
author={Zhengpeng Feng and Clement Atzberger and Sadiq Jaffer and Jovana Knezevic and Silja Sormunen and Robin Young and Madeline C Lisaius and Markus Immitzer and David A. Coomes and Anil Madhavapeddy and Andrew Blake and Srinivasan Keshav},
year={2025},
eprint={2506.20380},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/2506.20380},
}
