1 of 36

AQI Predictor

AI Based App that predict

AQL just By taking photo

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

2 of 36

Our Team

Group Leader

AI Enthusiast

Seeking Career in ML, Computer Vision and Flutter Developer.

WAQAS AHMAD

Group Member

Researcher and developer.

Ali Hassan

Group Member

Computer Scientist with an aspiration to develop systems that could bring change and betterment.

Hamza Sadiq

Supervisor

Assistant Professor & Associate HOD of Computer Science

Dr. Usama Ijaiz Bajwa

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

3 of 36

Agenda

1

2

3

4

5

6

7

8

9

CONSTRAINTS

Limitations of our Project

PROCEDURE

Flow of Entire Application

INTRODUCTION

An intro to the concept of our project

WORK FORWARD

Work we are Doing

PROBLEM

The problem that caused this solution to be created

FEATURES

Positive Aspects of our Application

CHALLENGES

Challenges We Faced during Development

TOOLS & TECHNOLGIES

We used in whole projects

OOUTPUT

Interfaces and Result of Our Project

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

4 of 36

Introduction

An Intro to the Concept Of Our Project

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

5 of 36

Things to know before start

  • AQI brief introduction

  • PM2.5 vitality in perspective of AQI

  • Categorization of PM2.5

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

6 of 36

PM2.5 Categorization

  • PM 2.5 is the particle that have diameter less than 2.5 and possess some value

  • Particulate matter is the sum of all solid and liquid particles suspended in air many of which are hazardous.

  • Major cause of Air pollution and causes respiratory problems

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

7 of 36

Advanced Approaches

  • Concept to build a system that predict AQL

  • Android and web based application

  • Using Deep Learning techniques:
    • Predict air quality level of any picture.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

8 of 36

Increasing Ratio Of Chronic Respiratory Diseases

> 3 Millions People Die each Year From chronic obstructive pulmonary disease.

Pakistan Worst AQI Rank

2/ 98 countries ranked in 2019

Expensive Sensor

Price of good Sensor is approx. 1 Million

Sensor Range

Range of Good Sensor is approx. 3-3.5KM

Problems

Problems that Caused this Solution To Be Created

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

9 of 36

Smart Solution

Use Smart Phone’s Camera to know that Quality of Air in which you Breath

Our Android and Web Application

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

10 of 36

Procedure

Turn On App

Turn On GPS

Turn On Internet

Capture Image

Getting Location

Saving Result

Display Result

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

11 of 36

Features

No exact application is available in Pakistan yet.

Unique App

01

Application can be used by PMD to spend less time finding the polluted areas and more time to control pollution.

Help in Reducing Air Pollution

02

This application’s database will be the largest visual collection of marked polluted areas in Pakistan.

Cheap Solution to Know Polluted Areas

03

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

12 of 36

Constraints

User needs android device with a working camera and android Version is 6.0 or above.

Android Version

User Should have active Internet Connection.

Active Internet

User’s Android Device must Support GPS.

GPS Support

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

13 of 36

Challenges

Challenges we Faced during Development

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

14 of 36

Challenges

Approach

Selection Of Technique

Deployment

Porting To Android App

Dataset

Dataset Collection & Annotation

01

02

03

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

15 of 36

Dataset

  • Dataset that was either of Pakistan or was near to Pakistan in terms of atmosphere and climate.

  • We couldn’t find any Dataset Of Pakistan.

  • We opted to use dataset of China that we were able to find.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

16 of 36

Dataset Labelling

  • Data annotation is the task of labelling any type of data : images, audio, text, video, …

  • We do it manually.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

17 of 36

Selection Of Technique

  • Either Machine Learning Models or Deep Learning Techniques

  • Extract features from Images or Feed Image Directly

  • Regression vs VGG16

18 of 36

Why we Select VGG16

  • Extracts prominent features from the image automatically.

  • VGG16 is priorly trained on ImageNet dataset which makes it prone for the classification task

  • This architecture is flexible and works well on the image Dataset

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

19 of 36

Deployment In Android

  • Convert Keras Model to TensorFlow and embed model into android

OR

  • Use Flask as backend

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

20 of 36

Using panoptic segmentation

  • Panoptic Segmentation model (from Detectron2 by Facebook) was chosen to detect sky in the pictures. It’s an incredibly intelligent CNN model that can be used to classify both instance segmentation objects and semantic segmentation objects.

  • We are using it with customized output to check if there is the sky in the picture or not. Having sky in the picture is our requirement to predict AQ level.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

21 of 36

Using panoptic segmentation

Panoptic segmentation is the combination of semantic and instance segmentation. Semantic segmentation works by classifying each pixel into the given classes that are predetermined. Image captioning, the task of automatically generating natural language descriptions of images, has received increasing attention in computer vision and natural language processing. This task has several important practical applications.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

22 of 36

System Architecture

Three-tier architecture

  • Two models used
    1. 1st for identifying if sky exists in the picture
    2. 2nd for identifying AQL: Our main model

  • A backend server on which the models are placed and operate on

  • A database on which data store and retrieve

Implementation

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

23 of 36

Output

Interface and Result of our Project

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

24 of 36

Android App Interfaces

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

25 of 36

AQI TELLER Interface

In this User Upload Pic and Application tells Air Quality Level

By Clicking Upload User will Upload Image and System check that it is according to instructions or not

Display Result after Processing and Precautions according to Image’s Result.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

26 of 36

01

Web App Demo

02

Android App Demo

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

27 of 36

Tools and Technologies

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

28 of 36

Future Work

  1. Can be improved to extend usage to pictures without sky and without enough light

  • Can be improved to calculate AQI

  • Can further increase accuracy if a more appropriate dataset can be obtained

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

29 of 36

Additional Working…

Writing a Journal Research Paper.

Team AQI Predictor Collaborating

with PMD Pakistan.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

30 of 36

Acknowledgment

We Would Like to Thank:

    • Allah Almighty who gave us the power and the courage to compete this project

    • Dr. Usama Ijaz Bajwa (Project Supervisor) for his guidance, which help us to complete this project.

    • And All Others who Help Us to complete this Project.

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

31 of 36

Connect Us Via…

MPVIR

Our Work is cited at Machine Perception & Visual Intelligence Research Group

https://sites.google.com/view/mpvir/projects/aqi-predictor

GitHub

Find our Work at GitHub

https://github.com/waqas2727

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

32 of 36

JAZAKALLAH

Any Question?

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

33 of 36

Further Read

For Explanation Purposes

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

34 of 36

Regression csv file

    • CSV file screenshot is here with features

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

35 of 36

FLOW CHART

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group

36 of 36

Results

Model

Accuracy(%)

VGG16

87.03

VGG16 + LSTM

66

VGG16 +

Random Forest

79

Department of Computer Sciences

Machine Perception and Visual Intelligence Research Group