This project analyzes the Algerian Forest Fires dataset — 244 weather observations from two regions of Algeria (Bejaia in the northeast, Sidi Bel-Abbes in the northwest), collected over June–September 2012 — to predict the Fire Weather Index (FWI), a composite score used by fire-danger rating systems worldwide.
# 🔥 Algerian Forest Fire — FWI Prediction
### Regression modeling of the Fire Weather Index using regularized linear models
---
## 📌 Overview
This project analyzes the **Algerian Forest Fires dataset** — 244 weather observations from two regions of Algeria (Bejaia in the northeast, Sidi Bel-Abbes in the northwest), collected over June–September 2012 — to predict the **Fire Weather Index (FWI)**, a composite score used by fire-danger rating systems worldwide.
The work is split into two notebooks:
| Notebook | Purpose |
|---|---|
| `Algerian_Forest_Fire_Data_Analysis.ipynb` | Cleaning, wrangling, and exploratory data analysis |
| `Algerian_Forest_Model_Training.ipynb` | Feature selection, scaling, and regression modeling |
---
## 🌍 Dataset
- **244 instances** — 122 per region, merged from two raw CSV blocks
- **11 weather/FWI-system features** + 1 target class label
- Region split encoded as a binary feature (`0` = Bejaia, `1` = Sidi Bel-Abbes)
- Class balance: **138 fire** vs **106 not-fire** days
| Feature | Description | Range |
|---|---|---|
| Temperature | Noon temperature (°C) | 22 – 42 |
| RH | Relative Humidity (%) | 21 – 90 |
| Ws | Wind speed (km/h) | 6 – 29 |
| Rain | Total rainfall (mm) | 0 – 16.8 |
| FFMC | Fine Fuel Moisture Code | 28.6 – 92.5 |
| DMC | Duff Moisture Code | 1.1 – 65.9 |
| DC | Drought Code | 7 – 220.4 |
| ISI | Initial Spread Index | 0 – 18.5 |
| BUI | Buildup Index | 1.1 – 68 |
| **FWI** | **Fire Weather Index (target)** | 0 – 31.1 |
| Classes | `fire` / `not fire` | — |
---
## 🧹 Data Cleaning
- Merged the two region-specific blocks of the raw CSV and stamped a `Region` column
- Dropped a malformed header row separating the two regions, and rows with nulls
- Stripped whitespace from column names and category labels (`" fire"` → `"fire"`)
- Cast day/month/year and integer-valued weather fields to `int`, remaining FWI-system columns to `float`
- Persisted a clean, analysis-ready CSV for the modeling notebook
## 📊 Expl …