The Udacity Disaster Response Pipeline project is a web application that analyzes and classifies messages related to disasters. The goal of this project is to help emergency responders quickly identify the most relevant messages during a disaster, enabling faster response and assistance.
The project consists of the following components:
- Loads the data from
messages
andcategories
datasets - Processes and cleans the data
- Stores the clean data in a SQLite database
- ETL pipeline code can be found in data/process_data.py
- Loads data from the SQLite database
- Trains a multi-output classification model.
- Saves the final model as a pickle file
- The model is used to categorise messages into different disaster-related categories.
- Machine Learning pipeline code can be found in models/train_classifier.py
- The Flask web app offers a user-friendly interface to input a message, which is then classified into relevant categories using the trained model.
- Users can also explore visualizations of the dataset.
- Python Version: Python 3.11
- Machine Learning Libraries:
- NumPy
- SciPy
- Pandas
- Scikit-Learn
- Natural Language Processing Libraries:
- NLTK (Natural Language Toolkit)
- SQLite Database Libraries:
- SQLAlchemy
- Model Loading and Saving Library:
- Pickle
- Web Application and Data Visualization Libraries:
- Flask
- Plotly
To clone the git repository:
git clone https://github.com/sadiaTab/Disaster_Response_Pipeline.git
To run the project, follow these steps:
-
Run the ETL pipeline to clean and store the processed data in the database:
python data/process_data.py data/messages.csv data/categories.csv data/DisasterResponse.db
-
Run the Machine Learning pipeline, which involves loading data from a database, training a classifier, and saving the classifier as a pickle file:
python models/train_classifier.py data/DisasterResponse.db models/classifier.pkl
-
Run the following command in the app directory:
python run.py
- Go to
http://127.0.0.1:3000/
to use the web application.
- This is the app frontpage showing training data distribution and word cloud.
- This is the result page showing the classification of new message into different disaster-related categories by the machine learning model.
This app was created as part of the Udacity Data Scientist Nanodegree program. The original dataset used in this project was initially curated by Udacity in partnership with Figure Eight (Appen).