Skip to content

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔥 Algerian Forest Fire Risk Analyzer

A Machine Learning web application built with Flask that predicts the Fire Weather Index (FWI) using meteorological conditions from two Algerian regions.

This project demonstrates an end-to-end Machine Learning workflow including data preprocessing, model training, model serialization, and deployment-ready web development.


🌐 Live Demo

Try the application here:

https://algerian-forest-fire-risk-analyzer.onrender.com


📌 Project Overview

The application predicts the Fire Weather Index (FWI) from weather measurements collected in:

  • 📍 Bejaia
  • 📍 Sidi-Bel Abbes

Users enter meteorological information through a simple web interface and the trained Linear Regression model predicts the expected Fire Weather Index.

The application also categorizes the predicted fire danger into different risk levels and provides a recommendation.


🚀 Features

  • Predict Fire Weather Index (FWI)
  • Supports two Algerian regions
  • Linear Regression model
  • StandardScaler preprocessing
  • Flask backend
  • Bootstrap-based frontend
  • Risk level classification
  • Fire safety recommendation

📊 Input Features

The model uses the following features:

  • Temperature
  • Relative Humidity (RH)
  • Wind Speed (Ws)
  • Rain
  • Fine Fuel Moisture Code (FFMC)
  • Duff Moisture Code (DMC)
  • Drought Code (DC)
  • Initial Spread Index (ISI)
  • Region

🎯 Target Variable

  • Fire Weather Index (FWI)

🧠 Machine Learning Workflow

  1. Data Cleaning
  2. Exploratory Data Analysis (EDA)
  3. Correlation Analysis
  4. Feature Selection
  5. Train-Test Split
  6. Feature Scaling using StandardScaler
  7. Linear Regression Model Training
  8. Model Evaluation
  9. Model Serialization using Pickle
  10. Flask Deployment

🛠 Technologies Used

  • Python
  • Flask
  • Scikit-Learn
  • Pandas
  • NumPy
  • HTML
  • Bootstrap
  • Pickle

📁 Project Structure

Algerian-Forest-Fire-Risk-Analyzer/

│

├── application.py

├── requirements.txt

├── README.md

├── .gitignore

│

├── models/

│ ├── linear_regression_model.pkl

│ └── standard_scaler.pkl

│

├── notebooks/

│ ├── ALGERIAN_LR.ipynb

│ └── Algerian_forest_fire_cleaned.csv

│

└── templates/

├── home.html

└── index.html

⚙️ Installation

Clone the repository

git clone https://github.com/YOUR_USERNAME/Algerian-Forest-Fire-Risk-Analyzer.git

Move into the project directory

cd Algerian-Forest-Fire-Risk-Analyzer

Create a virtual environment

python -m venv .venv

Activate the environment

Windows

.venv\Scripts\activate

Install dependencies

pip install -r requirements.txt

Run the application

python application.py

The application will be available at

http://127.0.0.1:5000

📈 Model

Algorithm:

Linear Regression

Preprocessing:

StandardScaler

Framework:

Flask


📷 Screenshots

(Add screenshots after deployment)

  • Home Page
  • Prediction Form
  • Prediction Result

👨‍💻 Author

Pratham Singh

Machine Learning | Artificial Intelligence | Python Developer


📄 License

This project is intended for educational and portfolio purposes.

About

A Flask web application that predicts the Fire Weather Index (FWI) using Linear Regression and meteorological data from the Algerian Forest Fires dataset.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages