Metadata-Version: 2.4
Name: satchange
Version: 0.1.2
Summary: Multipurpose satellite change detection (deforestation, mining, urbanisation, floods, burns, water, urban growth) via Google Earth Engine or Microsoft Planetary Computer.
Project-URL: Homepage, https://github.com/firmanhadi21/rs-change-detection
Project-URL: Documentation, https://firmanhadi21.github.io/rs-change-detection/
Project-URL: Repository, https://github.com/firmanhadi21/rs-change-detection
Author-email: Firman Hadi <firmanhadi21@lecturer.undip.ac.id>
Maintainer-email: Firman Hadi <firmanhadi21@lecturer.undip.ac.id>
License: MIT
License-File: LICENSE
Keywords: change-detection,deforestation,earth-engine,flood,geospatial,gis,landsat,ndbi,ndvi,planetary-computer,remote-sensing,sentinel
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Scientific/Engineering :: GIS
Classifier: Topic :: Scientific/Engineering :: Image Recognition
Requires-Python: >=3.11
Requires-Dist: requests
Provides-Extra: all
Requires-Dist: contextily; extra == 'all'
Requires-Dist: earthengine-api; extra == 'all'
Requires-Dist: matplotlib; extra == 'all'
Requires-Dist: numpy; extra == 'all'
Requires-Dist: odc-stac; extra == 'all'
Requires-Dist: planetary-computer; extra == 'all'
Requires-Dist: pystac-client; extra == 'all'
Requires-Dist: rasterio; extra == 'all'
Requires-Dist: rioxarray; extra == 'all'
Provides-Extra: gee
Requires-Dist: earthengine-api; extra == 'gee'
Provides-Extra: maps
Requires-Dist: contextily; extra == 'maps'
Requires-Dist: matplotlib; extra == 'maps'
Requires-Dist: numpy; extra == 'maps'
Requires-Dist: rasterio; extra == 'maps'
Provides-Extra: mpc
Requires-Dist: numpy; extra == 'mpc'
Requires-Dist: odc-stac; extra == 'mpc'
Requires-Dist: planetary-computer; extra == 'mpc'
Requires-Dist: pystac-client; extra == 'mpc'
Requires-Dist: rasterio; extra == 'mpc'
Requires-Dist: rioxarray; extra == 'mpc'
Description-Content-Type: text/markdown

# satchange

**Multipurpose satellite change detection in pure Python.** Map deforestation,
mining, urbanisation, floods, burns, surface-water change and multi-epoch urban
growth anywhere on Earth from free Sentinel-1/2 and Landsat data — via **Google
Earth Engine** or **Microsoft Planetary Computer** (no account needed). Export
georeferenced GeoTIFFs, quick-look PNGs, statistics, and print-ready A4 maps.

- 📖 **Full hands-on tutorial (English & Bahasa Indonesia):** <https://firmanhadi21.github.io/rs-change-detection/>
- 💻 **Source, examples & case study:** <https://github.com/firmanhadi21/rs-change-detection>

## Install

Heavy dependencies are optional *extras*, so the install stays lean:

```bash
pip install 'satchange[gee]'       # Google Earth Engine backend (free account)
pip install 'satchange[mpc,maps]'  # Planetary Computer + maps (no account)
pip install 'satchange[all]'       # everything
```

## Quick start

```bash
# Deforestation around a coordinate, with a finished map
satchange -s deforestation --lat -3.333 --lon 122.25 --radius 6 --map

# Flood extent from Sentinel-1 SAR — no Earth Engine account needed
satchange -s flood --lat 27.2 --lon 68.3 \
    --pre 2022-07-01:2022-07-25 --post 2022-08-20:2022-09-10 --backend mpc

# Urban growth timing across 2010/2015/2020 (Landsat 5/8/9)
satchange -s urban-trend --lat -6.30 --lon 107.15 --map

# List everything
satchange --list
```

Each run writes a self-contained `output/<run-id>/` folder containing the PNG,
GeoTIFF, statistics JSON, metadata, and any maps.

## Scenarios

| Scenario | Method | Sensor |
|----------|--------|--------|
| `deforestation` | NDVI loss | Sentinel-2 |
| `urbanization` | Built-up gain — `NDBI` (default), `UI`, `BU`, `IBI`, or thermal `NDISI`/`EBBI` via `--method` | Sentinel-2 / Landsat |
| `water` | NDWI change | Sentinel-2 |
| `burn` | dNBR severity | Sentinel-2 |
| `mining` | SIRAD radar temporal + NDVI loss | Sentinel-1 + S2 |
| `flood` | SAR water extent (event vs baseline) | Sentinel-1 |
| `urban-trend` | NDBI at 3 epochs → RGB growth-timing map | Landsat 5/8/9 |

## Two backends

| `--backend` | Data source | Account? |
|-------------|-------------|----------|
| `gee` (default) | Google Earth Engine | free account + `earthengine authenticate` |
| `mpc` | Microsoft Planetary Computer (STAC) | **none** — streams COGs, processes locally |

Optical scenarios build cloud-masked median composites; radar scenarios
auto-select the Sentinel-1 orbit with coverage. The AOI is a square centred on
your coordinate. Landsat 7 is skipped (SLC-off gaps).

## Make maps from a finished run

```bash
satmap output/<run-id>            # render A4 map sheets offline (no GEE)
```

Map sheets include an OpenStreetMap basemap, the change layer, legend, a
statistics panel, a location inset, coordinate grid, scale bar and north arrow.

## License

MIT © Firman Hadi. Data: Copernicus Sentinel (ESA) and Landsat (USGS/NASA),
via Google Earth Engine or Microsoft Planetary Computer.
