Fire days are rare
The problem
With heavily imbalanced labels, a model can look accurate by always predicting "no fire".
What I did
Computed class weights automatically and used PR-AUC as the primary metric instead of accuracy.
Case study
End-to-end ML pipeline predicting wildfire risk across Southern California WUI sites using NASA FIRMS data.
Emergency planning teams and fire risk analysts needed a data-driven, reproducible system that combines satellite fire detection, historical weather patterns, and geographic perimeter data to forecast where fire risk would escalate — without relying on manual signal interpretation.
The pipeline automates data ingestion, feature engineering (7-day lags, rolling stats, seasonality, neighbor features), chronological train/val/test splitting, class-imbalance weighting, and ANN/LSTM training — then serves predictions and PR/ROC curves through a full-stack dashboard operators can query interactively.
A complete Python machine-learning system that predicts next-day fire occurrence for 20+ Wildland-Urban Interface sites in Ventura, Santa Barbara, and LA counties. Ingests real NASA FIRMS VIIRS satellite data (75K+ records), RAWS daily weather features, and CAL FIRE FRAP historical perimeters. Trains ANN/LSTM models and surfaces predictions through a Next.js + FastAPI dashboard with interactive Leaflet maps and ApexCharts.
Makefile targets ingest NASA FIRMS VIIRS detections (75K+ records, 2019–2024), RAWS weather, and CAL FIRE FRAP perimeters. A feature step builds 7-day lags, rolling stats, seasonality, and neighbour features. Models (baselines, an ANN, and a 14-day LSTM) train behind a FastAPI service with 9 endpoints, and a Next.js dashboard shows metrics, PR/ROC curves, and per-site predictions on a Leaflet map.
The problem
With heavily imbalanced labels, a model can look accurate by always predicting "no fire".
What I did
Computed class weights automatically and used PR-AUC as the primary metric instead of accuracy.
The problem
Random splits and scalers fit on all data quietly leak the future into training.
What I did
Predicted t+1, fit the scaler on the training set only, and used a chronological 70/15/15 split.
The problem
Satellite points, station weather, and polygon perimeters do not line up on their own.
What I did
Automated the joins in a reproducible pipeline so every run rebuilds the same dataset.
Data pipeline (FIRMS + RAWS + FRAP)
NASA VIIRS ingestion, RAWS weather features, and FRAP perimeter joins are automated via Makefile.
ANN & baseline models
Logistic Regression, Random Forest, and ANN all trained and evaluated with PR-AUC as the primary metric.
LSTM with 14-day lookback
LSTM model implemented as an optional extension to the ANN baseline.
Real-time weather feed integration
Live RAWS or NWS data ingestion for continuous daily inference not yet implemented.