Reproducibility – README Project Title Leveraging Deep Learning and Ensemble Learning for Air Quality Forecasting in Smart Urban Environment Description This project analyzes air quality data to classify smog levels using classical machine learning (SVM, Decision Tree, Random Forest, KNN) and deep learning models (CNN, DNN, LSTM). It utilizes AQI data for PM2.5 and PM10 collected via the OpenWeatherMap API for the region of Lahore, Pakistan. Dataset The dataset used in this study is publicly available from OpenWeatherMap: - API Endpoint: `https://api.openweathermap.org/data/2.5/air_pollution/history?lat=31.5497&lon=74.3436&start=1672531200&end=1704067200&appid=4ccd6f333eec5f5a5982f255f550782a` - Dataset File: `Air_Quality_Data_with_Numerical_Smog_Levels_PM2.5_2020-2023.csv` (attached) Installation and Setup 1. Clone this repository or download the files. 2. Ensure Python 3.8+ is installed. 3. Install the required libraries using: pip install pandas numpy matplotlib seaborn scikit-learn tensorflow openpyxl Running the Code Step 1: Data Cleaning & Interpolation Script: `data_cleaning.py - Fills missing PM2.5 and PM10 AQI values using linear interpolation. - Converts interpolated values to integers. Step 2: Assign Numerical Smog Levels Script: `assign_smog_levels.py` - Categorizes AQI values into smog levels (1 to 6) based on environmental standards. Step 3: Model Training and Evaluation Script: `train_models.py` - Splits the data - Trains 3 deep learning models (CNN, DNN, LSTM) - Trains 4 classical models (SVM, Decision Tree, Random Forest, KNN) - Generates confusion matrices and prints accuracy scores. Output - Accuracy metrics for each model - Confusion matrices for PM10 classification - Visual heatmaps to interpret model performance Online Demo You can interact with the deployed model here: https://smog-pred.streamlit.app This web application allows users to upload air quality data and receive smog level predictions using the trained models. License This project is for academic and research use only. Contact For any queries, contact taseer.suleman11@gmail.com