An open API service indexing awesome lists of open source software.

https://github.com/fahadpathan7/aqi-prediction-web

This is a website that uses our custom model that we have developed for our thesis. It predicts Air Quality Indexing (AQI) for an uploaded image in real-time. It also shows lime explanation that shows the regions of image that is important to the model (mostly sky areas).
https://github.com/fahadpathan7/aqi-prediction-web

flask

Last synced: 12 months ago
JSON representation

This is a website that uses our custom model that we have developed for our thesis. It predicts Air Quality Indexing (AQI) for an uploaded image in real-time. It also shows lime explanation that shows the regions of image that is important to the model (mostly sky areas).

Awesome Lists containing this project

README

          

#

๐ŸŒ AQI Prediction ๐ŸŒค๏ธ

This is the application of our undergrad thesis. The thesis is about predicting the **Air Quality Index (AQI)** of a city using **Machine Learning**. We have used the data of the city of Dhaka, Bangladesh (open-source) to train our model. The model we have used here is our proposed custom model **(DeepAQNet)** which outperforms the other pre-trained models and the models worked on the same dataset. Just by capturing the image of the surrounding environment, the user can get the **real-time AQI** of that place.

---

## ๐Ÿ“‹ Table of Contents
- [๐ŸŒ AQI Prediction ๐ŸŒค๏ธ](#-aqi-prediction-๏ธ)
- [๐Ÿ“‹ Table of Contents](#-table-of-contents)
- [๐Ÿ“– Introduction](#-introduction)
- [๐ŸŒฌ๏ธ What is AQI?](#๏ธ-what-is-aqi)
- [๐Ÿค” Why is AQI important?](#-why-is-aqi-important)
- [๐Ÿ‡ง๐Ÿ‡ฉ Why is AQI prediction important for Bangladesh?](#-why-is-aqi-prediction-important-for-bangladesh)
- [๐Ÿš€ Result of our Proposed Model](#-result-of-our-proposed-model)
- [๐Ÿ› ๏ธ How to use the application?](#๏ธ-how-to-use-the-application)
- [๐Ÿ“ธ Web Screenshots](#-web-screenshots)

---

## ๐Ÿ“– Introduction
### ๐ŸŒฌ๏ธ What is AQI?
The **Air Quality Index (AQI)** indicates air pollution levels and their potential health effects. It measures pollutants such as particulate matter, ozone, carbon monoxide, sulfur dioxide, and nitrogen dioxide.

### ๐Ÿค” Why is AQI important?
The AQI communicates daily air quality and guides precautions for public health. Categories:

- **0-50**: ๐ŸŸข Good
- **51-100**: ๐ŸŸก Moderate
- **101-150**: ๐ŸŸ  Unhealthy for Sensitive Groups
- **151-200**: ๐Ÿ”ด Unhealthy
- **201-300**: ๐ŸŸฃ Very Unhealthy
- **301-500**: โšซ Hazardous

### ๐Ÿ‡ง๐Ÿ‡ฉ Why is AQI prediction important for Bangladesh?
Bangladesh faces severe air pollution due to urbanization, industrialization, and vehicular emissions. Dhaka often ranks among the world's most polluted cities. Real-time AQI predictions can help people take precautions against harmful air quality.

---

## ๐Ÿš€ Result of our Proposed Model
We have trained our proposed model **(DeepAQNet)** on the dataset of Dhaka, Bangladesh. The model has achieved the following performance metrics on the test dataset:

| ๐Ÿงช Metric | โš™๏ธ Value |
| --- | ---- |
| **MSE** | 1685.03 |
| **RMSE** | 41.05 |
| **MAE** | 30.55 |
| **R2 Score** | 0.4229 |

---

## ๐Ÿ› ๏ธ How to use the application?
**Note:** ๐Ÿ Python must be installed on your system.

1. Clone the repository. ๐ŸŒ€
```bash
git clone https://github.com/fahadPathan7/AQI-Prediction-Web.git
```
2. Change the directory. ๐Ÿ“‚
```bash
cd AQI-Prediction-Web
```
3. Install the required libraries. ๐Ÿ“ฆ
```bash
pip install flask tensorflow numpy pillow matplotlib lime scikit-image
```
4. Run the application. ๐Ÿš€
```bash
python app.py
```
5. Open the browser and go to the following URL. ๐ŸŒ
```bash
http://localhost:5000/
```
6. Capture the image of the surrounding environment. ๐Ÿ“ธ
7. Click on the **Predict** button to get the real-time AQI of that place. โœ…
8. Get the AQI and take necessary precautions to protect yourself from the harmful effects of air pollution. ๐ŸŒฌ๏ธ

---

## ๐Ÿ“ธ Web Screenshots


๐Ÿ–ผ๏ธ Before Uploading the Image



โฌ‡๏ธ


๐Ÿ“ท After Uploading & Predicting the Image



---