ClimateDataFetcher (cdf) is a climate data tool with CLI, HTTP API backend, and optional Dash UI workflows.
- Release:
1.0.0 - Application type: CLI + HTTP API + optional Dash UI
- Core commands:
list-sources,describe-source,fetch,ndvi,api,ui - Config check command:
validate-config - Sources:
open_meteo,noaa_cdo,nasa_gibs,sentinel_hub,planetary_computer - Outputs: JSON, GeoJSON, CSV, PNG, GeoTIFF,
manifest.json,logs/fetch.log - Tests:
103 passed - Coverage:
87%(target>= 86%met) - Rust acceleration: enabled and verified (
RUST_AVAILABLE=True) - NOAA long-range behavior: auto-chunked date windows (default
31days per chunk) - Fetch UX: built-in progress bars (
--progress/--no-progress) - UI design: refreshed Dash theme with responsive layout and accessibility-focused styling
pip install -e ".[dev]"
cdf --help
cdf list-sources
# Optional geospatial export dependencies
pip install -e ".[geotiff]"
# Optional UI dependencies
pip install -e ".[ui]"Build smallest API image (no UI dependency):
docker-build.batBuild with Dash UI included:
docker-build.bat --uiRun API container:
docker-run-api.batRun UI container (requires image built with --ui):
docker-run-ui.batStop both containers:
docker-stop.batDisk cleanup when needed:
docker image prune -f
docker container prune -f
docker volume prune -fWindows (.bat):
setup.batinstall environment and dependencies (--with-geotiffoptional)build.batrun install + tests (--distoptional for wheel/sdist)run.batrun CLI (--backgroundoptional)stop.batstop background run started byrun.bat --backgroundrun-ui.batrun Dash UI (--backgroundoptional)stop-ui.batstop background UI rundocker-build.batbuild container image (--uioptional)docker-run-api.batrun API containerdocker-run-ui.batrun UI containerdocker-stop.batstop/remove API + UI containers
Unix/macOS (.sh):
setup.shbuild.shrun.shstop.shrun-ui.shstop-ui.shdocker-build.shdocker-run-api.shdocker-run-ui.shdocker-stop.sh
cdf list-sourcescdf describe-source <source>cdf validate-config [--source <source|all>]cdf fetch --source ... --bbox ... --since ... --until ...cdf ndvi --nir <nir.png> --red <red.png> [--format json,csv]cdf api [--host 127.0.0.1] [--port 8000]cdf ui [--host 127.0.0.1] [--port 8501] [--debug]
Start backend server:
cdf api --host 127.0.0.1 --port 8000Endpoints:
GET /healthGET /sourcesGET /sources/{name}POST /validate-configPOST /fetchPOST /ndvi
# Open-Meteo (no auth)
cdf fetch `
--source open_meteo `
--bbox "-10,35,40,70" `
--since 2024-01-01 `
--until 2024-01-03 `
--verbose `
--out .\output_open_meteo# NOAA CDO (requires NOAA_CDO_TOKEN in .env)
cdf fetch `
--source noaa_cdo `
--bbox "-87.9,41.6,-87.5,42.1" `
--since 2023-06-01 `
--until 2023-06-07 `
--out .\output_noaa# NASA GIBS imagery
cdf fetch `
--source nasa_gibs `
--bbox "-10,35,40,70" `
--since 2024-04-01 `
--until 2024-04-07 `
--format png `
--resolution high `
--out .\output_gibs# NASA GIBS imagery + GeoTIFF export
cdf fetch `
--source nasa_gibs `
--bbox "-10,35,40,70" `
--since 2024-04-01 `
--until 2024-04-07 `
--format png,geotiff `
--resolution high `
--out .\output_gibs_geotiff# Sentinel Hub imagery (requires SENTINEL_HUB_CLIENT_ID / SENTINEL_HUB_CLIENT_SECRET)
cdf fetch `
--source sentinel_hub `
--bbox "-10,35,40,70" `
--since 2024-04-01 `
--until 2024-04-07 `
--format png `
--resolution high `
--out .\output_sentinel_hub# Planetary Computer STAC metadata
cdf fetch `
--source planetary_computer `
--bbox "-10,35,40,70" `
--since 2024-04-01 `
--until 2024-04-07 `
--format json,csv,geojson `
--out .\output_planetary_computeroutput/
├── manifest.json
├── data/
│ ├── <source>_<since>_<until>.json
│ ├── <source>_<since>_<until>.geojson
│ ├── <source>_<since>_<until>.csv
│ ├── <source>_<date>.png
│ └── <source>_<date>.tif
└── logs/
└── fetch.log
Create .env from .env.example:
NOAA_CDO_TOKEN=your_token_here
# Optional v0.2 tuning
# HTTP_RETRY_ATTEMPTS=3
# HTTP_RETRY_BASE_DELAY=0.5
# HTTP_RETRY_MAX_DELAY=5.0
# NOAA_CDO_CHUNK_DAYS=31
# SENTINEL_HUB_CLIENT_ID=
# SENTINEL_HUB_CLIENT_SECRET=
# SENTINEL_HUB_CLOUD_COVERAGE=80
# PLANETARY_PC_COLLECTION=sentinel-2-l2a
# PLANETARY_PC_LIMIT=25Validate config before a run:
cdf validate-config
cdf validate-config --source noaa_cdo
cdf validate-config --source sentinel_hub --liveNDVI example (local image analysis only; no network):
cdf ndvi `
--nir .\bands\nir.png `
--red .\bands\red.png `
--format json,csv `
--out .\output_ndvipython -m pytest -q tests -p no:tmpdir -p no:cacheprovider
python -m pytest tests --cov=climatedatafetcher --cov-report=term-missing -p no:tmpdir -p no:cacheprovider
Caption: cdf --help CLI output in terminal for command discovery.
Caption: v1.0 Dash UI Fetch tab with source fallback, compact bbox/date layout, and live log panel.
Caption: v1.0 Dash UI Validate Config tab.
Caption: v1.0 Dash UI NDVI tab.
- Implementation status:
status.md - Source details:
docs/sources.md - Contributing guide:
docs/contributing.md - Architecture notes:
docs/architecture.md - Planning spec (original):
ClimateDataFetcher_Architecture.md





