Predict the Fire Weather Index (FWI) for Algerian forests using meteorological data and a Ridge Regression ML model, deployed with Flask and ready for AWS Elastic Beanstalk.
# 🔥 Algerian Forest Fire FWI Prediction (End-to-End ML Deployment)
An end-to-end Machine Learning project that predicts the **Fire Weather Index (FWI)** using meteorological data from the Algerian Forest Fires dataset.
This project covers:
* Data preprocessing
* Feature scaling
* Model training (Ridge Regression)
* Model serialization
* Flask web application
* Production deployment (AWS Elastic Beanstalk ready)
## 📊 Dataset
**Source:**
Algerian Forest Fires Dataset (Updated CSV)
kaggle.com
### Dataset Description
The dataset contains meteorological data from two regions of Algeria:
* Bejaia Region
* Sidi-Bel Abbes Region
### Features Used
* Temperature
* RH (Relative Humidity)
* WS (Wind Speed)
* Rain
* FFMC
* DMC
* ISI
* Classes
* Region
Target Variable:
* FWI (Fire Weather Index)
## 🧠 Project Workflow
### 1️⃣ Data Preprocessing
* Cleaning missing values
* Encoding categorical features
* Feature scaling using StandardScaler
### 2️⃣ Model Training
* Algorithm used: **Ridge Regression**
* Model trained on scaled data
* Performance evaluated using regression metrics
### 3️⃣ Model Serialization
* Model saved using `pickle`
* Scaler saved separately
* Loaded inside Flask application
### 4️⃣ Web Application
* Built using Flask
* Accepts user input via HTML form
* Scales input
* Returns predicted FWI value
### 5️⃣ Deployment Ready
* Configured for AWS Elastic Beanstalk
* WSGI path configured
* Gunicorn included for production server
## 🚀 Project Structure
```
algerian-forest-fire-fwi-predictor/
│
├── application.py # Flask app entry point
├── requirements.txt # All Python dependencies
├── models/ # Saved ML models and scaler
│ ├── ridge.pkl
│ └── scaler.pkl
├── templates/ # HTML templates for Flask
│ ├── index.html
│ └── home.html
├── notebooks/ # Jupyter notebooks for EDA & training
│ └── fwi_model_tr …