DryForM is a Google Earth Engine (GEE) workflow for dry-forest and tree-cover mapping, model training, post-processing, disturbance analysis, and interactive time-series exploration.
The repository contains the script pipeline developed in the DryForM exploratory work (2022–2024), organized as numbered modules that can be run step-by-step in GEE.
This project is a scripted workflow (mostly JavaScript for GEE Code Editor) covering:
- creation of a sampling framework from multiple land-cover sources,
- ground-truth preparation and balancing,
- Sentinel-1/Sentinel-2 preprocessing,
- Random Forest training and inference,
- AlphaEarth embedding-based training experiments,
- optional object-based segmentation,
- post-processing and area summaries,
- disturbance detection with CCDC,
- an app-like time-series explorer.
All major modules are under DryForM_Workflow/ and are prefixed with step numbers to indicate execution order.
.
├── .gitignore
├── README.md
└── DryForM_Workflow/
├── 1_SamplingFramework/
│ ├── 1_0_LCProc_v3_2
│ └── 1_1_Export2Drive_Optional
├── 2_Samples/
│ ├── 2_0_AutoSampling
│ ├── 2_1_GroundTruth_Visu
│ ├── 2_2_BalanceGT
│ └── 2_3_Separability
├── 3_Preprocessing/
│ ├── 3_0_PrepS1S2_v9_(working_Allinone)
│ └── s1_code/
│ ├── wrapper
│ ├── s1_ard
│ ├── utilities
│ ├── speckle_filter
│ ├── terrain_flattening
│ └── border_noise_correction
├── 4_Segmentation/
│ └── 4_0_SNIC_Segmentation_ObjectOriented
├── 5_Training_Inference/
│ ├── 5_1_HyperparameterTunning
│ ├── 5_2_Training_withAutoSample
│ ├── 5_2_Training_withGroundTruth
│ ├── 5_3_ApplySavedModel_Optional
│ ├── 5_Training_Inference_5_2_Training_wtihGroundTruth_Embeds
│ └── 5_Training_Inference_5_2_Training_wtihGroundTruth_Embeds_BenchmarkMode
├── 6_Postprocessing/
│ └── 6_0_PostProc_v1
├── 7_Disturbance/
│ ├── 7_0_CCDC_InspectPixels_v3
│ ├── 7_1_CCDC_CreateAutomated_v3
│ ├── 7_2_CCDC_Extract_NonAutomated_v3
│ └── req/
├── 8_Utils/
│ ├── 8_0_Visualize_ClassificationResults
│ ├── 8_1_recurrent_IC_removal
│ └── 8_2_CalculateAreas
└── 9_App/
├── Time Series Explorer with images_df_vd_b2v10
└── req/
Note: scripts are stored without
.jsextensions, but are intended for Google Earth Engine JavaScript workflows.
1_0_LCProc_v3_2builds a preliminary LC reference layer from multiple global products and AOIs.1_1_Export2Drive_Optionaloptionally exports that layer to Google Drive.
2_0_AutoSamplinggenerates auto-sampled points from step 1 outputs.2_1_GroundTruth_Visuloads/visualizes manually interpreted ground truth.2_2_BalanceGTbalances class distributions for training/validation.2_3_Separabilitycomputes separability metrics (e.g., Jeffries–Matusita).
3_0_PrepS1S2_v9_(working_Allinone)prepares multi-temporal Sentinel-1/Sentinel-2 composites and exports tiled assets.- Uses helper modules in
3_Preprocessing/s1_code/for Sentinel-1 ARD processing.
4_0_SNIC_Segmentation_ObjectOrientedruns SNIC segmentation for object-oriented workflows.
5_1_HyperparameterTunningtunes Random Forest parameters.5_2_Training_withGroundTruthruns supervised RF training with visual GT.5_2_Training_withAutoSamplealternative training with auto-sampled GT.5_3_ApplySavedModel_Optionalapplies previously exported model assets.- AlphaEarth/Satellite-Embeddings scripts currently present in this repository root of step 5:
5_Training_Inference_5_2_Training_wtihGroundTruth_Embeds5_Training_Inference_5_2_Training_wtihGroundTruth_Embeds_BenchmarkMode
6_0_PostProc_v1mitigates no-data artifacts in classification outputs.
7_1_CCDC_CreateAutomated_v3creates CCDC outputs.7_2_CCDC_Extract_NonAutomated_v3extracts disturbance-relevant bands.7_0_CCDC_InspectPixels_v3interactive per-pixel inspection.- Uses reusable helper module under
7_Disturbance/req/.
8_0_Visualize_ClassificationResultsfor visual QA/QC.8_1_recurrent_IC_removalfor recurrent deletion of images in image collections.8_2_CalculateAreascalculates Forest / Non-forest area totals by zone (World_UNctry_grid) using pixel-area summaries and exports table results to Drive.
Time Series Explorer with images_df_vd_b2v10integrates classification, imagery chips, temporal profiles, and disturbance layers.- Uses helper modules under
9_App/req/.
These files implement the Sentinel-1 ARD chain used by step 3:
wrapper: orchestrates the S1 preprocessing workflow and calls the other helper modules.s1_ard: core ARD routine and parameter-driven S1 preprocessing logic.utilities: shared math/conversion functions (e.g., dB-linear conversions).speckle_filter: mono/multi-temporal speckle filtering implementations.terrain_flattening: slope/radiometric terrain correction functions.border_noise_correction: additional Sentinel-1 border noise masking.
The currently tracked repository structure contains two embedding-oriented scripts in 5_Training_Inference/.
If additional files now exist in another branch/path (for example an AlphaEarth/ subfolder or *_Embeds_v3.js variants), they are not present in this checked-out tree and should be added/committed so they can be documented here precisely.
Both 7_Disturbance/req/ and 9_App/req/ contain reusable helper modules required by the main scripts in those directories.
Includes .DS_Store ignore rule for macOS metadata files.
- A Google Earth Engine account with permission to run and export tasks.
- Access to required GEE assets referenced in scripts (AOIs, GT, intermediate outputs).
- (Optional) OEEex plugin or task management strategy for large export batches.
- Open Google Earth Engine Code Editor.
- Copy a script from this repository into a new GEE script.
- Update parameters in each script (AOI, year, asset paths, class fields, export paths).
- Run modules in numbered order (1 → 9), using optional modules as needed.
- Validate outputs after each stage before proceeding.
Because many scripts reference private/project assets, adaptation to your own GEE assets is expected.
The workflow is configured around multiple AOIs (e.g., Chaco, Caatinga, Cerrado, Tanzania/Tanganyika in different script versions) and supports reclassified LC targets for model training.
Class schemas and remapping arrays are defined directly in training scripts; adjust them consistently across balancing, training, validation, and visualization modules.
Depending on the executed path and options, outputs may include:
- LC proxy/sampling framework layers,
- training and validation sample assets,
- quarterly (or alternative interval) S1/S2 composites,
- trained classifier assets and classified rasters,
- post-processed classification maps,
- CCDC disturbance layers,
- area-estimation tables,
- summary tables and visualization layers.
- This repo captures working research scripts; variable names, comments, and assumptions are tuned to DryForM processing context.
- Some modules are explicitly marked as optional or experimental.
- Several scripts note known limitations (e.g., Sentinel-1 overlap artifacts, non-automated extraction steps) and ongoing optimization ideas.
- Some helper modules were adapted from external community/academic code and are integrated here for workflow reproducibility.
Contributions are welcome for:
- documentation improvements,
- script refactoring and parameterization,
- reproducibility improvements (config-driven assets/AOI setup),
- automation of currently manual steps.
When submitting changes, please keep the numbered workflow logic intact and document any breaking changes in step dependencies.