CoolFace
Modelpublic

glody007/zamba-deforestation-detector

sourceHugging Faceotherupdated 5mo agoView on Hugging Face
0likes21downloads
Model Card

zamba-deforestation-detector — LFM2.5-VL-450M (GGUF)

Fine-tuned from LiquidAI/LFM2.5-VL-450M on simulated Sentinel-2 RGB+SWIR change-detection pairs over the Congo Basin (DRC), to flag near-real-time forest clearing on a 90-day window. Companion to the `zamba-sat` repo, built for the AI in Space hackathon (DPhi Space × Liquid AI).

Given four images per sample — RGB(t-1), SWIR(t-1), RGB(t-0), SWIR(t-0) — and a small text block (lat/lon, dates, region name), the model emits a chain-of-thought followed by a JSON change-detection record:

json
{
  "deforestation_detected": true,
  "change_pattern": "expansion",     // expansion | stable | cloud_artifact
  "trajectory_confidence": "medium", // low | medium | high
  "severity": "medium",              // none | low | medium | high
  "clearing_type": "small_holder",
  "area_bucket_t1": "1-5_ha",
  "area_bucket_t0": "0-1_ha",
  "active_operation": false,
  "active_machinery_visible": false,
  "smoke_or_fire_visible": false,
  "recent_road_construction": false,
  "frame_quality": ["good"]
}

The full XML chain-of-thought wraps the JSON with <frame_descriptions>, <change_analysis>, <final_pattern>, and <json> blocks — see the `zamba-sat` README for the schema.

Eval results

Evaluated on the held-out subset of the `glody007/zamba-sat-congo-deforestation` dataset (90-day window, wide_window + wide_window_v2 runs). Ground truth from claude-opus-4-7.

fieldLFM2.5-VL-450M (base, Q8_0)LFM2.5-VL-450M Q8_0 (fine-tuned, this model)
valid_json0%67%
changepattern (expansion / stable / cloudartifact)0%50%
trajectory_confidence0%67%
composite (13 fields)0.0%38.5%

Held-out test set is small (N=6) — the headline movement is the base model emitting placeholder prose vs the fine-tune emitting schema-compliant JSON with correct expansion/stable discrimination. The base-model 0% is on the dir-test (N=36); see zamba-sat/evals/EXPERIMENTS.md for the full experiment log including v1 (cloud-class collapse) and v3 (overfitting boundary).

Files

Running inference with a VLM in llama.cpp requires two GGUF files:

filedescription
zamba-deforestation-v2-Q8_0.ggufLanguage model backbone (Q8_0)
mmproj-zamba-deforestation-v2-Q8_0.ggufVision tower + multimodal projector (F16)

Usage

llama-server

bash
llama-server \
    -m zamba-deforestation-v2-Q8_0.gguf \
    --mmproj mmproj-zamba-deforestation-v2-Q8_0.gguf \
    --jinja --port 8000

Reproduce eval results

Clone `zamba-sat` and run:

bash
git clone https://github.com/glody007/zamba-sat
cd zamba-sat
uv sync

# (1) Re-prep the dataset locally — same stratified split used for training.
uv run scripts/prepare_finetune.py \
    --runs wide_window wide_window_v2 \
    --output data/finetune \
    --skip-clouds

# (2) Eval the fine-tune behind llama-server (started in another shell with
# the GGUFs from this repo).
uv run scripts/evaluate.py --backend local \
    --server-url http://localhost:8000 \
    --model zamba-deforestation-Q8_0 \
    --runs wide_window wide_window_v2 --split test \
    --splits-file data/finetune/splits.json

Training details

  • Base: LiquidAI/LFM2.5-VL-450M
  • Method: full SFT (no LoRA), via leap-finetune on Modal H100×1
  • Data: 24 stratified train rows after --skip-clouds (17 expansion + 7 stable); held-out test = 6 rows (4 expansion + 2 stable)
  • Hyperparameters: 5 effective epochs / 12 grad steps, effective batch size 8 (2 × 4 grad accum), LR 2e-5, cosine, warmup 0.03, seed 42

This is the v2 checkpoint, which on internal evals beat both v1 (cloud-class collapse from training without --skip-clouds) and v3 (overfit at 8 ep / ~25 grad steps). v2 is the apparent sweet spot given the dataset size; the next step before further training is to collect more stable labels.