GithubHelp home page GithubHelp logo

ashishrana1501 / forest-fire-prediction Goto Github PK

View Code? Open in Web Editor NEW
12.0 2.0 6.0 4.11 MB

Algerian Forest Fire Prediction

Jupyter Notebook 93.89% Procfile 0.01% Python 0.16% CSS 4.72% JavaScript 0.04% SCSS 0.86% HTML 0.33%
feature-engineering feature-selection flask hyperparameter-tuning linear-regression logistic-regression machine-learning modeling random-forest-classifier random-forest-regression randomizedsearchcv xgboost-classifier xgboost-regression data-science deployment jupyter-notebook python sklearn

forest-fire-prediction's Introduction

Forest Fire Prediction

Heroku App (https://forestfire-predictions.herokuapp.com)

frontend

Demonstration

Classification

Forestfire.Prediction.mp4

Regression

ForestFire.Regression.mp4

A brief description of what this project is all about.

Forest Fire Prediction is a Supervised Machine learning problem statements. Using Regression and Classification Algorithm, Regression and Classification Model is build that detected future fires based on certain Weather report.

A framework is created using Flask and deployed on Heroku

Library Used in this Project

Data Pre-Processing

  • Numpy, Pandas, Matplotlib, Seaborn

Model Building

  • Sklearn, statsmodels

Hyperparameter Tuning

  • RandomizedSearchCV, GridSearchCV

Introduction

Algerian Forest Fires

Data set Available at: link text

Data Set Information:

  • The dataset includes 244 instances that regroup a data of two regions of Algeria,namely the

  • Bejaia region located in the northeast of Algeria and the Sidi Bel-abbes region located in the northwest of Algeria.

  • 122 instances for each region.

  • The period from June 2012 to September 2012.

  • The dataset includes 11 attribues and 1 output attribue (class)

  • The 244 instances have been classified into fire (138 classes) and not fire (106 classes) classes.

Attribute Information:

1. Date : (DD/MM/YYYY) Day, month ('june' to 'september'), year (2012)

Weather data observations

2. Temp : temperature noon (temperature max) in Celsius degrees: 22 to 42

3. RH : Relative Humidity in %: 21 to 90

4. Ws : Wind speed in km/h: 6 to 29

5. Rain: total day in mm: 0 to 16.8

FWI Components

6. Fine Fuel Moisture Code (FFMC) index from the FWI system: 28.6 to 92.5

7. Duff Moisture Code (DMC) index from the FWI system: 1.1 to 65.9

8. Drought Code (DC) index from the FWI system: 7 to 220.4

9. Initial Spread Index (ISI) index from the FWI system: 0 to 18.5

10. Buildup Index (BUI) index from the FWI system: 1.1 to 68

11. Fire Weather Index (FWI) Index: 0 to 31.1

12. Classes: two classes, namely Fire and not Fire

Steps

  1. Data Collection
  2. Data Pre-Processing
  3. Exploratory Data Analysis
  4. Feature Engineering
  5. Feature Selection
  6. Model Building
  7. Model Selection
  8. Hyperparameter Tuning
  9. Flask framework
  10. Model deployment

Model Building

Regression

  • For regression analysis FWI(Fire weather Index) considered as dependent feature because it highly correlated with classes variable with more than 90% correlation.

Model Used:

  1. Linear regression
  2. Lasso Regression
  3. Ridge Regression
  4. Decision tree
  5. Random forest
  6. K-Nearest Neighbour regressor
  7. Support Vector Regressor

Classification

  • For Classification Classes is dependent feature which is a Binary Classification(fire, not fire)

Model Used:

  1. Logistic Regression
  2. Decision Tree
  3. Random Forest
  4. K-Nearest Neighbour
  5. XGboost.

Model Selection

HyperParameter Tuning performed using RandomizedsearchCV for the model which performed best for both Regression and Classification.

  • For Regression r2_score metrics is used to select best model.

  • For Classification Stratified Kfold Cross-Validation metrics is used.

  • The best Mean CV Accuracy Model is used for Model Deployment.

Model Deployment

Flask

  • framework is created using Flask.

Heroku

  • Model deployed on Heroku.

๐Ÿ”— Links

portfolio linkedin

forest-fire-prediction's People

Contributors

ashishrana1501 avatar rafbot-v7 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

forest-fire-prediction's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.