# GEE LULC Toolkit

An end-to-end land-use / land-cover (LULC) classification workflow for
QGIS, powered by Google Earth Engine. Load satellite composites, compute
spectral indices, create and label sample points, run supervised or
unsupervised classification, assess accuracy, and build a print-ready map -
all inside QGIS.

## Requirements

- QGIS 3.22 or newer
- The `earthengine-api` Python package in the QGIS Python environment
  (OSGeo4W Shell: `pip install earthengine-api`)
- A Google Cloud project registered for Earth Engine

## The six tools

1. **Load GEE data & indices** - build a Sentinel-1/2 or Landsat composite
   for an AOI, add spectral indices, load a local multiband GeoTIFF.
2. **Create sample points** - Cochran sample size, stratified sampling by
   ESA WorldCover, proportional/equal allocation (Olofsson 2014).
3. **Label sample points** - class buttons, a 4-view synchronized labeling
   window, and GCP shapefile support.
4. **Classify & accuracy** - supervised (RF/GBT/CART/SVM) or unsupervised
   (K-Means and other clustering) with cluster reclassification;
   confusion matrix, kappa, and area-adjusted accuracy with 95% CIs.
5. **Signatures & separability** - mean spectral signatures and the
   Jeffries-Matusita separability matrix, with a live interactive plot.
6. **Map Layout** - a print-ready map with two locator insets, legend, and
   accuracy line.

## Quick start

1. Install from ZIP (Plugins ▸ Manage and Install ▸ Install from ZIP).
2. `pip install earthengine-api` in the OSGeo4W Shell, restart QGIS.
3. Set your GEE project ID in the plugin's settings, then authenticate.
4. Run the tools 1 → 6 in order.

## First-time Earth Engine setup

Run `earthengine authenticate` once in the OSGeo4W Shell, or let the plugin
prompt you on first use. You need a Cloud project with the Earth Engine API
enabled.

## Bundled data

The plugin bundles Cambodia administrative boundaries (NCDD) and map
assets so the AOI selection and map layout work offline. These live in
`data/` and `assets/`.

## Help

Each tool has a **?** button that opens a help panel describing its
options and workflow.

## License

GPL-2.0-or-later. See LICENSE.

## Author

YAM Sarath
